#boss skript broken

1 messages · Page 1 of 1 (latest)

sand swallow
#

code blocks please

#

and instead of looping 10000 times, use a while loop

#

and dont use console commands, skript has a playsound effect

vagrant crow
sand swallow
sand swallow
vagrant crow
#


on damage of drowned:
    attacker is a player
    victim's custom name is "&bᴘᴏѕᴇɪᴅᴏɴ"


    set {_boss} to victim



    loop all players in radius 20 around {_boss}:
        loop 50 times:
            set {_tridentLocation} to location of loop-player
            add 5 to y-coordinate of {_tridentLocation}
            spawn a trident at {_tridentLocation}

command /boss:
    permission: boss
    trigger:
        while 1 = 1:
            wait 10 seconds
            if {alive} is false:
                execute console command "playsound minecraft:music_disc.pigstep ambient @a 24.00 251.94 459.49 5"
                set {alive} to true
                set {_location} to location at 34, 254, 458
                set {_motion} to location at 34, 254, 458
                spawn 1 trident at {_motion}
                spawn a drowned at {_location}
                set name of spawned entity to "&bᴘᴏѕᴇɪᴅᴏɴ"
                set max health of spawned entity to 1500000000
                set health of spawned entity to 1500000000
                set damage of spawned entity to 50
                broadcast ""
                broadcast "&b&lᴘᴏѕᴇɪᴅᴏɴ ʜᴀѕ ᴀᴡᴏᴋᴇɴ!"
                broadcast ""
                wait 1 second
                spawn 4 zombies at {_location}
                set name of spawned entity to "&bᴘᴏѕᴇɪᴅᴏɴѕ ᴍɪɴɪᴏɴ"
                set max health of spawned entity to 100
                set health of spawned entity to 100
                wait 1 tick
                wait 10 minutes



on death of drowned:
    set {alive} to false
    loop all players:
        if "%region at loop-player%" contains "poseidon":
            give 2 string named "&f&lᴘᴏѕᴇɪᴅᴏɴ ʜᴀɪʀ" to loop-player
            execute console command "stopsound @a"

#

like that?

vagrant crow
#

ok

vagrant crow
sand swallow
#

I mean

#

Youre setting the var to false when a drowned dies

#

Not just the boss, but any drowned

vagrant crow
#

there is only one drowned there

#

its in a sealed area

sand swallow
#

“There” doesnt matter

#

If a drowned dies on the other side of the world the event is triggered

vagrant crow
#

How can I fix that

sand swallow
#

check if the drowned was the boss

#

Here's your options:

  • set & check NBT
  • set & check a metadata tag
  • check the victim's name
  • check the region
vagrant crow
#

i disabled the skript

#

deleted it

#

and it is still spawning

sand swallow
#

Because its a while loop