OFPEC Forum
Editors Depot - Mission Editing and Scripting => ArmA - Editing/Scripting Multiplayer => Topic started by: laggy on 20 Mar 2009, 15:46:58
-
If I create a local radio trigger i.e:
if (local player) then
{
trigger1 = createTrigger ["EmptyDetector", position player];
trigger1 setTriggerActivation ["ALPHA", "", true];
trigger1 setTriggerArea [0, 0, 0, false];
trigger1 setTriggerStatements ["this", "BlaBlaBla", ""];
trigger1 setTriggerText "BlaBlaBla";
}
Will this trigger create only local effects, just seen by using player if I use it for hints or sidechat?
What I'm planning to do is to have that trigger start a chat or hint, that shows how many units are left in friendly groups and also reveal those friendlies.
I only want that information to be shown to the player that calls for it obviously.
Cheers.
-
A script-created trigger is indeed entirely local, unlike a mission-editor placed trigger.
However, your code will only run for SP or the host in MP, since it doesn't take into account the fact that a JIP player doesn't have a player object at the start of the game:
if (not (isServer and (isNull player))) then
-
Thx again.