Jump to content
FoxtrotF

What's wrong with Triggers

Recommended Posts

Hello guys, I experience wired problems with trigger lost about ~2 hours, and unable to figure out what is wrong

I'm placing 10x10 trigger /Anybody / Present

Condition: (player in thisList) || (heli_1 in thisList) || (heli_4 in thisList)

On Activation, no matter what on activation hint "trigger area" or play "Car Alarm" sound effect, nothing happens when I'm entering trigger area with a player. It tends to work more or less correctly if I leave just (player in thisList) in condition, I didn't have any problem with such conditions in past, also seems that activation / present none / none absolutely not working in any circumstances.

Share this post


Link to post
Share on other sites

It seems to me one or both heli_1, heli_4 doesn't exist. Check that. If you spawned them, it's better to publicVariable their name (MP).

Also, "in" command is case sensitive (not in this case).

Share this post


Link to post
Share on other sites
1 hour ago, pierremgi said:

Also, "in" command is case sensitive.

 

It's not, the in command doesn't care about upper/lower case, case sensitivity is only needed for comparing strings:

"test" in ["Test","TEST"];//false
"Test" in ["Test","TEST"];//true

In the example made by the thread author there's no case sensitivity involved:

(player in thisList) || (heli_1 in thisList) || (heli_4 in thisList)
//same as
(pLaYeR in thisList) || (hElI_1 in thisList) || (HeLi_4 in thisList) 

 

Cheers

  • Like 1

Share this post


Link to post
Share on other sites

My bad. Check if your heli_1 and/or heli_4 exist everywhere the trigger can fire. if not, the condition will fail silently (error), no matter the position of player.

Share this post


Link to post
Share on other sites

I've had trouble with triggers recently and have stopped using them, replacing them with my own, coded analogue.

  • Like 1

Share this post


Link to post
Share on other sites
1 hour ago, Tankbuster said:

I've had trouble with triggers recently and have stopped using them, replacing them with my own, coded analogue.


#metoo :hm:

If I mess with the fields, changing parameters, etc. they break. Putting down new and starting over fixes it.

Share this post


Link to post
Share on other sites

Thank you guys for the reply!

I figured this strange issue, one of the heli unit was with 0 health on init, but this was not the case, after files verification everything seems to be ok and behave as usual.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×