• Shop NPC T-Posed
    0 replies, posted
So I have "fixed" the NPC shop example but the NPC is just stuck as a t-posed. I have tried to set the model as a playermodel (which I knew would do this) but also tried a NPC model with still did this, so it has to be something in the code. Here is the code: Init.lua (only where the model stuff is put in play): [code] function ENT:Initialize( ) --This function is run when the entity is created so it's a good place to setup our entity. self:SetModel( "models/monk.mdl" ) -- Sets the model of the NPC. self:SetSolid( SOLID_BBOX ) -- This entity uses a solid bounding box for collisions. self:SetUseType( SIMPLE_USE ) -- Makes the ENT.Use hook only get called once at every use. self:SetCollisionGroup(COLLISION_GROUP_PLAYER) self:DropToFloor() end [/code]
Sorry, you need to Log In to post a reply to this thread.