2015-06-29 02:34:21 +00:00
|
|
|
#include "script_component.hpp"
|
2015-07-15 11:03:54 +00:00
|
|
|
//#include "initKeybinds.sqf";
|
2015-07-04 23:07:51 +00:00
|
|
|
|
|
|
|
// Add interaction menu exception
|
2015-08-02 11:47:26 +00:00
|
|
|
["isNotSpectating", {!(GETVAR((_this select 0),GVAR(isStaged),false))}] call EFUNC(common,addCanInteractWithCondition);
|
2015-07-04 23:07:51 +00:00
|
|
|
|
2015-06-29 02:34:21 +00:00
|
|
|
["SettingsInitialized", {
|
2015-07-21 12:31:13 +00:00
|
|
|
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);
|
2015-07-04 17:53:06 +00:00
|
|
|
}] call EFUNC(common,addEventHandler);
|
2015-10-04 15:08:42 +00:00
|
|
|
|
2015-11-22 20:03:10 +00:00
|
|
|
// Create a radio channel for any spectators to text chat in
|
|
|
|
if (isServer) then {
|
|
|
|
GVAR(channel) = radioChannelCreate [[0.729,0.149,0.098,1],"Spectator","Spectator (%UNIT_NAME)",[]];
|
|
|
|
publicVariable QGVAR(channel);
|
|
|
|
};
|
|
|
|
|
2015-10-04 15:08:42 +00:00
|
|
|
// Should prevent unending spectator on mission end
|
2016-01-13 18:28:36 +00:00
|
|
|
addMissionEventHandler ["Ended",{ [QGVAR(EndMission)] call FUNC(interrupt) }];
|