Entity scripting question


(Loffy) #21

In the timelimit_hit (last part), why setwinner -1 and not 0 (axis)?
Have you tried inserting wm_announce “This is part X of the script and it is run now!” here and there. So you can see on screen that all parts of the script is run?:


 trigger timelimit_hit
   {
wm_announce "This is part timelimit_hit, the TOP, and it is run now!"
      wm_setwinner -1
      //trigger game_manager axis_win
      //wm_announce "^1AXIS WIN !!!"
      //wait 1000
      wm_teamvoiceannounce 0 sound/katastrophie/03brag16.wav
      //wait 1000
      wm_teamvoiceannounce 1 sound/katastrophie/01taunt13.wav
      //wait 5000
      wm_setwinner 0
      //wait 500
      wm_endround
wm_announce "This is part timelimit_hit, the BOTTOM, and it is run now!"
   } 


(Shaderman) #22

g_scriptDebug 1 could help.


(=PoW= Kernel 2.6.5) #23

In the posts above it was mentioned to set the winner to -1 otherwise the script won’t run at all.

What I was trying to do was have a few voice announcements and some text onscreen BEFORE the intermission screen.
It seems like the timelimit_hit trigger is only activated AFTER the intermission screen.

Can anyone confirm/deny this?

That’s what happens in Oasis when the called the script for the tank to drive up to the base.
It is already in the intermission screen.

Using the script I posted most recently, the team do get to hear the messages after the intermission screen appears so that’s good enough.

It would be good to see how to do it BEFORE the intermission screen.
Perhaps a script with a wait that resumes just before time expires in the round?