CTakeDamageInfo.GetDamageForce

From GMod Wiki

Jump to: navigation, search
Function
Syntax CTakeDamageInfo:GetDamageForce( )
Description:
Gets the directional force of the damage.
Returns: Vector
In Object: Ctakedamageinfo
Realm: NewerShared.png
BBCode Link: [b][url=http://wiki.garrysmod.com/?title=CTakeDamageInfo.GetDamageForce]CTakeDamageInfo.GetDamageForce [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b]



Example

DescriptionThis prints to console the directional force taken on an entity.
Used onNewerServer.png
Code
function ENT:OnTakeDamage( dmginfo )
	Msg( "Force:\t" .. tostring(dmginfo:GetDamageForce()) .. "\n" )
end
 
OutputThe directional force damage taken on an entity.


See Also

Personal tools
Namespaces
Variants
Actions
Navigation
Lua Scripting
Functions
Hooks
Toolbox