RS30002 28 Posted June 8, 2022 Hi...ive got a problem trigger gives player a task 0 = [] spawn { [resistance,["taskSchedule"],["Get more information about the guard activity","Steal the guard schedule",""], getPosATL schedule ,1,2,true,"search"] call BIS_fnc_taskCreate; waitUntil {ScheduleTaken}; ["taskSchedule", "SUCCEEDED",true] spawn BIS_fnc_taskSetState; }; all is well, task is assigned...but when i go to collect with the following code in the object's init and the idea it switches on "ScheduleTaken", nothing happens ScheduleTaken = false; call{this addAction ["Take Guard Schedule", {hint format ["Guard Schedule Taken"]; DeleteVehicle (_this select 0) select 0;}, [], 6, true, true, "", "", 6]; ScheduleTaken == true}; Tried a lot of variations of bracketing and where i put ScheduleTake == true...but couldn't get it to interact with each other so that the task completes🙁 Any suggestions would be much appreciated! Thanks in advance Share this post Link to post Share on other sites
sarogahtyp 1109 Posted June 8, 2022 ScheduleTaken = true Has to be part of the code which gets executed when the action is used. This is because true has to be assigned to ScheduleTaken. What you are doing is to test the condition if ScheduleTaken is equal to true. Also you are doing this on a place where the result of the condition specifies if the whole action gets shown. This is not what u want to do. 1 Share this post Link to post Share on other sites
RS30002 28 Posted June 8, 2022 17 minutes ago, sarogahtyp said: ScheduleTaken = true Has to be part of the code which gets executed when the action is used. This is because true has to be assigned to ScheduleTaken. What you are doing is to test the condition if ScheduleTaken is equal to true. Also you are doing this on a place where the result of the condition specifies if the whole action gets shown. This is not what u want to do. Very nice thank you. 🍻 full code ScheduleTaken = false; call{this addAction ["Take Guard Schedule", {ScheduleTaken = true; DeleteVehicle (_this select 0) select 0;}, [], 6, true, true, "", "", 6]; }; Share this post Link to post Share on other sites