Jump to content

I have to replace gen every time server starts


HiroKiros

Recommended Posts

in my skygen server i made a gen skript but i have one problem everytime the server starts i have to break and re place the gens for them to start working this is on of gens skript

on place of Pearlescent Froglight:
    set {gens::%location of event-block%} to uuid of player
    if {gens::%player's uuid%} < 10:
        add 1 to {gens::%player's uuid%}
        while event-block is Pearlescent Froglight:
            wait 20 ticks
            drop 1 bone above location of event-block Without velocity
    else:
        send "" to player
        send "&bYou have reached your Gen Cap! &7%{gens::%player's uuid%}%&b/&710" to player
        send "" to player
        cancel event
 
command /gencap [<player>] [<text>] [<number>]:
    permission: gencap.use
    permission message: &cNope!
    trigger:
        if arg-1 is set:
            if arg-2 is "reset":
                set {gens::%arg-1's uuid%} to 0
                send "&cYou have just reset %arg-1%&c's gen cap!" to player
                

Link to comment
Share on other sites

I dont understand would i have to redo the skript 

10 hours ago, ApexSplat said:

the drop needs to be in a every second event as when the server restarts, the on place event will stop so the while loop will stop and therefore, it won't drop anything

 

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...