share/hedgewars/Data/Missions/Campaign/A Classic Fairytale/shadow.lua
changeset 7243 9ae9178c525e
parent 7232 277cbfbed93c
child 7425 3495e70c6d14
equal deleted inserted replaced
7241:7fda4d886c5e 7243:9ae9178c525e
   258   return true
   258   return true
   259 end
   259 end
   260 
   260 
   261 function EmitDenseClouds(anim, dir)
   261 function EmitDenseClouds(anim, dir)
   262   local dif
   262   local dif
   263   if dir == "left" then 
   263   if dir == "Left" then 
   264     dif = 10
   264     dif = 10
   265   else
   265   else
   266     dif = -10
   266     dif = -10
   267   end
   267   end
   268   AnimInsertStepNext({func = AnimVisualGear, args = {dense, GetX(dense) + dif, GetY(dense) + dif, vgtSteam, 0, true}, swh = false})
   268   AnimInsertStepNext({func = AnimVisualGear, args = {dense, GetX(dense) + dif, GetY(dense) + dif, vgtSteam, 0, true}, swh = false})
   311   table.insert(startDialogue, {func = AnimWait, args = {dense, 4000}})
   311   table.insert(startDialogue, {func = AnimWait, args = {dense, 4000}})
   312   table.insert(startDialogue, {func = AnimCaption, args = {leaks, loc("After the shock caused by the enemy spy, Leaks A Lot and Dense Cloud went hunting to relax."), 6000}})
   312   table.insert(startDialogue, {func = AnimCaption, args = {leaks, loc("After the shock caused by the enemy spy, Leaks A Lot and Dense Cloud went hunting to relax."), 6000}})
   313   table.insert(startDialogue, {func = AnimCaption, args = {leaks, loc("Little did they know that this hunt will mark them forever..."), 4000}})
   313   table.insert(startDialogue, {func = AnimCaption, args = {leaks, loc("Little did they know that this hunt will mark them forever..."), 4000}})
   314   table.insert(startDialogue, {func = AnimSay, args = {leaks, loc("I have no idea where that mole disappeared...Can you see it?"), SAY_SAY, 9000}})
   314   table.insert(startDialogue, {func = AnimSay, args = {leaks, loc("I have no idea where that mole disappeared...Can you see it?"), SAY_SAY, 9000}})
   315   table.insert(startDialogue, {func = AnimSay, args = {dense, loc("Nope. It was one fast mole, that's for sure."), SAY_SAY, 5000}}) 
   315   table.insert(startDialogue, {func = AnimSay, args = {dense, loc("Nope. It was one fast mole, that's for sure."), SAY_SAY, 5000}}) 
   316   table.insert(startDialogue, {func = AnimCustomFunction, args = {dense, EmitDenseClouds, {startDialogue, "right"}}})
   316   table.insert(startDialogue, {func = AnimCustomFunction, args = {dense, EmitDenseClouds, {startDialogue, "Right"}}})
   317   table.insert(startDialogue, {func = AnimWait, args = {dense, 2000}})
   317   table.insert(startDialogue, {func = AnimWait, args = {dense, 2000}})
   318   table.insert(startDialogue, {func = AnimSay, args = {leaks, loc("Please, stop releasing your \"smoke signals\"!"), SAY_SAY, 5000}})
   318   table.insert(startDialogue, {func = AnimSay, args = {leaks, loc("Please, stop releasing your \"smoke signals\"!"), SAY_SAY, 5000}})
   319   table.insert(startDialogue, {func = AnimSay, args = {leaks, loc("You're terrorizing the forest...We won't catch anything like this!"), SAY_SAY, 6000}})
   319   table.insert(startDialogue, {func = AnimSay, args = {leaks, loc("You're terrorizing the forest...We won't catch anything like this!"), SAY_SAY, 6000}})
   320   table.insert(startDialogue, {func = AnimSay, args = {leaks, loc("..."), SAY_THINK, 1000}})
   320   table.insert(startDialogue, {func = AnimSay, args = {leaks, loc("..."), SAY_THINK, 1000}})
   321   table.insert(startDialogue, {func = AnimGiveState, args = {cannibals[1], 0}, swh = false})
   321   table.insert(startDialogue, {func = AnimGiveState, args = {cannibals[1], 0}, swh = false})
   386   table.insert(stronglingsAnim, {func = AnimSay, args = {leaks, loc("I'll hold them up while you return to the village!"), SAY_SAY, 6000}})
   386   table.insert(stronglingsAnim, {func = AnimSay, args = {leaks, loc("I'll hold them up while you return to the village!"), SAY_SAY, 6000}})
   387   table.insert(stronglingsAnim, {func = AnimFollowGear, args = {cyborg}, swh = false})
   387   table.insert(stronglingsAnim, {func = AnimFollowGear, args = {cyborg}, swh = false})
   388   table.insert(stronglingsAnim, {func = AnimCaption, args = {cyborg, loc("30 minutes later...")}, swh = false})
   388   table.insert(stronglingsAnim, {func = AnimCaption, args = {cyborg, loc("30 minutes later...")}, swh = false})
   389   table.insert(stronglingsAnim, {func = AnimWait, args = {cyborg, 2000}})
   389   table.insert(stronglingsAnim, {func = AnimWait, args = {cyborg, 2000}})
   390   table.insert(stronglingsAnim, {func = AnimSetGearPosition, args = {dense, 1420, 1315}})
   390   table.insert(stronglingsAnim, {func = AnimSetGearPosition, args = {dense, 1420, 1315}})
   391   table.insert(stronglingsAnim, {func = AnimMove, args = {dense, "left", 1400, 0}})
   391   table.insert(stronglingsAnim, {func = AnimMove, args = {dense, "Left", 1400, 0}})
   392   table.insert(stronglingsAnim, {func = AnimCustomFunction, args = {dense, EmitDenseClouds, {stronglingsAnim, "left"}}})
   392   table.insert(stronglingsAnim, {func = AnimCustomFunction, args = {dense, EmitDenseClouds, {stronglingsAnim, "Left"}}})
   393   table.insert(stronglingsAnim, {func = AnimMove, args = {dense, "left", 1350, 0}})
   393   table.insert(stronglingsAnim, {func = AnimMove, args = {dense, "Left", 1350, 0}})
   394   table.insert(stronglingsAnim, {func = AnimOutOfNowhere, args = {cyborg, 1250, 1320}})
   394   table.insert(stronglingsAnim, {func = AnimOutOfNowhere, args = {cyborg, 1250, 1320}})
   395   table.insert(stronglingsAnim, {func = AnimRemoveState, args = {cyborg, gstInvisible}})
   395   table.insert(stronglingsAnim, {func = AnimRemoveState, args = {cyborg, gstInvisible}})
   396   table.insert(stronglingsAnim, {func = AnimGearWait, args = {cyborg, 2000}})
   396   table.insert(stronglingsAnim, {func = AnimGearWait, args = {cyborg, 2000}})
   397   table.insert(stronglingsAnim, {func = AnimSay, args = {cyborg, loc("Greetings, cloudy one!"), SAY_SAY, 3000}})
   397   table.insert(stronglingsAnim, {func = AnimSay, args = {cyborg, loc("Greetings, cloudy one!"), SAY_SAY, 3000}})
   398   table.insert(stronglingsAnim, {func = AnimSay, args = {cyborg, loc("I have come to make you an offering..."), SAY_SAY, 6000}})
   398   table.insert(stronglingsAnim, {func = AnimSay, args = {cyborg, loc("I have come to make you an offering..."), SAY_SAY, 6000}})
   428   table.insert(refusedAnim, {func = AnimWait, args = {cyborg, 700}})
   428   table.insert(refusedAnim, {func = AnimWait, args = {cyborg, 700}})
   429   table.insert(refusedAnim, {func = AnimCustomFunction, args = {dense, RefusedStart, {}}})
   429   table.insert(refusedAnim, {func = AnimCustomFunction, args = {dense, RefusedStart, {}}})
   430   table.insert(refusedAnim, {func = AnimOutOfNowhere, args = {dense, 2645, 1146}})
   430   table.insert(refusedAnim, {func = AnimOutOfNowhere, args = {dense, 2645, 1146}})
   431   table.insert(refusedAnim, {func = AnimOutOfNowhere, args = {ramon, 2218, 1675}})
   431   table.insert(refusedAnim, {func = AnimOutOfNowhere, args = {ramon, 2218, 1675}})
   432   table.insert(refusedAnim, {func = AnimOutOfNowhere, args = {spiky, 2400, 1675}})
   432   table.insert(refusedAnim, {func = AnimOutOfNowhere, args = {spiky, 2400, 1675}})
   433   table.insert(refusedAnim, {func = AnimTurn, args = {spiky, "left"}})
   433   table.insert(refusedAnim, {func = AnimTurn, args = {spiky, "Left"}})
   434   table.insert(refusedAnim, {func = AnimWait, args = {cyborg, 1700}})
   434   table.insert(refusedAnim, {func = AnimWait, args = {cyborg, 1700}})
   435   table.insert(refusedAnim, {func = AnimTurn, args = {spiky, "right"}})
   435   table.insert(refusedAnim, {func = AnimTurn, args = {spiky, "Right"}})
   436   table.insert(refusedAnim, {func = AnimWait, args = {cyborg, 1700}})
   436   table.insert(refusedAnim, {func = AnimWait, args = {cyborg, 1700}})
   437   table.insert(refusedAnim, {func = AnimTurn, args = {spiky, "left"}})
   437   table.insert(refusedAnim, {func = AnimTurn, args = {spiky, "Left"}})
   438   table.insert(refusedAnim, {func = AnimSay, args = {spiky, loc("Dude, we really need a new shaman..."), SAY_SAY, 4000}})
   438   table.insert(refusedAnim, {func = AnimSay, args = {spiky, loc("Dude, we really need a new shaman..."), SAY_SAY, 4000}})
   439   AddSkipFunction(refusedAnim, SkipRefusedAnim, {})
   439   AddSkipFunction(refusedAnim, SkipRefusedAnim, {})
   440 
   440 
   441   table.insert(refusedFinalAnim, {func = AnimSay, args = {leaks, loc("It's over..."), SAY_SAY, 2000}})
   441   table.insert(refusedFinalAnim, {func = AnimSay, args = {leaks, loc("It's over..."), SAY_SAY, 2000}})
   442   table.insert(refusedFinalAnim, {func = AnimSay, args = {leaks, loc("Let's head back to the village!"), SAY_SAY, 4000}})
   442   table.insert(refusedFinalAnim, {func = AnimSay, args = {leaks, loc("Let's head back to the village!"), SAY_SAY, 4000}})
   516 function PlaceHogs()
   516 function PlaceHogs()
   517   HogTurnLeft(leaks, true)
   517   HogTurnLeft(leaks, true)
   518 
   518 
   519   for i = 2, 9 do
   519   for i = 2, 9 do
   520     SetGearPosition(cannibals[i], unpack(cyborgPos))
   520     SetGearPosition(cannibals[i], unpack(cyborgPos))
   521     AnimTurn(cannibals[i], "left")
   521     AnimTurn(cannibals[i], "Left")
   522     cannibalDead[i] = false
   522     cannibalDead[i] = false
   523   end
   523   end
   524 
   524 
   525   SetGearPosition(cannibals[1], cannibalPos[1][1], cannibalPos[1][2])
   525   SetGearPosition(cannibals[1], cannibalPos[1][1], cannibalPos[1][2])
   526   AnimTurn(cannibals[1], "left")
   526   AnimTurn(cannibals[1], "Left")
   527 
   527 
   528   SetGearPosition(cyborg, cyborgPos[1], cyborgPos[2])
   528   SetGearPosition(cyborg, cyborgPos[1], cyborgPos[2])
   529   SetGearPosition(ramon, 2218, 1675)
   529   SetGearPosition(ramon, 2218, 1675)
   530   SetGearPosition(skiky, 2400, 1675)
   530   SetGearPosition(skiky, 2400, 1675)
   531   SetGearPosition(dense, densePos[1], densePos[2])
   531   SetGearPosition(dense, densePos[1], densePos[2])