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!


    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.

Sword that damages all enities but not player

Discussion in 'Skript' started by aarav9999, Nov 2, 2022.

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

    aarav9999 Member

    Oct 4, 2022
    Likes Received:
    hello, I would like a sword that damages all entities in a certain radius but if I use damage all entities, it damages the player too. any fixes? Code will be below.

    on right click:
    if player's tool is iron sword named "&6Scylla":
    if {-p::%uuid of player%::hype} is true:
    send "&cAbility On Cooldown!"
    cancel event
    if {-p::%uuid of player%::hype} isn't set:
    set {-p::%uuid of player%::hype} to false
    if {-p::%uuid of player%::hype} is false:
    set {-p::%uuid of player%::hype} to true
    create fake explosion at player's head
    create fake explosion at player's location
    heal player by 30
    damage all entities in radius 5 of player by 30
    heal player by 30
    if player does not have potion effect absorption:
    apply potion of absorption of tier 3 to player for 25 seconds
    if player does not have potion effect regeneration:
    apply potion of regeneration of tier 2 to player for 10 seconds
    wait 2 seconds
    set {-p::%uuid of player%::hype} to false

    --- Double Post Merged, Nov 2, 2022, Original Post Date: Nov 2, 2022 ---
    Skript ver: 2.6.3
    skRayFall ver: 1.9.26
    Paper ver: git-Paper-411 (MC: 1.17.1) (Implementing API version 1.17.1-R0.1-SNAPSHOT) (Git: 6625db3 on ver/1.17.1)
  2. Pierrelasse

    Pierrelasse Active Member

    Apr 20, 2022
    Likes Received:
    (Dont try remaking skybluck)
Thread Status:
Not open for further replies.

Share This Page