Nuclide
Software Development Kit for id Tech
|
This entity represents an NSRenderableEntity with interactive surface properties. More...
#include <NSSurfacePropEntity.h>
Public Member Functions | |
void | NSSurfacePropEntity (void) |
virtual void | Spawned (void) |
Called when the entity is fulled initialized. More... | |
virtual void | SetModel (string) |
Sets the 3D model representation of the entity from a file path and name. More... | |
virtual void | Save (float) |
Handles saving a copy of this entity to a given filehandle. More... | |
virtual void | Restore (string, string) |
Similar to ::SpawnKey but for save-game fields. More... | |
virtual void | Respawn (void) |
Server: Called when the entity first spawns or when game-logic requests the entity to return to its original spawn state. More... | |
virtual void | Input (entity, string, string) |
Called when we are being prompted by another object/function with an input message. More... | |
virtual void | SpawnKey (string, string) |
This method handles entity key/value pairs on map load. More... | |
virtual void | ParentUpdate (void) |
Called when we need to re-align the entity to our parent entity. More... | |
virtual void | EvaluateEntity (void) |
Run each tic after physics are run to determine if we need to send updates over the network. More... | |
virtual float | SendEntity (entity, float) |
Called by the engine whenever we need to send a client an update about this entity. More... | |
virtual float | predraw (void) |
virtual void | ReceiveEntity (float, float) |
Client: Handles network updates from the server for the associated entity. More... | |
nonvirtual bool | IsOnFire (void) |
Returns whether or not this entity is on fire. More... | |
nonvirtual void | Ignite (entity, float, int) |
Sets the entity on fire. More... | |
nonvirtual void | Extinguish (void) |
If the entity is on fire, it'll have it extinguished. More... | |
virtual void | Pain (void) |
Called whenever the entity receives damage. More... | |
virtual void | Death (void) |
Called when the health is equal or below 0. More... | |
virtual bool | IsAlive (void) |
Returns whether or not the entity is alive. More... | |
nonvirtual bool | CanBleed (void) |
Returns whether the entity can bleed. More... | |
nonvirtual bool | IsVulnerable (void) |
Returns whether the entity can be damaged. More... | |
nonvirtual void | EnableBleeding (void) |
Makes the entity vulnerable if it wasn't already. More... | |
nonvirtual void | DisableBleeding (void) |
Makes the entity invulnerable if it wasn't already. More... | |
nonvirtual void | EnableAimAssist (void) |
Makes the entity vulnerable if it wasn't already. More... | |
nonvirtual void | DisableAimAssist (void) |
Makes the entity invulnerable if it wasn't already. More... | |
nonvirtual void | MakeVulnerable (void) |
Makes the entity vulnerable if it wasn't already. More... | |
nonvirtual void | MakeInvulnerable (void) |
Makes the entity invulnerable if it wasn't already. More... | |
nonvirtual void | SetTakedamage (float) |
Deprecated: Sets whether the entity can take damage. More... | |
nonvirtual void | SetHealth (float) |
Sets the current health of the entity. More... | |
nonvirtual void | SetMaxHealth (float) |
Sets the maximum amount of health the entity can have. More... | |
nonvirtual float | GetHealth (void) |
Returns the current health of the entity. More... | |
nonvirtual float | GetMaxHealth (void) |
Returns the maximum health the entity can have. More... | |
nonvirtual void | SetArmor (float) |
Sets the current armor of the entity. More... | |
nonvirtual float | GetArmor (void) |
Returns the current armor of the entity. More... | |
nonvirtual float | GetSpawnHealth (void) |
Returns the health the entity spawned with at map load. More... | |
nonvirtual bool | HasPropData (void) |
Returns if the entity has prop data information set. More... | |
nonvirtual __variant | GetPropData (int) |
Returns a variable type of information about the entity's prop data. More... | |
nonvirtual bool | HasSurfaceData (void) |
Returns if the entity has surface data information set. More... | |
nonvirtual __variant | GetSurfaceData (int) |
Returns a variable type of information about the entity's surface data. More... | |
nonvirtual void | SetSurfaceData (string) |
Assigns the surface data of a given description onto this entity. More... | |
nonvirtual void | SetPropData (string) |
Assigns the prop data of a given description onto this entity. More... | |
nonvirtual float | TimeSinceDeath (void) |
Returns how many seconds have passed since we died. More... | |
virtual void | DamageFeedback (NSSurfacePropEntity, NSSurfacePropEntity, int) |
Called when a different entity gets damaged by this entity. More... | |
nonvirtual void | SetPainCallback (void(void)) |
Sets which function to call upon taking pain. More... | |
nonvirtual void | SetDeathCallback (void(void)) |
Sets which function to call upon taking death. More... | |
nonvirtual bool | CanBeDamaged (void) |
Returns whether this entity reacts to damage being inflicted. More... | |
nonvirtual void | SetBloodColor (vector) |
Sets the colour of the blood of this entity. More... | |
nonvirtual vector | GetBloodColor (void) |
Returns the blood color of this entity. More... | |
virtual void | RenderFire (void) |
Called every frame to render a fire effect, but will only do so if the entity is burning. More... | |
nonvirtual vector | GetEyePos (void) |
Returns the absolute world position of where the eyes are located. More... | |
nonvirtual void | SetEyePos (vector) |
Sets the relative position of the eyes. More... | |
nonvirtual vector | GetViewAngle (void) |
Returns an euler angle of where the entity is 'looking' at. More... | |
This entity represents an NSRenderableEntity with interactive surface properties.
It can take damage and can handle variously different types of impact.
Returns whether this entity reacts to damage being inflicted.
|
virtual |
Called when a different entity gets damaged by this entity.
Called when the health is equal or below 0.
Reimplemented in func_breakable, func_guntarget, func_rot_button, NSClientPlayer, NSMonster, NSPhysicsEntity, and NSProjectile.
Makes the entity invulnerable if it wasn't already.
Makes the entity invulnerable if it wasn't already.
Makes the entity vulnerable if it wasn't already.
Run each tic after physics are run to determine if we need to send updates over the network.
Reimplemented from NSRenderableEntity.
Reimplemented in func_tracktrain, ambient_generic, speaker, NSClientPlayer, NSClientSpectator, NSMonster, NSPhysicsEntity, NSProjectile, and NSVehicle.
Returns the absolute world position of where the eyes are located.
Returns a variable type of information about the entity's prop data.
Returns the health the entity spawned with at map load.
Returns a variable type of information about the entity's surface data.
Returns an euler angle of where the entity is 'looking' at.
These are not necessarily eye values.
Returns if the entity has surface data information set.
Sets the entity on fire.
Called when we are being prompted by another object/function with an input message.
Reimplemented from NSRenderableEntity.
Reimplemented in func_door, func_guntarget, func_plat, ambient_generic, and NSMonster.
Returns whether or not the entity is alive.
Reimplemented in NSMonster.
Makes the entity invulnerable if it wasn't already.
Called whenever the entity receives damage.
Reimplemented in cycler, func_breakable, NSMonster, NSPhysicsEntity, and NSProjectile.
Called when we need to re-align the entity to our parent entity.
Reimplemented from NSEntity.
Reimplemented from NSRenderableEntity.
Reimplemented in NSClient, NSClientPlayer, NSClientSpectator, NSMonster, NSProjectile, and NSTalkMonster.
Client: Handles network updates from the server for the associated entity.
Reimplemented from NSRenderableEntity.
Reimplemented in func_tracktrain, func_tankmortar, prop_vehicle_driveable, speaker, NSClientPlayer, NSClientSpectator, NSMonster, NSPhysicsEntity, NSProjectile, NSTalkMonster, and NSVehicle.
Called every frame to render a fire effect, but will only do so if the entity is burning.
Server: Called when the entity first spawns or when game-logic requests the entity to return to its original spawn state.
Reimplemented from NSRenderableEntity.
Reimplemented in prop_static, button_target, cycler, func_breakable, func_button, func_door, func_door_rotating, func_guntarget, func_physbox, func_plat, func_platrot, func_pushable, func_rot_button, func_tank, func_tracktrain, monster_furniture, monster_generic, prop_dynamic, prop_physics, prop_static, ambient_generic, prop_physics_multiplayer, speaker, NSClientPlayer, NSMonster, NSPhysicsEntity, and NSTalkMonster.
Similar to ::SpawnKey
but for save-game fields.
Whatever you write into file handles within your ::Save()
method needs to be read back in here.
Reimplemented from NSRenderableEntity.
Reimplemented in func_breakable, func_button, func_door, func_door_rotating, func_guntarget, func_plat, func_platrot, func_pushable, func_rot_button, func_tank, func_trackchange, func_tracktrain, ambient_generic, speaker, NSClient, NSClientPlayer, NSClientSpectator, NSMonster, NSMoverEntity, NSNavAI, NSPhysicsEntity, NSProjectile, NSSquadMonster, NSTalkMonster, and NSVehicle.
Handles saving a copy of this entity to a given filehandle.
Within you want to use the ::SaveFloat() etc. methods to write the internal member attributes to the specified file handle.
Reimplemented from NSRenderableEntity.
Reimplemented in func_breakable, func_button, func_door, func_door_rotating, func_guntarget, func_plat, func_platrot, func_pushable, func_rot_button, func_tank, func_trackchange, func_tracktrain, ambient_generic, speaker, NSClient, NSClientPlayer, NSClientSpectator, NSMonster, NSMoverEntity, NSNavAI, NSPhysicsEntity, NSProjectile, NSSquadMonster, NSTalkMonster, and NSVehicle.
Called by the engine whenever we need to send a client an update about this entity.
Reimplemented from NSRenderableEntity.
Reimplemented in func_tracktrain, ambient_generic, speaker, NSClientPlayer, NSClientSpectator, NSMonster, NSPhysicsEntity, NSProjectile, NSTalkMonster, and NSVehicle.
Sets the colour of the blood of this entity.
Sets which function to call upon taking death.
Sets the maximum amount of health the entity can have.
Sets the 3D model representation of the entity from a file path and name.
Reimplemented from NSEntity.
Sets which function to call upon taking pain.
Assigns the prop data of a given description onto this entity.
Assigns the surface data of a given description onto this entity.
Deprecated: Sets whether the entity can take damage.
Called when the entity is fulled initialized.
Any spawn key/value info pairs have already been dealt with. So now we can make full decisions on the entity. Always make sure to call super::Spawned();
inside your method when overriding.
Reimplemented from NSEntity.
Reimplemented in prop_static, func_breakable, func_button, func_door, func_door_rotating, func_guntarget, func_plat, func_pushable, func_tank, func_trackchange, func_tracktrain, ambient_generic, func_tankmortar, prop_vehicle_driveable, speaker, NSMonster, NSPhysicsEntity, NSProjectile, and NSSquadMonster.
This method handles entity key/value pairs on map load.
You can easily convert the strValue
parameter using the ReadFloat etc. methods that are part of NSIO.
Reimplemented from NSRenderableEntity.
Reimplemented in prop_static, func_breakable, func_button, func_door, func_door_rotating, func_guntarget, func_physbox, func_plat, func_platrot, func_pushable, func_rot_button, func_tank, func_trackchange, func_tracktrain, prop_dynamic, prop_physics, ambient_generic, prop_physics_multiplayer, speaker, NSMonster, NSMoverEntity, NSPhysicsEntity, NSProjectile, NSSquadMonster, and NSTalkMonster.
Returns how many seconds have passed since we died.
Will return -1 if not applicable.