Garry's Mod Wiki

GM:PlayerSetHandsModel

GM:PlayerSetHandsModel( Player ply, Entity ent )

Description

Called whenever view model hands needs setting a model. By default this calls PLAYER:GetHandsModel and if that fails, sets the hands model according to his player model.

Arguments

1 Player ply
The player whose hands needs a model set
2 Entity ent
The hands to set model of

Example

Sets the players hands to the model's hands.

function GM:PlayerSetHandsModel( ply, ent ) local simplemodel = player_manager.TranslateToPlayerModelName(ply:GetModel()) local info = player_manager.TranslatePlayerHands(simplemodel) if info then ent:SetModel(info.model) ent:SetSkin(info.skin) ent:SetBodyGroups(info.body) end end

Page Links


Special Pages


Wikis

?

Render Time: 74ms

DB GetPage 35
Generate Html 7
SaveChanges (1) 23
Render Body 0
Render Sidebar 7