Trigger_add_tf_player_condition

  • If you're asking a question make sure to set the thread type to be a question!

DeOntwerper

L1: Registered
Nov 20, 2013
46
1
This trigger doesn't seem to work properly...

I have two triggers set up. One with a condition of 85 (Player is forced to use melee weapons) and the other with condition TF_COND_CANNOT_SWITCH_FROM_MELEE.

The TF_COND_CANNOT_SWITCH_FROM_MELEE trigger has a duration of -1, and the condition 85 has a time of 0.1.

They both work perfectly normal if the player walks through the teleport without holding down the fire button. They get switched to melee and cannot swith out. However when they hold down the fire button they can still switch from primary to secondary and fire just as normal.

How do I stop this?

As I am wanting to create a boxing area in which is melee only, however if I put the condition 85 as -1 for duration, it makes the player small and gives them a speed boost...which I don't want....and the players can still bypass by firing before entering the tele...

EDIT:

What I've tried...

  • trigger_stun before switching to melee via a point_clientcommand (slot3)
  • trigger_add_tf_player_condition (with 85 - merasmus melee tiny/speed) - however tiny/speed are unwanted

However all of these CAN be bypassed if the player holds down the attack button...
 
Last edited:

DeOntwerper

L1: Registered
Nov 20, 2013
46
1
Anyone?

As I'd like to do it without the use of an external SM plugin or use of sv_cheats (for obvious reasons).
 

Freyja

aa
Jul 31, 2009
2,994
5,813
I would use a trigger_multiple to fire a point_clientcommand with "slot 3" or whatever the command is to force the user to switch to their melee weapon that way. It may work better.
 

chandlerj333

L1: Registered
Jan 7, 2015
21
1
I'm new here and still quite inexperienced with hammer, but is it possible to reduce their ammo count to zero? That way, they cant shoot or switch back.
 
Mar 23, 2013
1,013
347
What if you stun the player with trigger_stun bevor he touches the condition-trigger? Did you try that?