share/hedgewars/Data/Missions/Campaign/A_Space_Adventure/desert03.lua
changeset 14488 7bb7e5e54f70
parent 13750 110d6c1e817f
child 14898 4596357d002d
equal deleted inserted replaced
14487:d72fb761aa59 14488:7bb7e5e54f70
    71 	Theme = "Desert"
    71 	Theme = "Desert"
    72 	-- Disable SuddenDeath
    72 	-- Disable SuddenDeath
    73 	WaterRise = 0
    73 	WaterRise = 0
    74 	HealthDecrease = 0
    74 	HealthDecrease = 0
    75 
    75 
    76 	-- Hog Solo
    76 	-- Hero
    77 	AddTeam(teamA.name, teamA.color, "Simple", "Island", "Default", "hedgewars")
    77 	teamA.name = AddMissionTeam(teamA.color)
    78 	hero.gear = AddHog(hero.name, 0, 1, "war_desertgrenadier1")
    78 	hero.gear = AddMissionHog(1)
       
    79 	hero.name = GetHogName(hero.gear)
    79 	AnimSetGearPosition(hero.gear, hero.x, hero.y)
    80 	AnimSetGearPosition(hero.gear, hero.x, hero.y)
    80 
    81 
    81 	initCheckpoint("desert03")
    82 	initCheckpoint("desert03")
    82 
    83 
    83 	AnimInit()
    84 	AnimInit()
   233 	checkAllMissionsCompleted()
   234 	checkAllMissionsCompleted()
   234 	EndGame()
   235 	EndGame()
   235 end
   236 end
   236 
   237 
   237 function gameOver()
   238 function gameOver()
   238 	SendStat(siGameResult, loc("Hog Solo lost, try again!"))
   239 	SendStat(siGameResult, string.format(loc("%s lost, try again!"), hero.name))
   239 	SendStat(siCustomAchievement, loc("You have to destroy all the targets."))
   240 	SendStat(siCustomAchievement, loc("You have to destroy all the targets."))
   240 	SendStat(siCustomAchievement, loc("You will fail if you run out of ammo and there are still targets available."))
   241 	SendStat(siCustomAchievement, loc("You will fail if you run out of ammo and there are still targets available."))
   241 	SendStat(siCustomAchievement, loc("Read the challenge objectives from within the mission for more details."))
   242 	SendStat(siCustomAchievement, loc("Read the challenge objectives from within the mission for more details."))
   242 	sendSimpleTeamRankings({teamA.name})
   243 	sendSimpleTeamRankings({teamA.name})
   243 	EndGame()
   244 	EndGame()