Changeset 4057 for data/branches/single_player_map/scripts/guard.lua
- Timestamp:
- Jul 3, 2006, 2:51:25 PM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
data/branches/single_player_map/scripts/guard.lua
r4056 r4057 8 8 playerInLock = false 9 9 hangarReached = false 10 11 height = 80 10 guardStopped = false 11 12 height = 29 12 13 13 14 -- Returns the distance between (x1,x2,x3) and (y1,y2,y3) … … 18 19 19 20 function observePlayer() 21 22 guardX = guard:getAbsCoorX() 23 guardY = guard:getAbsCoorY() 24 guardZ = guard:getAbsCoorZ() 25 20 26 playerX = Player:getAbsCoorX() 21 27 playerY = Player:getAbsCoorY() 22 28 playerZ = Player:getAbsCoorZ() 29 30 if dist( guardX,guardY,guardZ,playerX, playerX, playerX) > 30 and hangarRouteProgrammed then 31 --guard:stop() 32 guardStopped = true 33 end 34 35 if dist( guardX,guardY,guardZ,playerX, playerX, playerX) < 30 and hangarRouteProgrammed and guardStopped then 36 --guard:continue() 37 guardStopped = false 38 end 23 39 24 40 if dist( playerX,playerY,playerZ,167.361526,29,483.163818 ) < 60 then
Note: See TracChangeset
for help on using the changeset viewer.