309 |
307 |
310 runOnGears(StartingSetUp) |
308 runOnGears(StartingSetUp) |
311 runOnGears(ConvertValues) |
309 runOnGears(ConvertValues) |
312 end |
310 end |
313 |
311 |
314 function CheckForHogSwitch() |
312 function AssignHogAmmo() |
315 |
313 -- Re-assign ammo to this guy, so that his entire ammo set will |
316 if (CurrentHedgehog ~= nil) then |
314 -- be visible during another player's turn |
317 |
315 if lastHog ~= nil then |
318 currHog = CurrentHedgehog |
316 ConvertValues(lastHog) |
319 |
317 end |
320 if currHog ~= lastHog then |
318 |
321 |
319 -- Give the new hog what he is supposed to have, too |
322 -- re-assign ammo to this guy, so that his entire ammo set will |
320 ConvertValues(CurrentHedgehog) |
323 -- be visible during another player's turn |
|
324 if lastHog ~= nil then |
|
325 ConvertValues(lastHog) |
|
326 end |
|
327 |
|
328 -- give the new hog what he is supposed to have, too |
|
329 ConvertValues(CurrentHedgehog) |
|
330 |
|
331 end |
|
332 |
|
333 lastHog = currHog |
|
334 |
|
335 end |
|
336 |
|
337 end |
321 end |
338 |
322 |
339 function onNewTurn() |
323 function onNewTurn() |
340 CheckForHogSwitch() |
324 AssignHogAmmo() |
341 end |
325 end |
342 |
326 |
343 --function onGameTick20() |
327 --function onGameTick20() |
344 --CheckForHogSwitch() |
328 --CheckForHogSwitch() |
345 -- if we use gfPerHogAmmo is this even needed? Err, well, weapons reset, so... yes? |
329 -- if we use gfPerHogAmmo is this even needed? Err, well, weapons reset, so... yes? |