Hello again,
While figuring the addactions i found out a way to give people with the decent GUID to get an addaction tru the Epoch.Atlis mission.
init.sqf //Mission pbo
event = false; publicVariable "event";
waitUntil {!(isNull (findDisplay 46))};
if ((getPlayerUID player) in ["MY ID"]) then {
systemChat "Adding event";
removeAllActions player;
waitUntil {!isNull player};
while {true} do {
waitUntil {sleep 1.5; alive player};
player addaction ["Start Event", "start.sqf","",5,false,true,"",""];
waitUntil {sleep 1.5; !alive player};
};
};
it calls another script in the altis.mission
wich basicly sets a public variable to true,
start.sqf //mission pbo
systemChat "Starting event"; event = true; publicVariable "event";
Then in my @epochHive
it should see this if im not wrong thats its set to True
and run this
if (isServer) then {
if (event)then {
[] execVM "x\addons\custom\serverside\test.sqf";
};
};
This file is called test.sqf
and i got an init.sqf calling this file in the addon.
Now my question is
When i set
event = false; publicVariable "event";
to true at the start of the server it runs the code in @epochHive
but when i try to set it to true with the addaction running a script setting it true it doesnt seem to work.
Im probably just missing something small i guess. I hope you guys understand what i mean otherwise ask! ill try to explain it better haha.
Only yesterday i learned about AddpublicEventHandelers and Public variables so its still a bit fresh
greetz FlyX

