mirror of
https://github.com/EpochModTeam/DayZ-Epoch.git
synced 2025-12-14 12:12:34 +03:00
Consolidate DZE_ActionInProgress and r_action_count to one variable
There is no point in having two variables for the same purpose. It is also pointless to keep an action count tally like r_action_count was doing, since it is only ever checked for being 0 or 1. Any count higher or lower than that is irrelevant. I will make this change in vanilla too.
This commit is contained in:
@@ -1,8 +1,8 @@
|
||||
private ["_objectID","_objectUID","_target","_objectClasses","_range","_objects","_requirements","_count","_objects_filtered","_ctrl","_itemText","_type","_amount","_success","_wealth","_message1","_message2","_option"];
|
||||
disableSerialization;
|
||||
|
||||
if (DZE_ActionInProgress) exitWith {localize "STR_EPOCH_ACTIONS_2" call dayz_rollingMessages;};
|
||||
DZE_ActionInProgress = true;
|
||||
if (dayz_actionInProgress) exitWith {localize "STR_EPOCH_ACTIONS_2" call dayz_rollingMessages;};
|
||||
dayz_actionInProgress = true;
|
||||
|
||||
player removeAction s_player_maintain_area;
|
||||
s_player_maintain_area = 1;
|
||||
@@ -36,7 +36,7 @@ if (_count == 0) exitWith {
|
||||
} else {
|
||||
format[localize "STR_EPOCH_ACTIONS_22",_count] call dayz_rollingMessages;
|
||||
};
|
||||
DZE_ActionInProgress = false;
|
||||
dayz_actionInProgress = false;
|
||||
s_player_maintain_area = -1;
|
||||
s_player_maintain_area_preview = -1;
|
||||
};
|
||||
@@ -132,6 +132,6 @@ switch _option do {
|
||||
};
|
||||
};
|
||||
|
||||
DZE_ActionInProgress = false;
|
||||
dayz_actionInProgress = false;
|
||||
s_player_maintain_area = -1;
|
||||
s_player_maintain_area_preview = -1;
|
||||
|
||||
Reference in New Issue
Block a user