Is there a command to stop the execution of all previously loaded code, so that I can then continue with something else?
Sometimes my alts will crash in mini-games and it simply gets to 10/10 stuck errors then I had it going to sleep. So I decided to change it so if it hits 10/10 it runs the client restart function and then, depending on what waypoint it was in when it crashed, loads the waypoint for the next minigame.
The issue im having though, is that after reloging it'll still try and finish what ever it was doing before it starts what I need it to.
Example of the function I added to Unstickfailure:
Code: Select all
<onUnstickFailure><![CDATA[
if ShellAlts() == true then
local currentWP = string.lower(__WPL.FileName)
ChangeCharRestart("current")
if currentWP == "example" then
loadPaths("example2");
end
else
player:sleep();
end
]]></onUnstickFailure>