Skip to content

Commit

Permalink
Add settings
Browse files Browse the repository at this point in the history
  • Loading branch information
3Mydlo3 committed Aug 14, 2024
1 parent 3823439 commit f2a2692
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
4 changes: 4 additions & 0 deletions addons/spectator/functions/fnc_start.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,10 @@ private _whitelistedSides = switch _sides do {
case 1: {[playerSide]};
// All sides spectator
case 2: {[WEST, INDEPENDENT, EAST]};
// Player group only
case 3: {[group player]};
// Player only
case 4: {[player]};
default {playerSide call BIS_fnc_friendlySides};
};

Expand Down
4 changes: 2 additions & 2 deletions addons/spectator/initSettings.inc.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
"LIST",
[LSTRING(Sides), LSTRING(Sides_Description)],
LSTRING(DisplayName),
[[0, 1, 2], [LSTRING(Friendly), LSTRING(Own), "str_all_voices"], 0],
[[0, 1, 3, 4, 2], [LSTRING(Friendly), LSTRING(Own), LSTRING(PlayerGroup), "str_player", "str_all_voices"], 0],
1,
{[_this] call FUNC(restart)}
] call CBA_fnc_addSetting;
Expand All @@ -42,7 +42,7 @@
"LIST",
[LSTRING(Sides), LSTRING(Sides_Description)],
[LSTRING(DisplayName), LSTRING(Unconscious)],
[[0, 1, 2], [LSTRING(Friendly), LSTRING(Own), "str_all_voices"], 0],
[[0, 1, 3, 4, 2], [LSTRING(Friendly), LSTRING(Own), LSTRING(PlayerGroup), "str_player", "str_all_voices"], 0],
1,
{[_this] call FUNC(restart)}
] call CBA_fnc_addSetting;
Expand Down
4 changes: 4 additions & 0 deletions addons/spectator/stringtable.xml
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,10 @@
<English>Player side</English>
<Polish>Strona gracza</Polish>
</Key>
<Key ID="STR_AFM_Spectator_PlayerGroup">
<English>Player group</English>
<Polish>Grupa gracza</Polish>
</Key>
<Key ID="STR_AFM_Spectator_CivilianSide">
<English>Allow civilian spectating</English>
<Polish>Pozwól obserwować cywili</Polish>
Expand Down

0 comments on commit f2a2692

Please sign in to comment.