Add hidden bazooka training achievement for 100% accuracy
authorWuzzy <Wuzzy2@mail.ru>
Tue, 17 Jul 2018 18:38:44 +0200
changeset 13502 65c348d6c1fa
parent 13501 cbda0f842364
child 13503 4f00b08d6f1e
Add hidden bazooka training achievement for 100% accuracy
share/hedgewars/Data/Missions/Training/Basic_Training_-_Bazooka.lua
--- a/share/hedgewars/Data/Missions/Training/Basic_Training_-_Bazooka.lua	Tue Jul 17 16:45:34 2018 +0200
+++ b/share/hedgewars/Data/Missions/Training/Basic_Training_-_Bazooka.lua	Tue Jul 17 18:38:44 2018 +0200
@@ -12,6 +12,7 @@
 ]]
 
 HedgewarsScriptLoad("/Scripts/Locale.lua")
+HedgewarsScriptLoad("/Scripts/Achievements.lua")
 
 local hog			-- Hog gear
 local weaponSelected = false	-- Player has selected the weapon
@@ -190,6 +191,9 @@
 		AddAmmo(CurrentHedgehog, amBazooka, 0)
 		if shotsFired > maxTargets then
 			flawless = false
+		else
+			-- For 100% accuracy
+			awardAchievement(loc("Bazooka Master"))
 		end
 		if flawless then
 			PlaySound(sndFlawless, hog)