waypoint wait problem
Posted: Sun Apr 17, 2011 7:51 pm
I have a waypoint setup that's been working for the most part. Occasionally it fails and I need to somehow put a timer into the following function:
I've been looking around for a way to do it on my own but I haven't been able to find anything yet. The first occurrence is fine. My character gets to the entrance of the Boddosh room, waits till it detects Boddosh then waits 8 - 10 seconds for him to move back out of the room so I can clear 1/2 the room safely. It then goes back towards the entrance to wait a second time so I can clear the remaining mobs. On occasion Boddosh catches my character before it makes it to safety and it somehow lives through the fight before the second wait occurrence happens. Because of this it will wait indefinitely at the second wait. Is there some way to get a timer in there so it will continue after approximately 2 minutes?
Code: Select all
<!-- #133 --><waypoint x="3526" z="2693" y="47">
while (true) do
settings.options.MAX_TARGET_DIST = 300;
player:findTarget("Boddosh");
local target = player:getTarget();
if(target.Name == "Boddosh") then
player:restrnd(101, 8, 10);
break;
end;
yrest(300)
end;
</waypoint> <!-- Boddosh room -->
<!-- #134 --><waypoint x="3621" z="2771" y="49"> </waypoint>
<!-- #135 --><waypoint x="3697" z="2599" y="47"> </waypoint>
<!-- #136 --><waypoint x="3905" z="2626" y="47"> </waypoint>
<!-- #137 --><waypoint x="4037" z="2648" y="47"> </waypoint>
<!-- #138 --><waypoint x="3905" z="2626" y="47"> </waypoint>
<!-- #139 --><waypoint x="3697" z="2599" y="47"> </waypoint>
<!-- #140 --><waypoint x="3621" z="2771" y="49"> </waypoint>
<!-- #141 --><waypoint x="3526" z="2693" y="47"> </waypoint>
<!-- #142 --><waypoint x="3566" z="2692" y="49">
while (true) do
settings.options.MAX_TARGET_DIST = 300;
player:findTarget("Boddosh");
local target = player:getTarget();
if(target.Name == "Boddosh") then
player:restrnd(101, 12, 15);
break;
end;
yrest(300)
end;
</waypoint>