Xonotic QuakeC
The free, fast arena FPS with crisp movement and a wide array of weapons
relay.qc
Go to the documentation of this file.
1#include "relay.qh"
2#ifdef SVQC
3
4void relay_use(entity this, entity actor, entity trigger)
5{
6 if(this.active != ACTIVE_ACTIVE)
7 return;
8
9 SUB_UseTargets(this, actor, trigger);
10}
11
12/*QUAKED spawnfunc_trigger_relay (.5 .5 .5) (-8 -8 -8) (8 8 8)
13This fixed size trigger cannot be touched, it can only be fired by other events. It can contain killtargets, targets, delays, and messages.
14*/
15spawnfunc(trigger_relay)
16{
17 this.active = ACTIVE_ACTIVE;
18 this.use = relay_use;
19 this.reset = spawnfunc_trigger_relay; // this spawnfunc resets fully
20}
21
22spawnfunc(target_relay)
23{
24 spawnfunc_trigger_relay(this);
25}
26
27spawnfunc(target_delay)
28{
29 if(!this.wait)
30 this.wait = 1;
31 if(!this.delay)
32 this.delay = this.wait; // fall back to quake 3 field
33 spawnfunc_trigger_relay(this);
34}
35#endif
var entity(vector mins, vector maxs,.entity tofield) findbox_tofield_OrFallback
float delay
Definition items.qc:17
float wait
Definition items.qc:17
#define use
int active
Definition defs.qh:34
const int ACTIVE_ACTIVE
Definition defs.qh:37
void SUB_UseTargets(entity this, entity actor, entity trigger)
Definition triggers.qc:344
void relay_use(entity this, entity actor, entity trigger)
Definition relay.qc:4
#define spawnfunc(id)
Definition spawnfunc.qh:96