Jump to content

Clear Pathfind Goals of Event-Entity Doesn't Work


duhnoob1010

Recommended Posts

 

For some reason, the "clear pathfind goals of event-entity" does not seem to work for me. 

(I use sQuerry also)

1082695907_2022-02-10(3).png.eee7caf044135a0f82c6993427394c42.png

Full Code:

on right click:
    if uncolored name of player's tool is "Zombie Summoner":
        loop all players:
            set {_variable} to loop-players
            if uncolored name of loop-player's tool is "Zombie Summoner":
                if {grey.%player%} is false:
                    message "&4You Can't Do That Yet" to player
                    stop
                    cancel event
                if {grey.%player%} isn't set:
                    set {grey.%player%} to true
                if {grey.%player%} is true:
                    set {grey.%player%} to false
                    spawn a zombie at loop-player's location
                    set {_HM} to last spawned entity
                    set {_ra} to player
                    set name of last spawned entity to "&4Soul Servant"
                    clear pathfind goals of {_HM}
                    loop all mobs in radius 10 around loop-player:
                        if loop-mob is not {_variable}:
                            if loop-mob is not {_HM}:
                                set target of {_HM} to loop-mobs
                                increase max health of {_HM} by 40
                                apply strength 1 to {_HM} for 30 seconds
                                wait 30 seconds
                                set {grey.%player%} to true
                                kill {_HM}

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...