mirror of
https://github.com/EpochModTeam/Epoch.git
synced 2024-08-30 18:22:13 +00:00
E-Pad Blocked Areas
This commit is contained in:
parent
b66bc7a33e
commit
877108a1b9
Sources
31
Sources/epoch_code/customs/E_Pad/BlockedAreas.sqf
Normal file
31
Sources/epoch_code/customs/E_Pad/BlockedAreas.sqf
Normal file
@ -0,0 +1,31 @@
|
||||
_config = 'CfgEpochClient' call EPOCH_returnConfig;
|
||||
_blacklist = (getArray(_config >> worldname >> 'blockedArea'));
|
||||
if (isnil "Epoch_BlockedMarkeron") then {
|
||||
Epoch_BlockedMarkeron = false;
|
||||
};
|
||||
if (Epoch_BlockedMarkeron) then {
|
||||
{
|
||||
_x params ["_mPos","_size"];
|
||||
_mName = format ["blockedmarker_%1",_mPos];
|
||||
deleteMarkerlocal _mName;
|
||||
} foreach _blacklist;
|
||||
["Blocked Areas are now removed from your Map",5] call Epoch_Message;
|
||||
}
|
||||
else {
|
||||
_mShape = 'ELLIPSE';
|
||||
_mColor = 'ColorRed';
|
||||
_mBrush = 'Grid';
|
||||
_mAlpha = 0.8;
|
||||
{
|
||||
_x params ["_mPos","_size"];
|
||||
_msize = [_size,_size];
|
||||
_mName = format ["blockedmarker_%1",_mPos];
|
||||
_mrkr = createMarkerLocal [_mName, _mPos];
|
||||
_mName setMarkerShapeLocal _mShape;
|
||||
_mName setMarkerSizeLocal _mSize;
|
||||
_mName setMarkerColorLocal _mColor;
|
||||
_mName setMarkerBrushLocal _mBrush;
|
||||
_mName setMarkerAlphaLocal _mAlpha;
|
||||
} forEach _blacklist;
|
||||
["Blocked Areas are now shown on your Map",5] call Epoch_Message;
|
||||
};
|
@ -90,6 +90,18 @@ class e_pad_config
|
||||
ToggleVar = "EPOCH_DeathMarkerOn";
|
||||
ToggleAble = "true";
|
||||
};
|
||||
class blockedMarker
|
||||
{
|
||||
ButtonText = "";
|
||||
Description = "Blocked Areas";
|
||||
icon = "x\addons\a3_epoch_code\Data\UI\epad\blocked.paa";
|
||||
color[] = {1,0,0,1};
|
||||
colortoggled[] = {0,1,0,1};
|
||||
action = "call compile preprocessfilelinenumbers 'epoch_code\customs\E_Pad\BlockedAreas.sqf'";
|
||||
tooltip = "Show / Hide blocked areas on the map";
|
||||
ToggleVar = "Epoch_BlockedMarkeron";
|
||||
ToggleAble = "true";
|
||||
};
|
||||
class Earplug {
|
||||
ButtonText = "";
|
||||
Description = "Auto-Earplugs";
|
||||
@ -178,7 +190,7 @@ class e_pad_config
|
||||
{
|
||||
ButtonText = "";
|
||||
Description = "Server Settings";
|
||||
icon = "x\addons\a3_epoch_code\Data\UI\epad\server_info_icon_ca.paa";
|
||||
icon = "x\addons\a3_epoch_code\Data\UI\epad\seversettings.paa";
|
||||
color[] = {1,1,1,1};
|
||||
colortoggled[] = {0,1,0,1};
|
||||
html = "epoch_code\customs\E_Pad\ServerSettings.html";
|
||||
|
Loading…
x
Reference in New Issue
Block a user