SkDragon

  • 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!

  • LOOKING FOR A VERSION OF SKRIPT?

    You can always check out skUnity Downloads for downloads and any other information about Skript!

Status
Not open for further replies.

MeHow

Active Member
Feb 6, 2017
140
13
18
22
Lithuania
code_language.skript:
every 2 seconds:
    loop all zombies:
        loop all blocks in radius 10 of loop-zombie:
            if line 1 of loop-block is "[Building]":   
                if line 2 of loop-block is "LightTower":   
                    if line 3 of loop-block is "Level 1":                   
                        if loop-block is a sign:
                            damage loop-zombie by 0.5 heart   
                            drawLine particle redstone, center loop-block, target location of loop-zombie, id "%loop-zombie%", rainbowMode true, solid true, density 5, length 6, zigZag count 0, height 0, visibleRange 32, displacementXYZ 0, 1, 0, pulseDelay 1                           
                            stop

I am trying to do that from sign particle line target loop-zombie
Ty for help
 
This is going to be REALLY laggy, you're looping a 21x21x21 area, which is 9261 blocks, around every zombie every 2 seconds. This is a completely unideal solution, you should just use the "on sign edit" event to detect when a player finishes editing a sign, then detect those lines then, and if it's one of the correct signs, add its location to a list, and then instead loop through the list of sign locations and find nearby zombies.
 
Status
Not open for further replies.