So iv’e been trying to make models appear on players and iv’e managed to do it but whenever the player looks down, up, left or right the model seems to follow there eye position. Is there anyway to make it stay in on place but turn if the player turns like it does with pointshop?
when it firsts spawns on the player:
when the player looks down/up:
here’s my code:
local bone = LocalPlayer():LookupBone("ValveBiped.Bip01_Spine2") local matrix = LocalPlayer():GetBoneMatrix(bone) local pos = matrix:GetTranslation() local ang = matrix:GetAngles() pos = pos + LocalPlayer():GetForward() * 0 + LocalPlayer():GetRight() * 0 + LocalPlayer():GetUp() * 20 local AttachedModel=ClientsideModel("models/modified/backpack_2.mdl",RENDERGROUP_OPAQUE) AttachedModel:SetParent(LocalPlayer()) AttachedModel:SetPos(pos) AttachedModel:SetAngles(ang) AttachedModel:SetRenderOrigin(pos) AttachedModel:SetRenderAngles(ang) AttachedModel:SetupBones() AttachedModel:DrawModel() AttachedModel:SetRenderOrigin() AttachedModel:SetRenderAngles()