# HG changeset patch # User Wuzzy # Date 1508604744 -7200 # Node ID 2c4a07eb211217c99711455cb095c49b99a23ab4 # Parent 4e0e592558562ddb9d51be3ad8e9f5316fa62760 Sniper rifle training: Fix missing victory sound, also disable controls at the end String freeze notice: This commit will display a caption with the string "Victory!". It does NOT violate the string freeze, as this string is already present in stub.lua. diff -r 4e0e59255856 -r 2c4a07eb2112 share/hedgewars/Data/Missions/Challenge/Basic_Training_-_Sniper_Rifle.lua --- a/share/hedgewars/Data/Missions/Challenge/Basic_Training_-_Sniper_Rifle.lua Sat Oct 21 18:38:28 2017 +0200 +++ b/share/hedgewars/Data/Missions/Challenge/Basic_Training_-_Sniper_Rifle.lua Sat Oct 21 18:52:24 2017 +0200 @@ -374,10 +374,17 @@ end else if not game_lost then - -- Otherwise show that the goal was accomplished + -- Victory! + AddCaption(loc("Victory!"), 0xFFFFFFFF, capgrpGameState) ShowMission(loc("Sniper Training"), loc("Aiming Practice"), loc("Congratulations! You've eliminated all targets|within the allowed time frame."), 0, 0) -- Also let the hogs shout "victory!" - PlaySound(sndVictory) + PlaySound(sndVictory, CurrentHedgehog) + FollowGear(CurrentHedgehog) + + -- Disable hog controls + SetInputMask(0) + AddAmmo(CurrentHedgehog, amSniperRifle, 0) + -- Save the time left so we may keep it. time_goal = TurnTimeLeft end