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 our 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.

Item Damage

Discussion in 'Skript' started by Zakkeagle, Oct 29, 2017.

Thread Status:
Not open for further replies.
  1. Zakkeagle

    Zakkeagle Member

    Joined:
    Oct 20, 2017
    Messages:
    5
    Likes Received:
    0
    How would I prevent items from burning in lava or fire?

    Here's what I have:
    Code (Skript):
    1. on damage of entity:
    2.     event-entity is item:
    3.         damage was caused by burn:
    4.             cancel the event
    I've gotten no errors from it either, and I can't find anything on it
     
  2. ImOfflinezzz

    Addon Developer

    Joined:
    Jan 24, 2017
    Messages:
    72
    Likes Received:
    10
    Code (Skript):
    1.  
    2. damage cause isn't burning or lava
    3.  
     
  3. Abwasserrohr

    Abwasserrohr Member

    Joined:
    Apr 19, 2017
    Messages:
    2
    Likes Received:
    0
    My suggestion:
    Code (Skript):
    1.  
    2. on damage of a entity:
    3.    if "%victim%" is "dropped item":
    4.        if "%damage type%" is "burning" or "lava" or "fire":
    5.            cancel event
    6.  
    7.  
    I think, dropped items normally don't get any damage. Lava/Magma are the only one, right?

    EDIT: This way, only lava damages would get blocked.
     
    #3 Abwasserrohr, Nov 16, 2017
    Last edited: Nov 18, 2017
  4. Mr_Simba

    Mr_Simba King of the Pridelands
    Moderator Supporter

    Joined:
    Dec 9, 2016
    Messages:
    257
    Likes Received:
    55
    Medals:
    Cacti and explosions also destroy them.
     
Thread Status:
Not open for further replies.
Loading...