So I'm having an issue with a script and I'm not sure what's wrong. I've tried a few different formats but to save space I'm only going to share the first one because none of my transmutations worked anyways.
At line 2, I get 'then' expected near 'else' but I can't for the life of me figure out how to fix it.
require "wait"
if @Ki <= 100000 else
if @Pl <= 500000 then
if lastTriggerTime == nil or os.time () - lastTriggerTime >= 10 then
wait.make (function ()
lastTriggerTime = os.time ()
Execute ("nmoff")
wait.time (10)
Execute ("senzu")
wait.time (2)
Execute ("nmon")
end)
end
end
At line 2, I get 'then' expected near 'else' but I can't for the life of me figure out how to fix it.