Fix body marker only showing one body

This commit is contained in:
ebayShopper
2017-02-21 19:02:42 -05:00
parent d416ae80ab
commit ffb88a0d7b
4 changed files with 21 additions and 12 deletions

View File

@@ -81,6 +81,8 @@
[FIXED] Panic sounds will no longer overlap when the player is attacked by zombies. #1861 @DeVloek [FIXED] Panic sounds will no longer overlap when the player is attacked by zombies. #1861 @DeVloek
[FIXED] Melee weapons will no longer be eaten when attempting to add them to a full toolbelt. [FIXED] Melee weapons will no longer be eaten when attempting to add them to a full toolbelt.
[FIXED] Updated to Sa-Matra's latest Core Patch BIS Effects which fix the fire in the sky bug again. #1883 @oiad @icomrade [FIXED] Updated to Sa-Matra's latest Core Patch BIS Effects which fix the fire in the sky bug again. #1883 @oiad @icomrade
[FIXED] Mark body now marks all of your bodies instead of just one. @oiad
[FIXED] Group and body markers correctly update on the GPS mini map now.
[NOTE] The fixes below are included in the 1.0.6 Build C server package released December 29th, 2016 (http://dayzepoch.com/a2dayzepoch.php) [NOTE] The fixes below are included in the 1.0.6 Build C server package released December 29th, 2016 (http://dayzepoch.com/a2dayzepoch.php)
[FIXED] Hive child 309 errors that resulted in broken saving of newly built storage object inventory. @icomrade [FIXED] Hive child 309 errors that resulted in broken saving of newly built storage object inventory. @icomrade

View File

@@ -1,4 +1,4 @@
private ["_count","_found","_group","_hasGPS","_index","_marker","_markBody","_markGroup","_markSelf","_pos","_self","_vehicle"]; private ["_bodyCount","_count","_group","_hasGPS","_index","_marker","_markBody","_markGroup","_markSelf","_name","_pos","_self","_vehicle"];
while {true} do { while {true} do {
_group = player call dayz_filterGroup; _group = player call dayz_filterGroup;
@@ -9,7 +9,7 @@ while {true} do {
if (!isNull findDisplay 80000) then {findDisplay 80000 closeDisplay 2;}; if (!isNull findDisplay 80000) then {findDisplay 80000 closeDisplay 2;};
localize "STR_EPOCH_RADIO_CONTACT_LOST" call dayz_rollingMessages; localize "STR_EPOCH_RADIO_CONTACT_LOST" call dayz_rollingMessages;
} else { } else {
if (visibleMap or !isNull findDisplay 88890) then { if (visibleMap or !isNull (uiNameSpace getVariable["BIS_RscMiniMap",displayNull])) then {
_hasGPS = "ItemGPS" in items player; _hasGPS = "ItemGPS" in items player;
_markBody = (dayz_markBody == 1 or (dayz_markBody == 2 && _hasGPS)); _markBody = (dayz_markBody == 1 or (dayz_markBody == 2 && _hasGPS));
_markGroup = (dayz_markGroup == 1 or (dayz_markGroup == 2 && _hasGPS)); _markGroup = (dayz_markGroup == 1 or (dayz_markGroup == 2 && _hasGPS));
@@ -40,21 +40,27 @@ while {true} do {
dayz_oldMemberCount = _count; dayz_oldMemberCount = _count;
if (_markBody) then { if (_markBody) then {
_found = false; _bodyCount = 0;
_name = name player;
{ {
if (_x getVariable["bodyName",""] == name player) exitWith { if (_x getVariable["bodyName",""] == _name) then {
_found = true; _bodyCount = _bodyCount + 1;
_pos = [_x] call FNC_GetPos; _pos = [_x] call FNC_GetPos;
deleteMarkerLocal "MyBody"; deleteMarkerLocal format["MyBody%1",_bodyCount];
_marker = createMarkerLocal ["MyBody",_pos]; _marker = createMarkerLocal [format["MyBody%1",_bodyCount],_pos];
_marker setMarkerTypeLocal "DestroyedVehicle"; _marker setMarkerTypeLocal "DestroyedVehicle";
_marker setMarkerTextLocal localize "STR_EPOCH_RIP"; _marker setMarkerTextLocal localize "STR_EPOCH_RIP";
_marker setMarkerColorLocal "ColorRed"; _marker setMarkerColorLocal "ColorRed";
}; };
} count allDead; } count allDead;
if (!_found) then {deleteMarkerLocal "MyBody";}; //Body was deleted or hidden
// Remove markers for bodies that were deleted
if (dayz_oldBodyCount > _bodyCount) then {
for "_i" from _bodyCount to dayz_oldBodyCount do {deleteMarkerLocal format["MyBody%1",_i];};
};
dayz_oldBodyCount = _bodyCount;
} else { } else {
deleteMarkerLocal "MyBody"; for "_i" from 1 to dayz_oldBodyCount do {deleteMarkerLocal format["MyBody%1",_i];};
}; };
}; };
}; };

View File

@@ -24,6 +24,7 @@ if (count _savedGroup > 0 && {!dayz_requireRadio or {dayz_requireRadio && "ItemR
} count allGroups; } count allGroups;
}; };
dayz_oldBodyCount = 0;
dayz_oldGroupCount = 0; dayz_oldGroupCount = 0;
dayz_oldMemberCount = 0; dayz_oldMemberCount = 0;
dayz_disbandGroup = compile preprocessFileLineNumbers "\z\addons\dayz_code\groups\disband.sqf"; dayz_disbandGroup = compile preprocessFileLineNumbers "\z\addons\dayz_code\groups\disband.sqf";

View File

@@ -1,5 +1,5 @@
//new2 //new2
5 allDead !"} count allDead;\nif (!_found) then {deleteMarkerLocal \"MyBody\";};" 5 allDead !"} count allDead;\n\n\nif (dayz_oldBodyCount > _bodyCount) then {"
5 allGroups !"publicVariableServer \"PVDZ_Server_UpdateGroup\";\n};\n} count allGroups;" 5 allGroups !"publicVariableServer \"PVDZ_Server_UpdateGroup\";\n};\n} count allGroups;"
5 allMissionObjects !"allMissionObjects \"RoadFlare\"" !"allMissionObjects \"ChemLight\"" !"[_x,2,0,false,false] spawn BIS_Effects_Burn;\n};\n} count allMissionObjects \"SpawnableWreck\";" 5 allMissionObjects !"allMissionObjects \"RoadFlare\"" !"allMissionObjects \"ChemLight\"" !"[_x,2,0,false,false] spawn BIS_Effects_Burn;\n};\n} count allMissionObjects \"SpawnableWreck\";"
5 allowDammage 5 allowDammage
@@ -11,13 +11,13 @@
5 createAgent !="_agent = createAgent [_type, _position, [], _radius, \"CAN_COLLIDE\"];" !="_agent = if (_type == \"Pastor\") then {createAgent [_type, _Pos, [], 0, \"NONE\"]} else {createAgent [_type, _Pos, [], 0, \"FORM\"]};" !="_dog = createAgent [_type, _Pos, [], 0, \"NONE\"];" 5 createAgent !="_agent = createAgent [_type, _position, [], _radius, \"CAN_COLLIDE\"];" !="_agent = if (_type == \"Pastor\") then {createAgent [_type, _Pos, [], 0, \"NONE\"]} else {createAgent [_type, _Pos, [], 0, \"FORM\"]};" !="_dog = createAgent [_type, _Pos, [], 0, \"NONE\"];"
5 createDialog !="_region = createDialog \"RscDisplaySpawnSelecter\";" !="_gender = createDialog 'RscDisplayGenderSelect';" !="_dialog = createDialog \"bloodTest\";" !="createDialog 'RscDisplayCraftingMenu';" !="createDialog \"DAYZ_PADLOCK\";" !="createDialog \"horde_journal_front_cover\";" !="createDialog 'horde_journal_front_cover';" !="createDialog 'horde_journal_pages_headshots';" !="createDialog 'horde_journal_pages_murders';" !="createDialog 'horde_journal_pages_journal_humanity';" !="createDialog 'horde_journal_pages_zombies';" !="createDialog 'horde_journal_pages_bandits';" !="createDialog 'horde_journal_pages_humanity_art';" !"Z_ResetContainer = true;\ncreateDialog \"AdvancedTrading\";" !"createDialog \"DoorManagement\";\ncall DoorNearbyHumans;" !="createDialog \"ComboLockUI\";" !"createdialog \"PlotManagement\";\ncall PlotNearbyHumans;" !"_trader_data = (_this select 3);\n\n_dialog = createdialog \"TraderDialog\";" !="_ok = createdialog \"SafeKeyPad\";" !="_ok = createdialog \"KeypadUI\";" !"EpochDeathBoardLoad = {\ncreatedialog \"EpochDeathBoardDialog\";" !="if(DZE_doorManagement) then {createdialog \"DoorAccess\";} else {createdialog \"ComboLockUI\";};" !"\ndisableSerialization;\ncreateDialog \"DZ_GroupDialog\";" 5 createDialog !="_region = createDialog \"RscDisplaySpawnSelecter\";" !="_gender = createDialog 'RscDisplayGenderSelect';" !="_dialog = createDialog \"bloodTest\";" !="createDialog 'RscDisplayCraftingMenu';" !="createDialog \"DAYZ_PADLOCK\";" !="createDialog \"horde_journal_front_cover\";" !="createDialog 'horde_journal_front_cover';" !="createDialog 'horde_journal_pages_headshots';" !="createDialog 'horde_journal_pages_murders';" !="createDialog 'horde_journal_pages_journal_humanity';" !="createDialog 'horde_journal_pages_zombies';" !="createDialog 'horde_journal_pages_bandits';" !="createDialog 'horde_journal_pages_humanity_art';" !"Z_ResetContainer = true;\ncreateDialog \"AdvancedTrading\";" !"createDialog \"DoorManagement\";\ncall DoorNearbyHumans;" !="createDialog \"ComboLockUI\";" !"createdialog \"PlotManagement\";\ncall PlotNearbyHumans;" !"_trader_data = (_this select 3);\n\n_dialog = createdialog \"TraderDialog\";" !="_ok = createdialog \"SafeKeyPad\";" !="_ok = createdialog \"KeypadUI\";" !"EpochDeathBoardLoad = {\ncreatedialog \"EpochDeathBoardDialog\";" !="if(DZE_doorManagement) then {createdialog \"DoorAccess\";} else {createdialog \"ComboLockUI\";};" !"\ndisableSerialization;\ncreateDialog \"DZ_GroupDialog\";"
5 createDisplay 5 createDisplay
5 createMarker !"\"createMarkerLocal\",\n\"setMarkerPosLocal\"," !="rcreateMarkerLocal = 'createMarkerLocal'" !"rcreateMarkerLocalcode" !"\"createMarkerLocal\", \"createSimpleTask\"," !"if (isnil 'BIS_GITA_fnc_createMarkers' || false) then {" !"_marker = createMarkerLocal [format[\"groupMember" !="_marker = createMarkerLocal [\"MyBody\",_pos];" 5 createMarker !"\"createMarkerLocal\",\n\"setMarkerPosLocal\"," !="rcreateMarkerLocal = 'createMarkerLocal'" !"rcreateMarkerLocalcode" !"\"createMarkerLocal\", \"createSimpleTask\"," !"if (isnil 'BIS_GITA_fnc_createMarkers' || false) then {" !"_marker = createMarkerLocal [format[\"groupMember"
5 createUnit !="_newUnit = _group createUnit [_class,respawn_west_original,[],0,\"NONE\"];" !="BIS_MPF_logic = BIS_MPF_dummygroup createUnit [\"Logic\", [1000,10,0], [], 0, \"NONE\"];" 5 createUnit !="_newUnit = _group createUnit [_class,respawn_west_original,[],0,\"NONE\"];" !="BIS_MPF_logic = BIS_MPF_dummygroup createUnit [\"Logic\", [1000,10,0], [], 0, \"NONE\"];"
5 createVehicleLocal !"if (_VectorWorkAround) then {\n_object2 = _ghost2 createVehicleLocal [0,0,0];\nhideObject _object;\n};" !="_object = (_x select 1) createVehicleLocal [0,0,0];" !="_Crater= \"CraterLong\" createvehiclelocal [_pos select 0, _pos select 1, 0];" !="_plant = _x createVehicleLocal (getMarkerPos \"center\");" !="_point = \"Logic\" createVehicleLocal getPosATL _unit;" !="_obj = _class createVehicleLocal _new;" !="_obj = _class createVehicleLocal (getMarkerpos \"respawn_west\");" !" = \"#lightpoint\" createVehicleLocal " !" = \"#particlesource\" createVehicleLocal " !="_object = _ghost createVehicleLocal getMarkerpos \"respawn_west\";" !="_cursorTarget = _upgrade createVehicleLocal getMarkerpos \"respawn_west\";" !="_sign = \"Sign_arrow_down_large_EP1\" createVehicleLocal [0,0,0];" !="_obj = \"Sign_sphere10cm_EP1\" createVehicleLocal [0,0,0];" !="_obj = _model createVehicleLocal [0,0,0];" !="_objectSnapGizmo = \"Sign_sphere10cm_EP1\" createVehicleLocal [0,0,0];" !"_object = _type createVehicleLocal [0,0,0];" 5 createVehicleLocal !"if (_VectorWorkAround) then {\n_object2 = _ghost2 createVehicleLocal [0,0,0];\nhideObject _object;\n};" !="_object = (_x select 1) createVehicleLocal [0,0,0];" !="_Crater= \"CraterLong\" createvehiclelocal [_pos select 0, _pos select 1, 0];" !="_plant = _x createVehicleLocal (getMarkerPos \"center\");" !="_point = \"Logic\" createVehicleLocal getPosATL _unit;" !="_obj = _class createVehicleLocal _new;" !="_obj = _class createVehicleLocal (getMarkerpos \"respawn_west\");" !" = \"#lightpoint\" createVehicleLocal " !" = \"#particlesource\" createVehicleLocal " !="_object = _ghost createVehicleLocal getMarkerpos \"respawn_west\";" !="_cursorTarget = _upgrade createVehicleLocal getMarkerpos \"respawn_west\";" !="_sign = \"Sign_arrow_down_large_EP1\" createVehicleLocal [0,0,0];" !="_obj = \"Sign_sphere10cm_EP1\" createVehicleLocal [0,0,0];" !="_obj = _model createVehicleLocal [0,0,0];" !="_objectSnapGizmo = \"Sign_sphere10cm_EP1\" createVehicleLocal [0,0,0];" !"_object = _type createVehicleLocal [0,0,0];"
5 ctrlAddEventHandler 5 ctrlAddEventHandler
5 ctrlRemoveAllEventHandlers 5 ctrlRemoveAllEventHandlers
5 ctrlSetPosition !="_control ctrlSetPosition [_posX, _posY];" !"if (_h != -1) then {_pos set [3,_h]};\n_control ctrlsetposition _pos;" !="_control ctrlSetPosition [0, (_y + _deltaY)];" !="_disp_ctrl ctrlSetPosition [_posX, _posY];" !="_control ctrlSetPosition _grpPos;" !="_group ctrlSetPosition _pos;" !="_control ctrlSetPosition [_controlPos select 0, _controlPos select 1, _controlPos select 2, 0.03921 * _lines];" !="((uiNamespace getVariable 'DAYZ_GUI_waiting') displayCtrl 1400) ctrlSetPosition _sandLevel;" !="_delayControl ctrlSetPosition [0, _pos];" !="_icon ctrlSetPosition [(_screen select 0),(_screen select 1),.99,.65];" 5 ctrlSetPosition !="_control ctrlSetPosition [_posX, _posY];" !"if (_h != -1) then {_pos set [3,_h]};\n_control ctrlsetposition _pos;" !="_control ctrlSetPosition [0, (_y + _deltaY)];" !="_disp_ctrl ctrlSetPosition [_posX, _posY];" !="_control ctrlSetPosition _grpPos;" !="_group ctrlSetPosition _pos;" !="_control ctrlSetPosition [_controlPos select 0, _controlPos select 1, _controlPos select 2, 0.03921 * _lines];" !="((uiNamespace getVariable 'DAYZ_GUI_waiting') displayCtrl 1400) ctrlSetPosition _sandLevel;" !="_delayControl ctrlSetPosition [0, _pos];" !="_icon ctrlSetPosition [(_screen select 0),(_screen select 1),.99,.65];"
5 deleteMarker !"} count allDead;\nif (!_found) then {deleteMarkerLocal \"MyBody\";};" 5 deleteMarker !"} count allDead;\n\n\nif (dayz_oldBodyCount > _bodyCount) then {"
5 displayAddEventHandler !"bis_fnc_halo_keydown_eh = (finddisplay 46) displayaddeventhandler [\"keydown\",\"_this call bis_fnc_halo_keydown;\"];" 5 displayAddEventHandler !"bis_fnc_halo_keydown_eh = (finddisplay 46) displayaddeventhandler [\"keydown\",\"_this call bis_fnc_halo_keydown;\"];"
5 displayRemoveAllEventHandlers 5 displayRemoveAllEventHandlers
5 displaySetEventHandler 5 displaySetEventHandler