share/hedgewars/Data/Missions/Training/Basic_Training_-_Bazooka.lua
changeset 13497 65c348d6c1fa
parent 13354 f9a15dcd857c
child 13503 c5d7376fa58a
equal deleted inserted replaced
13496:cbda0f842364 13497:65c348d6c1fa
    10 	- “Bouncing bomb” / water skip
    10 	- “Bouncing bomb” / water skip
    11 	- Precise aiming
    11 	- Precise aiming
    12 ]]
    12 ]]
    13 
    13 
    14 HedgewarsScriptLoad("/Scripts/Locale.lua")
    14 HedgewarsScriptLoad("/Scripts/Locale.lua")
       
    15 HedgewarsScriptLoad("/Scripts/Achievements.lua")
    15 
    16 
    16 local hog			-- Hog gear
    17 local hog			-- Hog gear
    17 local weaponSelected = false	-- Player has selected the weapon
    18 local weaponSelected = false	-- Player has selected the weapon
    18 local gamePhase = 0		-- Used to track progress
    19 local gamePhase = 0		-- Used to track progress
    19 local targetsLeft = 0		-- # of targets left in this round
    20 local targetsLeft = 0		-- # of targets left in this round
   188 		ShowMission(loc("Basic Bazooka Training"), loc("Training complete!"), loc("Congratulations!"), 0, 0)
   189 		ShowMission(loc("Basic Bazooka Training"), loc("Training complete!"), loc("Congratulations!"), 0, 0)
   189 		SetInputMask(0)
   190 		SetInputMask(0)
   190 		AddAmmo(CurrentHedgehog, amBazooka, 0)
   191 		AddAmmo(CurrentHedgehog, amBazooka, 0)
   191 		if shotsFired > maxTargets then
   192 		if shotsFired > maxTargets then
   192 			flawless = false
   193 			flawless = false
       
   194 		else
       
   195 			-- For 100% accuracy
       
   196 			awardAchievement(loc("Bazooka Master"))
   193 		end
   197 		end
   194 		if flawless then
   198 		if flawless then
   195 			PlaySound(sndFlawless, hog)
   199 			PlaySound(sndFlawless, hog)
   196 		else
   200 		else
   197 			PlaySound(sndVictory, hog)
   201 			PlaySound(sndVictory, hog)