Entity.GetSkin

From GMod Wiki

Revision as of 17:04, 9 December 2010 by Joerdgs (Talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
Function
Syntax Entity:GetSkin( )
Description:
Returns the skin number the entity is using.
Returns: Integer
In Object: Entity
Realm: NewerShared.png
BBCode Link: [b][url=http://wiki.garrysmod.com/?title=Entity.GetSkin]Entity.GetSkin [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b]



Examples

DescriptionPrints the skin of all prop_physics's
Used onNewerShared.png
Code
for k, v in pairs ( ents.FindByClass( "prop_physics" ) ) do --For all the prop_physics...
    MsgN( Format( "Prop_physics %i has skin %i!", k, v:GetSkin() ) ) --Print skin number!
end
OutputE.G. "Prop_physics 6 has skin 2!"


Additional Notes

See Also

Personal tools
Namespaces
Variants
Actions
Navigation
Lua Scripting
Functions
Hooks
Toolbox