1. Welcome to skUnity!

    Welcome to skUnity! This is a forum where members of the Skript community can communicate and interact. Skript Resource Creators can post their Resources for all to see and use.

    If you haven't done so already, feel free to join our official Discord server to expand your level of interaction with the comminuty!

    Now, what are you waiting for? Join the community now!

  2. LOOKING FOR A VERSION OF SKRIPT?

    You can always check out our Wiki for downloads and any other information about Skript!

Dismiss Notice
This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

increase or decrease damage by percentages

Discussion in 'Skript' started by nicolas toledo, Dec 23, 2020.

Tags:
Thread Status:
Not open for further replies.
  1. nicolas toledo

    Joined:
    Mar 29, 2020
    Messages:
    28
    Likes Received:
    0
    Hello, I am having a problem! I want a player to have a specific item to damage 50% more based on the final damage caused. Therefore a weapon that damages 100 should damage 150, but only damages 10 more hearts (110). Weapon damage is controlled by the Heroes plugin, but I don't think it affects anything. Here I leave the code that I am using:

    Code (Text):
    1. on damage:
    2.     loop all items in the inventory of attacker:  
    3.         if name of attacker's tool contains "&1 [Sharp]":      
    4.             increase damage by 50%
     
  2. Sxndayy

    Sxndayy New Member

    Joined:
    Dec 24, 2020
    Messages:
    6
    Likes Received:
    0
    Try using this (removing the loop):
    Code (Text):
    1. on damage:
    2.     if name of attacker's tool contains "&1 [Sharp]":
    3.         increase damage by 50%
     
  3. nicolas toledo

    Joined:
    Mar 29, 2020
    Messages:
    28
    Likes Received:
    0
    Not found :emoji_frowning:
     
  4. FireRoz

    FireRoz Active Member

    Joined:
    May 28, 2020
    Messages:
    134
    Likes Received:
    6
    i feel like i already answered this question. did u make a new post?
    --- Double Post Merged, Jan 26, 2021, Original Post Date: Jan 26, 2021 ---
    upload_2021-1-26_9-25-14.png

    u already got the answer from me, why r u double posting ? :emoji_confused:
    here, you can see you made 1 post with 2 replies, that specific post is marked as solved, then you posted this thread asking the same thing.

    Just go to that thread and take the answer -_-
     
Thread Status:
Not open for further replies.

Share This Page

Loading...