From e895aff152d8a382c586f3be907dc8d2abda295a Mon Sep 17 00:00:00 2001 From: icedream Date: Sat, 21 Dec 2013 20:49:53 +0100 Subject: [PATCH] SetColor also needs application of skin from player. Fixes #6 again. --- lua/weapons/disguiser/init.lua | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lua/weapons/disguiser/init.lua b/lua/weapons/disguiser/init.lua index c00cb3b..aa53855 100644 --- a/lua/weapons/disguiser/init.lua +++ b/lua/weapons/disguiser/init.lua @@ -348,9 +348,12 @@ hook.Add("PlayerDeath", "Disguiser.ThirdPersonDeath", function(victim, inflictor // fake entity for spectacular death! local dentity = ents.Create("prop_physics") dentity:SetModel(victim:GetModel()) + if !!victim:GetSkin() then + dentity:SetSkin(victim:GetSkin()) + end + dentity:SetColor(victim:GetColor()) dentity:SetAngles(victim:GetAngles()) dentity:SetPos(victim:GetPos()) - dentity:SetColor(victim:GetColor()) dentity:SetVelocity(victim:GetVelocity()) local physics = victim:GetPhysicsObject() dentity:SetBloodColor(BLOOD_COLOR_RED) -- this thing was alive, ya know? :(