Merge pull request #929 from morgoth0/patch-7

Patch 7
This commit is contained in:
vbawol 2017-10-19 10:53:43 -05:00 committed by GitHub
commit 04d3d1d64d
4 changed files with 51 additions and 46 deletions

View File

@ -58,7 +58,7 @@ if(isNil {Epoch_markerCounter})then{Epoch_markerCounter = 0};
{
// double check all, use these defaults if not defined
_x params [
["_mName",format["marker_%1", Epoch_markerCounter]],
["_mName",format["EPOCH_marker_%1", Epoch_markerCounter]],
["_mShape","ICON"],
["_mType","hd_dot"],
["_mColor","ColorRed"],
@ -94,7 +94,7 @@ if(isNil {Epoch_markerCounter})then{Epoch_markerCounter = 0};
_mName setMarkerColorLocal _mColor
};
if(_mName isEqualTo (format["marker_%1", Epoch_markerCounter]))then{
if(_mName isEqualTo (format["EPOCH_marker_%1", Epoch_markerCounter]))then{
Epoch_markerCounter = Epoch_markerCounter + 1;
};
}forEach _markerArray;
}forEach _markerArray;

View File

@ -384,40 +384,45 @@ if(visibleMap)then{
if(isNil {EPOCH_lastMapScale})then{EPOCH_lastMapScale = 0};
for "_i" from 0 to ((count _zoomMarkers) - 1) do {
_zoomMarker = _zoomMarkers select _i;
switch(true)do{
case ( (_mapScale >= 0.95) && (_mapScale <= 1) ): {
_zoomMarker setMarkerSizeLocal [0.666,0.666];
//_zoomMarker setMarkerAlphaLocal 0;
};
case ( (_mapScale >= 0.75) && (_mapScale < 0.95) ): {
_zoomMarker setMarkerSizeLocal [0.8,0.8];
};
case ( (_mapScale >= 0.55) && (_mapScale < 0.75) ): {
_zoomMarker setMarkerSizeLocal [1,1];
};
case ( (_mapScale >= 0.5) && (_mapScale < 0.55) ): {
_zoomMarker setMarkerSizeLocal [1.1,1.1];
};
case ( (_mapScale >= 0.45) && (_mapScale < 0.5) ): {
_zoomMarker setMarkerSizeLocal [1.2,1.2];
};
case ( (_mapScale >= 0.35) && (_mapScale < 0.45) ): {
_zoomMarker setMarkerSizeLocal [1.4,1.4];
};
case ( (_mapScale >= 0.25) && (_mapScale < 0.35) ): {
_zoomMarker setMarkerSizeLocal [1.666,1.666];
};
case ( (_mapScale >= 0.15) && (_mapScale < 0.25) ): {
_zoomMarker setMarkerSizeLocal [1.8,1.8];
};
case ( (_mapScale >= 0.1) && (_mapScale < 0.15) ): {
_zoomMarker setMarkerSizeLocal [1.9,1.9];
};
case ( (_mapScale >= 0.0666) && (_mapScale < 0.1) ): {
_zoomMarker setMarkerSizeLocal [2.2,2.2];
};
case ( (_mapScale >= 0) && (_mapScale < 0.0666) ): {
_zoomMarker setMarkerSizeLocal [2.666,2.666];
private "_markerString";
_markerString = toArray _zoomMarker;
_markerString resize 6;
if (toString _markerString == "EPOCH_") then {
switch(true)do{
case ( (_mapScale >= 0.95) && (_mapScale <= 1) ): {
_zoomMarker setMarkerSizeLocal [0.666,0.666];
//_zoomMarker setMarkerAlphaLocal 0;
};
case ( (_mapScale >= 0.75) && (_mapScale < 0.95) ): {
_zoomMarker setMarkerSizeLocal [0.8,0.8];
};
case ( (_mapScale >= 0.55) && (_mapScale < 0.75) ): {
_zoomMarker setMarkerSizeLocal [0.9,0.9];
};
case ( (_mapScale >= 0.5) && (_mapScale < 0.55) ): {
_zoomMarker setMarkerSizeLocal [1.0,1.0];
};
case ( (_mapScale >= 0.45) && (_mapScale < 0.5) ): {
_zoomMarker setMarkerSizeLocal [1.1,1.1];
};
case ( (_mapScale >= 0.35) && (_mapScale < 0.45) ): {
_zoomMarker setMarkerSizeLocal [1.2,1.2];
};
case ( (_mapScale >= 0.25) && (_mapScale < 0.35) ): {
_zoomMarker setMarkerSizeLocal [1.3,1.3];
};
case ( (_mapScale >= 0.15) && (_mapScale < 0.25) ): {
_zoomMarker setMarkerSizeLocal [1.4,1.4];
};
case ( (_mapScale >= 0.1) && (_mapScale < 0.15) ): {
_zoomMarker setMarkerSizeLocal [1.5,1.5];
};
case ( (_mapScale >= 0.0666) && (_mapScale < 0.1) ): {
_zoomMarker setMarkerSizeLocal [1.6,1.6];
};
case ( (_mapScale >= 0) && (_mapScale < 0.0666) ): {
_zoomMarker setMarkerSizeLocal [1.7,1.7];
};
};
};
};

View File

@ -13,17 +13,17 @@ class CfgMarkerSets
brushes[] = {"Solid","SolidFull","Horizontal","Vertical","Grid","FDiagonal","BDiagonal","DiagGrid","Cross","Border","SolidBorder"};
class PlayerMarker {
markerArray[] = {
{"PlayerMarker1","ICON","EpochActive_Hex","ColorBlue",1,{0.9,0.9}},
{"PlayerMarker2","ICON","EpochBG_Hex","ColorWhite",0.3,{0.9,0.9}},
{"PlayerMarker3","ICON","EpochGPS","ColorBlue",1,{0.8,0.8},0,"format['%1/%2',(format[mapGridPosition player]) select [0,3],(format[mapGridPosition player]) select [3,3]]"}
{"EPOCH_PlayerMarker1","ICON","EpochActive_Hex","ColorBlue",1,{0.9,0.9}},
{"EPOCH_PlayerMarker2","ICON","EpochBG_Hex","ColorWhite",0.3,{0.9,0.9}},
{"EPOCH_PlayerMarker3","ICON","EpochGPS","ColorBlue",1,{0.8,0.8},0,"format['%1/%2',(format[mapGridPosition player]) select [0,3],(format[mapGridPosition player]) select [3,3]]"}
};
};
class DeathMarker {
markerArray[] = {
{"DeathMarker1","ICON","EpochActive_Circle","ColorRed",1,{0.9,0.9}},
{"DeathMarker2","ICON","EpochBG_Circle","ColorPink",0.3,{0.9,0.9}},
{"DeathMarker3","ICON","EpochSkull","ColorRed",1,{0.8,0.8},0,"str(name player)"}
{"EPOCH_DeathMarker1","ICON","EpochActive_Circle","ColorRed",1,{0.9,0.9}},
{"EPOCH_DeathMarker2","ICON","EpochBG_Circle","ColorPink",0.3,{0.9,0.9}},
{"EPOCH_DeathMarker3","ICON","EpochSkull","ColorRed",1,{0.8,0.8},0,"str(name player)"}
};
};
class EpochDebugBox {

View File

@ -53,7 +53,7 @@ _return = [];
{
// double check all, use these defaults if not defined
_x params [
["_mName",format["globalMarker__%1", Epoch_markerCounterGlobal]],
["_mName",format["EPOCH_globalMarker_%1", Epoch_markerCounterGlobal]],
["_mShape","ICON"],
["_mType","hd_dot"],
["_mColor","ColorBlack"],
@ -62,7 +62,7 @@ _return = [];
["_mDir",0],
["_mText",""]
];
_mName = format["globalMarker_%1", Epoch_markerCounterGlobal];
_mName = format["EPOCH_globalMarker_%1", Epoch_markerCounterGlobal];
_marker = createMarker [_mName, _mPos];
_return pushBack _mName;
_mName setMarkerShape _mShape;
@ -88,4 +88,4 @@ _return = [];
Epoch_markerCounterGlobal = Epoch_markerCounterGlobal + 1;
}forEach _markerArray;
_return
_return