Exemplo n.º 1
0
        public void Tick(PlayerBase entity)
        {
            if (!entity)
            {
                return;
            }

            TeamID localPlayerTeam = Base.LocalPlayer.Team;
            TeamID entityTeam      = entity.Team;

            if (ConfigManager.CVisualGlowObjectManager.GlowActive)
            {
                if (entity.IsPlayer)
                {
                    if ((entityTeam != localPlayerTeam) && !ConfigManager.CVisualMisc.DangerZone)
                    {
                        entity.GlowRender(ConfigManager.CVisualGlowObjectManager, ConfigManager.CVisualGlowObjectManager.GlowHPActive);
                    }
                    else if ((entityTeam == localPlayerTeam) && !ConfigManager.CVisualMisc.DangerZone)
                    {
                        entity.GlowRender(new CVisualGlowObjectManager());
                    }
                    else if (ConfigManager.CVisualMisc.DangerZone)
                    {
                        entity.GlowRender(ConfigManager.CVisualGlowObjectManager, ConfigManager.CVisualGlowObjectManager.GlowHPActive);
                    }
                }

                Base.LocalPlayer.GlowUpdate(ref GlowUpdate);
            }

            if (ConfigManager.CVisualChamsColor.ChamsActive)
            {
                if ((entityTeam != localPlayerTeam) && !ConfigManager.CVisualMisc.DangerZone)
                {
                    entity.ChamsRender(ConfigManager.CVisualChamsColor, ConfigManager.CVisualChamsColor.ChamsHPActive);
                }
                else if (ConfigManager.CVisualMisc.DangerZone)
                {
                    entity.ChamsRender(ConfigManager.CVisualChamsColor, ConfigManager.CVisualChamsColor.ChamsHPActive);
                }
            }

            if (ConfigManager.CVisualMisc.RadarActive)
            {
                entity.Spotted = 1;
            }
        }