[SKRIPT] time by variable

Discussion in 'Spigot Plugin Help' started by Instanity, Jun 9, 2017.

  1. So I have an UHC plugin that I bought but I'm not too good at editing plugins with an IDE so I tried using Skript to make this function.
    I tried to make a thing that when some does the command "/config pvp_time <number>" it will set {pvp.time} to the number, but when uhc starts it will appear in the action bar. and I don't know how to do it.
    That's what I tried:
    Code (Text):
    on command "/config pvp_time <number>":
        if player has permission "instanity.host":
            set {pvp.time} to arg-1
            message "Integer set to %arg-1%"
       
    on command "/config heal_time <number>":
        if player has permission "instanity.host":
            set {heal.time} to arg-1
            message "Integer set to %arg-1%"
           
    on command "/startuhc" or "/uhc:startuhc":
        if player has permission "instanity.host":
            wait 7 seconds
            loop all players:
                execute console command "/timer %{heal.time}% &7[&6Heal&7]"
                wait {heal.time} seconds
                execute console command "/timer %{pvp.time}% &7[&bPvP&7]"
     

  2. ANY API???