Murder gamemode. How to make murderer can disguise playermodels when using pointshop1 models?

When murderer disguise on dead players corpse
it just change names and colors. (if playermodel is default citizens then cloths colors too)

But i’m using pointshop1 and murderer can’t distuise corpse’s playermodel
when dead players were using custom playermodel by pointshop.

I tryed to add playermodel lua scripts clumsy…

sv_player.lua
563 ~ 572



	// disguise as ragdolls
	if IsValid(tr.Entity) && tr.Entity:GetClass() == "prop_ragdoll" && tr.HitPos:Distance(tr.StartPos) < 80 then
		if ply:GetMurderer() && ply:GetLootCollected() >= 1 then
			if tr.Entity:GetBystanderName() != ply:GetBystanderName() || tr.Entity:GetPlayerColor() != ply:GetPlayerColor() || tr.Entity:GetPlayerModel() != ply:GetPlayerModel() then 
				ply:MurdererDisguise(tr.Entity)
				ply:SetLootCollected(ply:GetLootCollected() - 1)
				return
			end
		end
	end


sv_player
602~617



function PlayerMeta:MurdererDisguise(copyent)
	if !self.Disguised then
		self.DisguiseColor = self:GetPlayerColor()
		self.DisguiseName = self:GetBystanderName()
		self.PlayerModel = self:GetPlayerModel()
	end
	if GAMEMODE.CanDisguise:GetBool() then
		self.Disguised = true
		self.DisguisedStart = CurTime()
		self:SetBystanderName(copyent:GetBystanderName())
		self:SetPlayerColor(copyent:GetPlayerColor())
		self:SetPlayerModel(copyent:GetPlayerModel())
	else
		self:UnMurdererDisguise()
	end
end


sv_player
619~630



function PlayerMeta:UnMurdererDisguise()
	if self.Disguised then
		self:SetPlayerColor(self.DisguiseColor)
		self:SetBystanderName(self.DisguiseName)
		self:PlayerModel(self.PlayerModel)
	end
	self.Disguised = false
end

function PlayerMeta:GetMurdererDisguised()
	return self.Disguised and true or false
end


Of course it dosen’t work.

How to make murderer can disguise playermodels…?

GetModel, not GetPlayerModel ?

There is no GetModel…

use these instead

O h my god, it works!! Than you!!!