Some items for my pointshop are made using PAC so they show up for the props in Prop Hunt (obvious flaw) so I was wondering if there is a way to disable the textures (since they're all pat texture and effect items) or make them transparent.
Thanks! :P
Is Prophunt using teams?
Yes
then change youre item code!
[lua]
ITEM.Name = 'Burning Wood-Crate'
ITEM.Price = 45000
ITEM.Model = 'models/props_junk/wood_crate001a.mdl'
ITEM.Attachment = 'eyes'
function ITEM:OnEquip(ply, modifications)
if ply:IsPlayer() and (ply:IsTeam() == 1) and ply:Alive() then
ply:PS_AddClientsideModel(self.ID)
end
end
function ITEM:OnHolster(ply)
ply:PS_RemoveClientsideModel(self.ID)
end
function ITEM:ModifyClientsideModel(ply, model, pos, ang)
local Size = Vector(0.5,0.5,0.5)
local mat = Matrix()
mat:Scale(Size)
model:EnableMatrix('RenderMultiply', mat)
model:SetMaterial('models/props_halloween/scary_ghost')
local MAngle = Angle(0,0,0)
local MPos = Vector(0,0,0)
pos = pos + (ang:Forward() * MPos.x) + (ang:Up() * MPos.z) + (ang:Right() * MPos.y)
ang:RotateAroundAxis(ang:Forward(), MAngle.p)
ang:RotateAroundAxis(ang:Up(), MAngle.y)
ang:RotateAroundAxis(ang:Right(), MAngle.r)
halo.Add( {model},
Color(255,0,0),
1,
1,
1)
return model, pos, ang
end
[/lua]
Oh by the way heres a free new head for you :).
--
If the hunter team is 1 then it only gives them the hat!-- if not change that :)
Short Break:
If youre gamemode bugs with halos remove the halo :D
Read through the code he has given you and replace the way normal items are equipped with the way PAC ones are.
[code]function ITEM:OnEquip(ply, modifications)
if ply:IsPlayer() and (ply:IsTeam() == 1) and ply:Alive() then
ply:PS_AddClientsideModel(self.ID)
end
end
[/code]
Sorry, you need to Log In to post a reply to this thread.