Add new option to spectator unit filter setting

Adds an option to use playableUnits for scenarios where AI playable units are enabled.
This commit is contained in:
SilentSpike 2015-08-05 14:15:27 +01:00
parent 07e09b60fa
commit 5200fd6a02
4 changed files with 11 additions and 4 deletions

View File

@ -1,8 +1,8 @@
class ACE_Settings { class ACE_Settings {
class GVAR(filterUnits) { class GVAR(filterUnits) {
typeName = "SCALAR"; typeName = "SCALAR";
value = 1; value = 2;
values[] = {CSTRING(units_none), CSTRING(units_players), CSTRING(units_all)}; values[] = {CSTRING(units_none), CSTRING(units_players), CSTRING(units_playable), CSTRING(units_all)};
}; };
class GVAR(filterSides) { class GVAR(filterSides) {
typeName = "SCALAR"; typeName = "SCALAR";

View File

@ -21,11 +21,15 @@ class CfgVehicles {
class players { class players {
name = CSTRING(units_players); name = CSTRING(units_players);
value = 1; value = 1;
};
class playable {
name = CSTRING(units_playable);
value = 2;
default = 1; default = 1;
}; };
class all { class all {
name = CSTRING(units_all); name = CSTRING(units_all);
value = 2; value = 3;
}; };
}; };
}; };

View File

@ -36,7 +36,7 @@ if !(_newUnits isEqualTo []) exitWith {
private ["_sides","_cond","_filteredUnits","_color","_icon"]; private ["_sides","_cond","_filteredUnits","_color","_icon"];
// Unit setting filter // Unit setting filter
_newUnits = [[],allPlayers,allUnits] select GVAR(filterUnits); _newUnits = [[],allPlayers,playableUnits,allUnits] select GVAR(filterUnits);
// Side setting filter // Side setting filter
_sides = []; _sides = [];

View File

@ -25,6 +25,9 @@
<English>Only players</English> <English>Only players</English>
<Polish>Tylko gracze</Polish> <Polish>Tylko gracze</Polish>
</Key> </Key>
<Key ID="STR_ACE_Spectator_units_playable">
<English>Playable Units</English>
</Key>
<Key ID="STR_ACE_Spectator_units_all"> <Key ID="STR_ACE_Spectator_units_all">
<English>All units</English> <English>All units</English>
<Polish>Wszystkie jednostki</Polish> <Polish>Wszystkie jednostki</Polish>