I've been trying to get a playermodel to work for my server. I haven't done any other playermodels before so this is new to me. I have gotten a weapon to work though. I'm trying to get an Ahri playermodel to work. It works for me on the server but when my friends try to get it to work it's just a huge ERROR. I don't think it's a problem with the fastDL though, because it downloads. And I even had them subscribe to my collection. But it's still an error just for them. Here is the code for the pointshop ahri file.
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
ITEM.Name = 'Ahri'
ITEM.Price = 750
ITEM.Model = 'C:/steamcmd/gmod/garrysmod/gamemodes/terrortown/content/models/player_ahri.mdl'
function ITEM:OnEquip(ply, modifications)
if not ply._OldModel then
ply._OldModel = ply:GetModel()
end
timer.Simple(1, function() ply:SetModel(self.Model) end)
end
function ITEM:OnHolster(ply)
if ply._OldModel then
ply:SetModel(ply._OldModel)
end
end
function ITEM:PlayerSetModel(ply)
ply:SetModel(self.Model)
end
-----------------------------------------------------------------------------------------------------------------------------------------------------
Any help would be appreciated. Thanks.
EDIT: Kleiner who is a pre setup playermodel uses this exact code (except for the file location, name, and price), and he works just fine for my friends and I.
Change the file location to be relative to garrysmod/; don't include anything before that. Notice how the Kleiner model's path starts from models/.
Sorry, you need to Log In to post a reply to this thread.