Talk:Targetname

From Valve Developer Community
Jump to navigation Jump to search

Flashlight on at start of round (CS:S)

Could someone tell me how to make it so, that, in CS:S, at the start of every round, only the flashlights of the CT are ON. So:

  • At the start of a round, flashlights on
  • Only the one of CT's

I already figured out that you can select all players by making a Logic_auto and set OnMapSpawn, and the target to player. Thanks in advance! --CrabbyData 08:10, 13 May 2006 (PDT)

You would need to use a logical statement of if player team = counter, or similar. I'm not sure that that's possible though. --TomEdwards 08:33, 13 May 2006 (PDT)
Where should I put that? Because, I can't alter everybody's CS:S source-code to make that work... --CrabbyData 09:01, 13 May 2006 (PDT)
That's why I don't know if it's possible. --TomEdwards 09:04, 13 May 2006 (PDT)
Does CS:S support filters for trigger brush entities? That would presumably be the best way of setting up this kind of if statement. How do you go about turning on a player's flashlight for them though? point_clientcommand? --Giles 09:21, 13 May 2006 (PDT)
Perhaps the filtering would be unnecessary though, if you just stretched a trigger around the appropriate player starts and then had it delete itself after it did its job ... --Giles 09:24, 13 May 2006 (PDT)
Filtering would be nessicary because not all of them would be used. Actually you might want to find a way to delete them all after all of the team members have been spawned because having any left over because there weren't enough players on the team would cause a CT walking through one to turn their flashlight on again even though it had been turned off. But since everyone spawns at once, you could have each delete all the rest after a 1sec delay or something. --AndrewNeo 09:41, 13 May 2006 (PDT)