Created
July 30, 2012 02:02
-
-
Save pxpc2/3203310 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if ((trap != null) && (trap.isOnScreen()) && (Players.getLocal().getAnimation() == -1)) | |
{ | |
Tile tile = trap.getLocation(); | |
trap.interact("Set-trap"); | |
SFields.inactivity = new Timer(0); | |
while ((SceneEntities.getAt(tile.getX(), | |
tile.getY()).getId() == SConstants.SWAMP_LIZARD_TRAP_OPEN) && | |
Players.getLocal().getAnimation() != -1) | |
{ | |
Context.get().getActiveScript().log.severe("inactive"); | |
Time.sleep(400); | |
if (SFields.inactivity.getElapsed() > 5000) | |
{ | |
return; | |
} | |
} | |
if (SceneEntities.getAt(tile.getX(), tile.getY()).getId() == SConstants.SWAMP_LIZARD_TRAP_WAITING) | |
{ | |
Context.get().getActiveScript().log.severe("We got in"); | |
SFields.trapTiles.add(tile); | |
} | |
} | |
else if (trap != null && !trap.isOnScreen()) | |
{ | |
Walking.walk(trap); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment