share/hedgewars/Data/Missions/Campaign/A_Space_Adventure/fruit02.lua
changeset 9747 abe0c8a2d573
parent 9746 64abf9862562
child 9758 3b8058b251b8
equal deleted inserted replaced
9746:64abf9862562 9747:abe0c8a2d573
   271 	if not permitCaptainLimeDeath and not GetHealth(green1.gear) then
   271 	if not permitCaptainLimeDeath and not GetHealth(green1.gear) then
   272 		-- game ends with the according stat messages
   272 		-- game ends with the according stat messages
   273 		heroDeath()
   273 		heroDeath()
   274 		permitCaptainLimeDeath = true
   274 		permitCaptainLimeDeath = true
   275 	end
   275 	end
       
   276 	if CurrentHedgehog and GetY(CurrentHedgehog) > 1350 then
       
   277 		SetWind(-40)
       
   278 	end
   276 end
   279 end
   277 
   280 
   278 function onGearDelete(gear)
   281 function onGearDelete(gear)
   279 	if gear == hero.gear then
   282 	if gear == hero.gear then
   280 		hero.dead = true
   283 		hero.dead = true
   540 function goToThesurface()
   543 function goToThesurface()
   541 	TurnTimeLeft = 0
   544 	TurnTimeLeft = 0
   542 end
   545 end
   543 
   546 
   544 function wind()
   547 function wind()
   545 	if GetY(CurrentHedgehog) > 1350 then
   548 	SetWind(math.random(-100,100))
   546 		SetWind(-40)
       
   547 	else
       
   548 		SetWind(math.random(-100,100))
       
   549 	end
       
   550 end
   549 end
   551 
   550 
   552 function saveHogsPositions()
   551 function saveHogsPositions()
   553 	local positions;
   552 	local positions;
   554 	positions = GetX(hero.gear)..","..GetY(hero.gear)
   553 	positions = GetX(hero.gear)..","..GetY(hero.gear)