desert01 fixed destructible terrain marks and cosmos marks for completed main missions
authorPeriklis Ntanasis <pntanasis@gmail.com>
Wed, 18 Dec 2013 03:06:37 +0200
changeset 9802 00216d609140
parent 9800 169fbb968bb3
child 9803 0773ec65dfc2
desert01 fixed destructible terrain marks and cosmos marks for completed main missions
share/hedgewars/Data/Missions/Campaign/A_Space_Adventure/cosmos.lua
share/hedgewars/Data/Missions/Campaign/A_Space_Adventure/desert01.hwp
share/hedgewars/Data/Missions/Campaign/A_Space_Adventure/desert01.lua
share/hedgewars/Data/Missions/Campaign/A_Space_Adventure/final.lua
share/hedgewars/Data/Missions/Campaign/A_Space_Adventure/global_functions.lua
--- a/share/hedgewars/Data/Missions/Campaign/A_Space_Adventure/cosmos.lua	Wed Dec 18 01:05:15 2013 +0400
+++ b/share/hedgewars/Data/Missions/Campaign/A_Space_Adventure/cosmos.lua	Wed Dec 18 03:06:37 2013 +0200
@@ -226,6 +226,10 @@
 	CheckEvents()
 end
 
+function onGameTick20()
+	setFoundDeviceVisual()
+end
+
 function onPrecise()
 	if GameTime > 3000 then
 		SetAnimSkip(true)
@@ -471,6 +475,34 @@
 	sendStatsOnRetry()
 end
 
+function setFoundDeviceVisual()
+	--WriteLnToConsole("status: "..status.fruit01.." - "..status.fruit02)
+	if status.moon01 then
+		vgear = AddVisualGear(1116, 848, vgtBeeTrace, 0, false)
+
+	end
+	if status.ice01 then
+		vgear = AddVisualGear(1512, 120, vgtBeeTrace, 0, false)
+
+	end
+	if status.desert01 then
+		vgear = AddVisualGear(4015, 316, vgtBeeTrace, 0, false)
+
+	end
+	if status.fruit01 and status.fruit02 then
+		vgear = AddVisualGear(2390, 384, vgtBeeTrace, 0, false)
+
+	end
+	if status.death01 then
+		vgear = AddVisualGear(444, 400, vgtBeeTrace, 0, false)
+
+	end
+	if status.final then
+		vgear = AddVisualGear(3070, 810, vgtBeeTrace, 0, false)
+
+	end
+end
+
 -------------- ANIMATIONS ------------------
 
 function Skipanim(anim)
@@ -562,6 +594,7 @@
 	SendStat(siGameResult, loc("Hog Solo arrived at "..planet))
 	SendStat(siCustomAchievement, loc("Return to the mission menu by pressing the \"Go back\" button"))
 	SendStat(siCustomAchievement, loc("You can choose another planet by replaying this mission"))
+	SendStat(siCustomAchievement, loc("Planets with completed main missions will be marked with a flower"))
 	SendStat(siPlayerKills,'1',teamC.name)
 	EndGame()
 end
Binary file share/hedgewars/Data/Missions/Campaign/A_Space_Adventure/desert01.hwp has changed
--- a/share/hedgewars/Data/Missions/Campaign/A_Space_Adventure/desert01.lua	Wed Dec 18 01:05:15 2013 +0400
+++ b/share/hedgewars/Data/Missions/Campaign/A_Space_Adventure/desert01.lua	Wed Dec 18 03:06:37 2013 +0200
@@ -24,7 +24,8 @@
 local dialog01 = {}
 -- mission objectives
 local goals = {
-	[dialog01] = {missionName, loc("Getting ready"), loc("The device part is hidden in one of the crates! Go and get it!"), 1, 4500},
+	[dialog01] = {missionName, loc("Getting ready"), loc("The device part is hidden in one of the crates! Go and get it!").."|"..
+			loc("Most of the destructible terrain in marked with blue color"), 1, 4500},
 }
 -- crates
 local btorch1Y = 60
--- a/share/hedgewars/Data/Missions/Campaign/A_Space_Adventure/final.lua	Wed Dec 18 01:05:15 2013 +0400
+++ b/share/hedgewars/Data/Missions/Campaign/A_Space_Adventure/final.lua	Wed Dec 18 03:06:37 2013 +0200
@@ -150,6 +150,7 @@
 end
 
 function heroWin(gear)
+	saveCompletedStatus(7)
 	SendStat(siGameResult, loc("Congratulations, you have saved Hogera!"))
 	SendStat(siCustomAchievement, loc("Hogera is safe!"))
 	SendStat(siPlayerKills,'1',teamA.name)
--- a/share/hedgewars/Data/Missions/Campaign/A_Space_Adventure/global_functions.lua	Wed Dec 18 01:05:15 2013 +0400
+++ b/share/hedgewars/Data/Missions/Campaign/A_Space_Adventure/global_functions.lua	Wed Dec 18 03:06:37 2013 +0200
@@ -35,7 +35,7 @@
 			status.moon01 = true
 		end
 		if allStatus:sub(2,2) == "1" then
-			status.fuit01 = true
+			status.fruit01 = true
 		end
 		if allStatus:sub(3,3) == "1" then
 			status.fruit02 = true