Description
Fires the scripted event that belongs to an Apex campaign mission state, on the machine where it is called, with BIS_fnc_callScriptedEventHandler on missionNamespace:
- "Waiting" - "BIS_coop_campaign_ss_missionWaiting"
- "Intro" - "BIS_coop_campaign_ss_missionIntro"
- "Loadout" - "BIS_coop_campaign_ss_missionLoadout"
- "Started" - "BIS_coop_campaign_ss_missionStarted"
Any other state shows an error. The function does not change the mission state (see BIS_fnc_EXP_camp_manager_setState).
The function is meant for internal use. It is called by BIS_fnc_EXP_camp_manager (on state changes), BIS_fnc_EXP_camp_manager_setState and the campaign's state scripts, e.g. for players joining a mission in progress. The campaign's shared init script and the missions add the handlers with BIS_fnc_addScriptedEventHandler.
Syntax
[state] call BIS_fnc_EXP_camp_manager_triggerEvent
Parameters:
state: String - (Optional, default "Waiting") the mission state: "Waiting", "Intro", "Loadout" or "Started"
Returns: Nothing
Examples
Example 1
[missionNamespace, "BIS_coop_campaign_ss_missionStarted", { systemChat "Mission started"; }] call BIS_fnc_addScriptedEventHandler;
["Started"] call BIS_fnc_EXP_camp_manager_triggerEvent; // shows "Mission started"
See also
BIS_fnc_EXP_camp_manager · BIS_fnc_EXP_camp_manager_setState · BIS_fnc_EXP_camp_manager_getState · BIS_fnc_addScriptedEventHandler · BIS_fnc_callScriptedEventHandler