Its good to see new scripters, but there a few points that have to be worked on
Stop using so much while loops xD
I suggest you to get rid of them or atleast add a break timer so it can't get stuck.
Walking to the swamp could also be in the localwalker,
since it has been walking to several wrong positions for me too lately... not sure what the issue is
Try to have a better code style,
More checks where your player is located and what to do next.
Don't just put everything back to back.
Like APA said: Use states or use some way the logic of the script improves
This will also give NPE's:
if(objects.closest("Staircase").hasAction("Climb-down"))
objects.closest("Staircase").interact("Climb-down");
if(objects.closest("Gate").hasAction("Open"))
You should get the Object first, then Null check it before you do anything with it.
Khaleesi