Below is a script I've just made for my game, and have tested it and it works. (To a degree, it would be better to have a per level setup file if anyone at TGC is watching
).
;Artificial Intelligence Script
;Header
desc = All Change
;Triggers
:state=0,plrwithinzone=1:timerstart,state=1
; Time delay to make sure the global script has finished running
:state=1,timergreater=100:state=2
; Setup the level
:state=2:sky=skybank\scifi\Spc
:state=2:music=audiobank\music\User\evil-pulse-complete.wav,musicvolume=50,soundscale=25
:state=2:fog=0,fogred=0,foggreen=0,fogblue=0
:state=2:ambience=100,ambiencered=255,ambiencegreen=255,ambienceblue=255,state=3
Firstly, Put this trigger so that it will trigger as soon as the player starts the level. One of the problems I had was the global startup script seemed to run after my trigger. So you will see in that script there is a time delay of 1/10th of a second before it trys to set everything up. On my system it seems to be long enough. You may need to make it longer on others.
Next the sky in the script is taken up at the level start I think so you cannot have more than 1 sky command run per level. I need to do more investigation to sort this out.
The music will cause a momentary pause (I assume while it's loading) but it's only a flicker and I expect it depends on the size of the .wav file loading)
Jas
----
"What is this talk of 'release'? Klingons do not'release' software. It escapes leaving a bloody trail of developers and quality assurance people in its wake!"