[CS GO] Disable shadow of certain player

Please post any questions about developing your plugin here. Please use the search function before posting!
Ehrmann
Junior Member
Posts: 10
Joined: Fri Apr 14, 2017 12:18 pm
Location: Moscow

[CS GO] Disable shadow of certain player

Postby Ehrmann » Wed Feb 07, 2018 10:41 pm

Hello. I want to disable shadow of certain player and return it back in the end of round. What I've try (does not work):

Syntax: Select all

Code: Select all

from players.entity import Player
from entities.constants import EntityEffects
from commands.client import ClientCommand 

@ClientCommand('shadows')
def disable_shadows(command, index, team_only=None):
    player = Player(index)
    player.effects = EntityEffects.NOSHADOW | EntityEffects.NORECEIVESHADOW
    player.call_input("DisableShadow")

I found another way, but it kill all dynamic shadows on a map:

Syntax: Select all

Code: Select all

from entities.entity import Entity
from commands.client import ClientCommand

@ClientCommand('shadows')
def disable_shadows(command, index, team_only=None):
    sh = Entity.create('env_cascade_light')
    sh.call_input('Kill')
   

Is there a way to do this?

Return to “Plugin Development Support”

Who is online

Users browsing this forum: No registered users and 17 guests