25#define CENVGLOBAL_CVAR "env_global_data"
55 TOUCHFILTER_FRIENDLIES,
56 TOUCHFILTER_CLIENTSINVEHICLES,
57 TOUCHFILTER_EVERYTHING,
60 TOUCHFILTER_CLIENTSNOTINVEHICLES,
62 TOUCHFILTER_NPCSINVEHICLES,
89 virtual void Touch(entity);
95 virtual void SpawnKey(
string,
string);
99 virtual void Save(
float);
100 virtual void Restore(
string,
string);
102 virtual void Input(entity,
string,
string);
105 nonvirtual
void SetValue(
int newValue);
111 virtual void Trigger(entity, triggermode_t);
159 nonvirtual
void SetTeam(
float);
162 nonvirtual
float GetTeam(
void);
171 float m_timeSinceLastTouch;
173 entity m_touchingEntity;
174 vector m_touchPosition;
175 vector m_touchNormal;
177 nonvirtual
void _TouchHandler(
void);
178 nonvirtual
void _BlockedHandler(
void);
182 string m_globalState;
183 string m_triggerKillTarget;
184 string m_triggerMessage;
188 bool m_triggerEnabled;
189 bool m_triggerStartsDisabled;
190 bool m_triggerSpawnflagFilter;
192 float m_touchingOnlyTeam;
195 float m_triggerDelay;
This class is responsible for handling core entity functionality.
Definition: IO.h:78
ncTrigger handles all the non-input as well as Legacy (Quake, GoldSource) style trigger behaviour.
Definition: Trigger.h:77
nonvirtual bool TriggerEnabled(void)
Returns whether the trigger functionality of this entity is enabled.
Definition: Trigger.qc:292
virtual int GetValue(entity)
Returns what we will pass onto other's ncTrigger::GetMaster() calls if we're their master.
Definition: Trigger.qc:166
virtual void Blocked(entity)
Called whenever out movement is being blocked by an entity.
Definition: Trigger.qc:451
void ncTrigger(void)
Definition: Trigger.qc:18
nonvirtual void UseTargets(entity, int, float)
When called will trigger its legacy targets with a given delay.
Definition: Trigger.qc:98
nonvirtual entity GetTargetEntity(void)
Returns the first entity named after the target field.
Definition: Trigger.qc:250
nonvirtual float GetTeam(void)
Retrives the team value of a given entity.
Definition: Trigger.qc:407
virtual void Input(entity, string, string)
Called when we are being prompted by another object/function with an input message.
Definition: Trigger.qc:368
nonvirtual void SetTriggerTarget(string)
Sets the legacy target for this entity.
Definition: Trigger.qc:154
nonvirtual void EnableTrigger(void)
Definition: Trigger.qc:274
nonvirtual float GetTriggerDelay(void)
Returns the time until this triggers is scheduled to fire its targets, relative time in seconds.
Definition: Trigger.qc:232
nonvirtual globalstate_t GetGlobalValue(string)
Returns the value of a given env_global property.
Definition: Trigger.qc:172
nonvirtual vector GetTouchNormal(void)
Returns the normal of the last valid surface the entity has touched.
Definition: Trigger.qc:487
virtual void StartTouch(entity)
Called when we started touching another entity.
Definition: Trigger.qc:469
nonvirtual void DisableTrigger(void)
Definition: Trigger.qc:280
nonvirtual void SetValue(int newValue)
Sets the internal value of the entity as queried by GetValue().
Definition: Trigger.qc:160
virtual bool CanBeTriggeredBy(entity)
Definition: Trigger.qc:43
nonvirtual bool HasTargetname(void)
Returns TRUE if the entity has a name that can be used for messaging.
Definition: Trigger.qc:265
virtual void EndTouch(entity)
Called when we stopped touching the last touched entity.
Definition: Trigger.qc:475
nonvirtual bool HasTriggerTarget(void)
Returns TRUE if the entity has a legacy trigger target.
Definition: Trigger.qc:259
virtual void Trigger(entity, triggermode_t)
Called whenever we're legacy triggered by another object or function.
Definition: Trigger.qc:92
virtual void SpawnKey(string, string)
This method handles entity key/value pairs on map load.
Definition: Trigger.qc:414
nonvirtual vector GetTouchPosition(void)
Returns the last valid point the entity has touched.
Definition: Trigger.qc:481
nonvirtual string GetTriggerKillTarget(void)
Returns the name of the entity group it will remove from the game upon trigger.
Definition: Trigger.qc:244
virtual void Spawned(void)
Called when the entity is fulled initialized.
Definition: Trigger.qc:35
nonvirtual string GetTriggerTarget(void)
Returns the name of the entity group it can trigger (legacy style).
Definition: Trigger.qc:226
nonvirtual string GetTriggerMessage(void)
Returns the message which will be displayed upon trigger.
Definition: Trigger.qc:238
virtual void Restore(string, string)
Similar to ncIO::SpawnKey() but for save-game fields.
Definition: Trigger.qc:317
virtual void Touch(entity)
Called whenever we're touching another entity.
Definition: Trigger.qc:463
nonvirtual void SetTeam(float)
Assigns the entity to a given team value.
Definition: Trigger.qc:395
nonvirtual void ToggleTrigger(void)
Definition: Trigger.qc:286
virtual void Save(float)
Handles saving a copy of this entity to a given filehandle.
Definition: Trigger.qc:298
nonvirtual int GetMaster(entity)
Returns whether our master allows us to be triggered.
Definition: Trigger.qc:193
typedef enumflags
Defines the valid alignment flags for text fields.
Definition: font.h:37