Some more cleanup to map objects, allow trigger_delay and trigger_counter to be deact...
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / mapobjects / trigger / gamestart.qc
1 #include "gamestart.qh"
2
3 #ifdef SVQC
4 void gamestart_use(entity this, entity actor, entity trigger)
5 {
6         SUB_UseTargets(this, this, trigger);
7         delete(this); // TODO: deleting this means it can't be used upon map reset!
8 }
9
10 spawnfunc(trigger_gamestart)
11 {
12         this.use = gamestart_use;
13         this.reset2 = spawnfunc_trigger_gamestart;
14
15         if(this.wait)
16         {
17                 setthink(this, adaptor_think2use);
18                 this.nextthink = game_starttime + this.wait;
19         }
20         else
21                 InitializeEntity(this, adaptor_think2use, INITPRIO_FINDTARGET);
22 }
23 #endif