mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
7e9500f2ca
Seamlessly integrates the spectator system with the vanilla respawn framework when the onDeath setting is enabled. This commit makes a lot of changes: - Edit BI functions used by the vanilla respawn framework to enable support for ace_spectator. - Set spectator state is now tracked using a GVAR for the local player since using a unit won't be reliable all of the time. However unit is still marked for any filtering purposes. - Instead of NV being used based on the sun to moon transition state by default, that functionality only takes place in the integrated system so that custom frameworks can do what they want. - Seagull units are hidden when using framework integration since they're spawned by the engine with respawn type 1 and they just hang around undesirably
11 lines
469 B
Plaintext
11 lines
469 B
Plaintext
#include "script_component.hpp"
|
|
//#include "initKeybinds.sqf";
|
|
|
|
// Add interaction menu exception
|
|
["isNotSpectating", {!(GETVAR((_this select 0),GVAR(isStaged),false))}] call EFUNC(common,addCanInteractWithCondition);
|
|
|
|
["SettingsInitialized", {
|
|
GVAR(availableModes) = [[0,1,2], [1,2], [0], [1], [2]] select GVAR(restrictModes);
|
|
GVAR(availableVisions) = [[-2,-1,0,1], [-2,-1], [-2,0,1], [-2]] select GVAR(restrictVisions);
|
|
}] call EFUNC(common,addEventHandler);
|