Solved block loop not working

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

    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!

ThunderPierce

Member
Jul 15, 2024
15
0
1
Belgium
every 3 seconds:
loop all blocks:
loop-block is green terracotta:
{generator::%event-location%} is online:
drop 1 paper with no velocity at location above loop-block

im making a gen server and my block loop for my generator isnt working, it gives the error "line 3: there is no loop that matches loop-block".
the variable is saved in another piece of code so that cant be the problem.
im using skrayfall.
 
loop all blocks would cause so much strain on the server, its not actually looping all blocks. its looping the names of them, like stone, oak log, dirt
you need to make a list of all the placed generators
 
nvm it didnt give the error untill i changed some stuff.

every 3 seconds:
loop green terracotta:
{generator::%loop-location%} is online:
drop 1 paper with no velocity at location above loop-block
 
Here, try this:


code_language.skript:
every 3 seconds:
    loop all players:
        loop all blocks in a radius of 5 of loop-player:
            if loop-block is green terracotta:
                if {generator::%loop-location%} is online:
                    drop 1 paper with no velocity at block above loop-block
 
Here, try this:


code_language.skript:
every 3 seconds:
    loop all players:
        loop all blocks in a radius of 5 of loop-player:
            if loop-block is green terracotta:
                if {generator::%loop-location%} is online:
                    drop 1 paper with no velocity at block above loop-block
i get the error "cant understand this: all blocks in a radius of 5 of loop-player