Jump to content
Sign in to follow this  
hypno toad

Trigger question:

Recommended Posts

I have a trigger that putts text on the screen, but it does it for all players.

How can I make it only show the text on the one players screen?

Share this post


Link to post
Share on other sites

name the player something like "soldier"

then change the condition of the trigger to

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">this && soldier in thisList

Share this post


Link to post
Share on other sites

Maybe I will have to make this MP mission into a single player one until I can make it a bit simpler.

Or maybe I could work with it.

Share this post


Link to post
Share on other sites

I have used a line like this one before so only a 1 Player can access a Radio not sure if it will work but worth a shot

in the condition

Quote[/b] ]this && player in thislist

on act

Quote[/b] ]

nul = [objNull, player] execVM "yourtextmessage.sqf"

and the just make a simple text message script.

yourtextmessage.sqf

Quote[/b] ]

hint format ["Hows Ya Bum for grubs?"];

Give it a go

GL

Odin

Share this post


Link to post
Share on other sites

Triggers are global objects, and they activate globally. This means you can't use the "Condition" box to filter where the effects take place. You need to insert further conditions in the onAct code itself.

Try using something like if !(player in list myTrigger) then exit; as the first line in your executed script.

I haven't done any scripting for ages, syntax in the above example may be wrong smile_o.gif

Share this post


Link to post
Share on other sites
...what i said works.

The trigger only activates when the player named Soldier trips it.

That's true, but it's not what hypno toad is trying to achieve. He(?) wants the effects to only execute on one client. Using the this && unitName in thisList condition will not stop the trigger executing on all clients.

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
Sign in to follow this  

×