Skip to content
Snippets Groups Projects
Commit 71129e5c authored by dg's avatar dg
Browse files

Huge Sandworm Tunneler will try very very hard to get to the exit. It truly is relentless !

git-svn-id: http://svn.net-core.org/repos/t-engine4@6715 51575b47-30f0-44d4-a5cc-537603b46e54
parent 844793af
No related branches found
No related tags found
No related merge requests found
......@@ -119,9 +119,15 @@ newAI("sandworm_tunneler_huge", function(self)
self.ai_state.next_spot = self.ai_state.next_spot + 1
local s = game.level.ordered_spots[self.ai_state.next_spot]
if not s then
game.logSeen(self, "#OLIVE_DRAB#The %s burrows into the ground and disappears.", self.name)
self:disappear()
return
local ls = game.level.ordered_spots[#game.level.ordered_spots]
if self.x == ls.x and self.y == ls.y then
game.logSeen(self, "#OLIVE_DRAB#The %s burrows into the ground and disappears.", self.name)
self:disappear()
return
else -- Relentlessly try to get to the end
self.ai_state.next_spot = #game.level.ordered_spots
s = ls
end
end
self.ai_state.spot_x = s.x
self.ai_state.spot_y = s.y
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment