OFPEC Forum
Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting Multiplayer => Topic started by: GingaWRATH on 09 Jul 2005, 14:37:46
-
I have this trigger
Con: !alive player
onact: [] exec "script.sqs"
this triggers is Local, and I have publicvariables in the .sqs
and want the sqs to run on all machines but need to use this condition.
is there anyway of making !alive player Or a Trigger Public.
-
Basically I want All clients on the server to see any msgs.
Im using Globalchat for my msgs but only the Player who died sees anything.
-
1) attach a killed eventhandler to the Players
2) When killed have the eventhandler make a boolean true and publicvariable it
3) Have a trigger waiting on that boolean to become true
4) Have the activation field of the trigger run a script
5) For repeating purposes, have the trigger script reset the boolean to false
eg
INIT.SQS
tx_dead = false
player addEventHandler ["killed", {tx_dead = true; Publicvariable "tx_dead"}]
TRIGGER
Activated by: Nobody
Set To: Repeatedly
Condition: tx_dead
On activation: [] exec "Alive.sqs"
Alive.sqs
tx_dead = false
add your own lines of code here
exit
-
Brilliant Worx great Thanx Now I can goto sleep.. ;D