int GetTeamNumber()
Get the team number of this entity.
handle GetChildren()
Get the entities parented to this entity.
bool IsNPC()
Is this entity an CAI_BaseNPC?
void SetAngularVelocity(float pitchVel, float yawVel, float rollVel)
Set the local angular velocity - takes float pitch,yaw,roll velocities
void SetMaxHealth(int amt)
Set the maximum health of this entity.
void SetLocalScale(float flScale)
void DeleteAttribute(string pName)
Delete an entity attribute.
int GetSpawnGroupHandle()
Returns the spawn group handle of this entity
void SetLocalOrigin(Vector origin)
Set entity local origin from a Vector
Vector TransformPointWorldToEntity(Vector vPoint)
Returns the input Vector transformed from world to entity space
void SetContextThink(string pszContextName, handle hThinkFunc, float flInterval)
Set a think function on this entity.
void Attribute_SetIntValue(string pName, int nValue)
Set int value for an entity attribute.
bool HasAttribute(string pName)
See if an entity has a particular attribute.
int Attribute_GetIntValue(string pName, int nDefault)
Get int value for an entity attribute.
Vector GetBoundingMaxs()
Get a vector containing max bounds, centered on object.
Vector GetCenter()
Get vector to center of object - absolute coords
handle GetOwner()
Gets this entity's owner
void SetConstraint(Vector vPos)
Set the position of the constraint.
table GetContext(string name)
GetContext( name ): looks up a context and returns it if available. May return string, float, or null (if the context isn't found).
void SetMass(float flMass)
Set the mass of an entity. (does nothing if it doesn't have a physics object)
void SetAbsScale(float flScale)
void OverrideFriction(float duration, float friction)
Takes duration, value for a temporary override.
void SetEntityName(string pName)
Set the name of an entity.
Vector GetUpVector()
Get the up vector of the entity.
void RemoveEffects(int nFlags)
RemoveEffects( int ): Removes the render effect flag.
void SetLocalAngles(float fPitch, float fYaw, float fRoll)
Set entity local pitch, yaw, roll by component
void Attribute_SetFloatValue(string pName, float flValue)
Set float value for an entity attribute.
Vector GetBaseVelocity()
Get Base? velocity.
void GatherCriteria(handle hResult)
Returns a table containing the criteria that would be used for response queries on this entity. This is the same as the table that is passed to response rule script function callbacks.
void Trigger()
Fires off this entity's OnTrigger responses.
QAngle GetLocalAngles()
Get entity local pitch, yaw, roll as a QAngle
void SetHealth(int nHealth)
Set the health of this entity.
void EmitSound(string soundname)
Plays a sound from this entity.
float Attribute_GetFloatValue(string pName, float flDefault)
Get float value for an entity attribute.
Vector GetAngularVelocity()
Get the local angular velocity - returns a vector of pitch,yaw,roll
int TakeDamage(handle hInfo)
Apply damage to this entity. Use CreateDamageInfo() to create a damageinfo object.
Vector TransformPointEntityToWorld(Vector vPoint)
Returns the input Vector transformed from entity to world space
void SetForwardVector(Vector v)
Set the orientation of the entity to have this forward vector.
void SetContextNum(string pName, float fValue, float duration)
SetContextNum( name , value, duration ): store any key/value pair in this entity's dialog contexts. Value must be a number (int or float). Will last for duration (set 0 to mean 'forever').
void EmitSoundParams(string soundname, int nPitch, float flVolume, float flDelay)
Plays/modifies a sound from this entity. changes sound if nPitch and/or flVol or flSoundTime is > 0.
void ApplyLocalAngularVelocityImpulse(Vector angImpulse)
Apply an Ang Velocity Impulse
int GetMaxHealth()
Get the maximum health of this entity.
void PrecacheScriptSound(string soundname)
Precache a sound for later playing.
QAngle GetLocalAngularVelocity()
Maybe local angvel
void ApplyAbsVelocityImpulse(Vector vecImpulse)
Apply a Velocity Impulse
Vector GetLocalVelocity()
Get Entity relative velocity.
int GetHealth()
Get the health of this entity.
QAngle EyeAngles()
Get the qangles that this entity is looking at.
void SetVelocity(Vector vecVelocity)
string GetModelName()
Returns the name of the model.
void SetContext(string pName, string pValue, float duration)
SetContext( name , value, duration ): store any key/value pair in this entity's dialog contexts. Value must be a string. Will last for duration (set 0 to mean 'forever').
Vector GetRightVector()
Get the right vector of the entity.
Vector GetAnglesAsVector()
Get entity pitch, yaw, roll as a vector.
Vector GetForwardVector()
Get the forward vector of the entity.
void SetAbsAngles(float fPitch, float fYaw, float fRoll)
Set entity pitch, yaw, roll by component.
bool IsPlayer()
Is this entity a player?
bool IsAlive()
Is this entity alive?
void SetParent(handle hParent, string pAttachmentname)
Set the parent for this entity.
table GetBounds()
Get a table containing the 'Mins' & 'Maxs' vector bounds, centered on object.
void AddEffects(int nFlags)
AddEffects( int ): Adds the render effect flag.
Vector GetBoundingMins()
Get a vector containing min bounds, centered on object.
Vector EyePosition()
Get vector to eye position - absolute coords.
void SetAngles(float fPitch, float fYaw, float fRoll)
Set entity pitch, yaw, roll by component.
void SetGravity(float flGravity)
Set PLAYER gravity, ignored for objects.
handle GetOwnerEntity()
Get the owner entity, if there is one
void SetFriction(float flFriction)
Set PLAYER friction, ignored for objects.
Vector GetLocalOrigin()
Get entity local origin as a Vector
handle GetMoveParent()
If in hierarchy, retrieves the entity's parent.
handle GetRootMoveParent()
If in hierarchy, walks up the hierarchy to find the root parent.
void StopSound(string soundname)
Stops a named sound playing from this entity.
void SetOwner(handle pOwner)
Sets this entity's owner
float GetMass()
Get the mass of an entity. (returns 0 if it doesn't have a physics object)
void ValidatePrivateScriptScope()
Validates the private script scope and creates it if one doesn't exist.
float GetSoundDuration(string soundname, string actormodel)
Returns float duration of the sound. Takes soundname and optional actormodelname.
void SetAbsOrigin(Vector origin)
int GetTeam()
Get the team number of this entity.
void SetTeam(int iTeamNum)
void FollowEntity(handle hEnt, bool bBoneMerge)
hEntity to follow, bool bBoneMerge