<Effect name="Thunderstorm variables">
<Param name="Note3" dispName="Settings" VarType="string">inactiv, NOT LOOPED, </Param>
<Param name="Note4" dispName="Condition" VarType="string">Always</Param>
<Command>}</Command>
<Command>}</Command>
<Command>/**/ float time=0;</Command>
<Command>/**/ int lightning1=0;</Command>
<Command>/**/ int lightning1time=0;</Command>
<Command>/**/ int lightning2=0;</Command>
<Command>/**/ int lightning2time=0;</Command>
<Command>rule _DeclareGlobalsEnd</Command>
<Command>inactive</Command>
<Command>{</Command>
<Command>if (1==1) {</Command>
</Effect>
<Effect name="Thunderstorm">
<Command>time = time + 1;</Command>
<Command>if(Math_mod(time, 10) == 0) {</Command>
<Command>trSoundPlayFN("\cinematics\23_out\darksky.mp3","1", -1, "","icons/");</Command>
<Command>trSoundPlayFN("\cinematics\23_out\ankh.mp3","1", -1, "","icons/");</Command>
<Command>}</Command>
<Command>if(Math_mod(time,16) == 0) {</Command>
<Command>trSoundPlayFN("\cinematics\23_out\darksky.mp3","1", -1, "","icons/");</Command>
<Command>trSoundPlayFN("lightningbirth.wav","1", -1, "","icons/");</Command>
<Command>}</Command>
<Command>if(Math_mod(time,26) == 0) {</Command>
<Command>trSoundPlayFN("\cinematics\31_out\rocktumble.mp3","1", -1, "","icons/");</Command>
<Command>trSoundPlayFN("lightthunder.wav","1", -1, "","icons/");</Command>
<Command>}</Command>
<Command>if(Math_mod(time, 22) == 0) {</Command>
<Command>trSoundPlayFN("\cinematics\23_out\ankh.mp3","1", -1, "","icons/");</Command>
<Command>trSoundPlayFN("\cinematics\32_out\explosion.mp3","1", -1, "","icons/");</Command>
<Command>trSoundPlayFN("meteorbighit.wav","1", -1, "","icons/");</Command>
<Command>trSoundPlayFN("lightningstrike2.wav","1",-1,"","icons/");</Command>
<Command>trSoundPlayFN("lightningstrike3.wav","1",-1,"","icons/");</Command>
<Command>}</Command>
<Command>if(Math_mod(time, 7) == 0) {</Command>
<Command>trSoundPlayFN("rainloop.wav","1", -1, "","icons/");</Command>
<Command>}</Command>
<Command>if(Math_mod(time,7) == 0) {</Command>
<Command>trSoundPlayFN("ambientwind.wav","1", -1, "","icons/");</Command>
<Command>}</Command>
<Command>if(Math_mod(time,25) ==0) {</Command>
<Command>sunColor(255,255,255);</Command>
<Command>ambientColor(190,190,255);</Command>
<Command>subModeEnter("Simulation", "Editor");</Command>
<Command>uiMessageBox("moo","setSunPosition(45,120,false)");</Command>
<Command>uiCycleCurrentActivate();</Command>
<Command>subModeLeave("Simulation", "Editor");</Command>
<Command>modeEnter("pregame");</Command>
<Command>modeEnter("Simulation");</Command>
<Command>subModeEnter("Simulation", "Singleplayer");</Command>
<Command>trSetLighting("Erebus",0.25);</Command>
<Command>lightning1 = 1;</Command>
<Command>lightning1time = 0;</Command>
<Command>}</Command>
<Command>if(Math_mod(time,31) ==0) {</Command>
<Command>sunColor(190,255,255);</Command>
<Command>ambientColor(60,140,190);</Command>
<Command>subModeEnter("Simulation", "Editor");</Command>
<Command>uiMessageBox("moo","setSunPosition(15,180,false)");</Command>
<Command>uiCycleCurrentActivate();</Command>