War3:Source

Development => Development and Programming Help => Topic started by: alex0310 on November 30, 2016, 07:33:52 AM

Title: [TF2] Set player invisible weapon
Post by: alex0310 on November 30, 2016, 07:33:52 AM
Hi. If someone does not know is the way to set player visibility alpha in tf2.
It works for coloring weapons, but my problem is how to change visibility of player active weapon. I tried to do this like that:
Code: [Select]
SetWeaponsIvisible(client)
{
   new weapon = GetEntPropEnt(client, Prop_Send, "m_hActiveWeapon");
   SetEntityRenderMode(weapon, RENDER_TRANSCOLOR);
   SetEntityRenderColor(weapon, 255, 255, 255, 0);
     
}
and
Code: [Select]
SetWeaponsInvisible(client)
{
   new weapon = GetEntPropEnt(client, Prop_Send, "m_hActiveWeapon");
   SetEntityRenderMode(weapon, RENDER_NONE);
but it does not work.

maybe war3source blocking this function???