Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add virtual faction aliases to other components #259

Merged
merged 5 commits into from
Aug 4, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
93 changes: 43 additions & 50 deletions f/assignGear/f_assignInsignia.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,6 @@ switch (_insignia_style_CSAT) do
case "Urban" : {_CSAT_Medic_Badge = "CSAT_Urban_Medic_Badge";};
};

// Treat CTRG like BLUFOR
if (_faction == "blu_ctrg_f") then {_faction = "blu_f"};

// ===================================================================================

// Assign Insignia based on type of the unit.
Expand All @@ -44,14 +41,15 @@ private _roleBadge = switch (_typeofUnit) do
// INSIGNIA: MEDIC
case "m":
{
switch (_faction) do
switch (true) do
{
case "blu_f" : {_NATO_Medic_Badge};
case "opf_f" : {_CSAT_Medic_Badge};
case "ind_f" : {"AAF_Medic_Badge"};
case "ind_e_f" : {"AAF_Medic_Badge"};
case "opf_r_f" : {"CSAT_Pacific_Medic_Badge"};
case "blu_w_f" : {"NATO_Pacific_Medic_Bade"};
case (_faction in ["blu_f","nato"]) : {_NATO_Medic_Badge};
case (_faction in ["blu_t_f","blu_w_f","natopacific","natowoodland"]) : {"NATO_Pacific_Medic_Badge"};
case (_faction in ["opf_f","csat"]) : {_CSAT_Medic_Badge};
case (_faction in ["opf_t_f","csatpacific"]) : {"CSAT_Pacific_Medic_Badge"};
case (_faction in ["ind_f","ind_e_f","aaf","ldf"]) : {"AAF_Medic_Badge"};
case (_faction in ["opf_r_f","spetsnaz"]) : {"CSAT_Pacific_Medic_Badge"};
case (_faction in ["blu_ctrg_f","ctrg"]) : {_NATO_Medic_Badge"};
default {"NATO_Medic_Badge"};
};
};
Expand All @@ -65,9 +63,9 @@ private _roleBadge = switch (_typeofUnit) do

private _groupBadges = [];

switch (_faction) do
switch (true) do
{
case "blu_f" : {
case (_faction in ["blu_f","nato"]) : {
if (_insignia_style_NATO == "Tanoa") then {
_groupBadges = [
["GrpNATO_ASL","NATO_Pacific_ASL_Badge"],
Expand Down Expand Up @@ -104,7 +102,7 @@ switch (_faction) do
];
};
};
case "blu_t_f": {
case (_faction in ["blu_t_f","blu_w_f","natoPacific","natoWoodland"]): {
_groupBadges = [
["GrpNATO_ASL","NATO_Pacific_ASL_Badge"],
["GrpNATO_A1","NATO_Pacific_A1_Badge"],
Expand All @@ -122,25 +120,8 @@ switch (_faction) do
["GrpNATO_DC","NATO_Pacific_DC_Badge"]
];
};
case "blu_w_f": {
_groupBadges = [
["GrpNATO_ASL","NATO_Pacific_ASL_Badge"],
["GrpNATO_A1","NATO_Pacific_A1_Badge"],
["GrpNATO_A2","NATO_Pacific_A2_Badge"],
["GrpNATO_A3","NATO_Pacific_A3_Badge"],
["GrpNATO_BSL","NATO_Pacific_BSL_Badge"],
["GrpNATO_B1","NATO_Pacific_B1_Badge"],
["GrpNATO_B2","NATO_Pacific_B2_Badge"],
["GrpNATO_B3","NATO_Pacific_B3_Badge"],
["GrpNATO_CSL","NATO_Pacific_CSL_Badge"],
["GrpNATO_C1","NATO_Pacific_C1_Badge"],
["GrpNATO_C2","NATO_Pacific_C2_Badge"],
["GrpNATO_C3","NATO_Pacific_C3_Badge"],
["GrpNATO_CO","NATO_Pacific_CO_Badge"],
["GrpNATO_DC","NATO_Pacific_DC_Badge"]
];
};
case "opf_f": {

case (_faction in ["opf_f","csat"]): {
switch (_insignia_style_CSAT) do
{
case "Tanoa" : {
Expand Down Expand Up @@ -199,7 +180,7 @@ switch (_faction) do
};
};
};
case "opf_t_f": {
case (_faction in ["opf_t_f","csatPacific"]): {
_groupBadges = [
["GrpCSAT_ASL","CSAT_Pacific_ASL_Badge"],
["GrpCSAT_A1","CSAT_Pacific_A1_Badge"],
Expand All @@ -217,7 +198,7 @@ switch (_faction) do
["GrpCSAT_DC","CSAT_Pacific_DC_Badge"]
];
};
case "opf_r_f": {
case (_faction in ["opf_r_f","spetsnaz"]): {
_groupBadges = [
["GrpSpetsnaz_ASL","CSAT_Pacific_ASL_Badge"],
["GrpSpetsnaz_A1","CSAT_Pacific_A1_Badge"],
Expand All @@ -235,7 +216,7 @@ switch (_faction) do
["GrpSpetsnaz_DC","CSAT_Pacific_DC_Badge"]
];
};
case "ind_f": {
case (_faction in ["ind_f","aaf"]): {
_groupBadges = [
["GrpAAF_ASL","AAF_ASL_Badge"],
["GrpAAF_A1","AAF_A1_Badge"],
Expand All @@ -253,7 +234,7 @@ switch (_faction) do
["GrpAAF_DC","AAF_DC_Badge"]
];
};
case "ind_e_f": {
case (_faction in ["ind_e_f","ldf"]): {
_groupBadges = [
["GrpLDF_ASL","AAF_ASL_Badge"],
["GrpLDF_A1","AAF_A1_Badge"],
Expand All @@ -271,7 +252,25 @@ switch (_faction) do
["GrpLDF_DC","AAF_DC_Badge"]
];
};
case "blu_g_f" : {
case (_faction in ["blu_ctrg_f","ctrg"]): {
_groupBadges = [
["GrpCTRG_ASL","NATO_ASL_Badge"],
["GrpCTRG_A1","NATO_A1_Badge"],
["GrpCTRG_A2","NATO_A2_Badge"],
["GrpCTRG_A3","NATO_A3_Badge"],
["GrpCTRG_BSL","NATO_BSL_Badge"],
["GrpCTRG_B1","NATO_B1_Badge"],
["GrpCTRG_B2","NATO_B2_Badge"],
["GrpCTRG_B3","NATO_B3_Badge"],
["GrpCTRG_CSL","NATO_CSL_Badge"],
["GrpCTRG_C1","NATO_C1_Badge"],
["GrpCTRG_C2","NATO_C2_Badge"],
["GrpCTRG_C3","NATO_C3_Badge"],
["GrpCTRG_CO","NATO_CO_Badge"],
["GrpCTRG_DC","NATO_DC_Badge"]
];
};
case (_faction in ["blu_g_f","opf_g_f","ind_g_f","fia"]) : {
_groupBadges = [
["GrpFIA_ASL","NATO_ASL_Badge"],
["GrpFIA_A1","NATO_A1_Badge"],
Expand All @@ -286,11 +285,8 @@ switch (_faction) do
["GrpFIA_C2","NATO_C2_Badge"],
["GrpFIA_C3","NATO_C3_Badge"],
["GrpFIA_CO","NATO_CO_Badge"],
["GrpFIA_DC","NATO_DC_Badge"]
];
};
case "opf_g_f" :{
_groupBadges = [
["GrpFIA_DC","NATO_DC_Badge"],

["GrpOFIA_ASL","NATO_ASL_Badge"],
["GrpOFIA_A1","NATO_A1_Badge"],
["GrpOFIA_A2","NATO_A2_Badge"],
Expand All @@ -304,11 +300,8 @@ switch (_faction) do
["GrpOFIA_C2","NATO_C2_Badge"],
["GrpOFIA_C3","NATO_C3_Badge"],
["GrpOFIA_CO","NATO_CO_Badge"],
["GrpOFIA_DC","NATO_DC_Badge"]
];
};
case "ind_g_f" :{
_groupBadges = [
["GrpOFIA_DC","NATO_DC_Badge"],

["GrpIFIA_ASL","NATO_ASL_Badge"],
["GrpIFIA_A1","NATO_A1_Badge"],
["GrpIFIA_A2","NATO_A2_Badge"],
Expand All @@ -325,7 +318,7 @@ switch (_faction) do
["GrpIFIA_DC","NATO_DC_Badge"]
];
};
case "ind_c_f" :{
case (_faction in ["ind_c_f","syndikat"]) :{
_groupBadges = [
["GrpSyndikat_ASL","NATO_ASL_Badge"],
["GrpSyndikat_A1","NATO_A1_Badge"],
Expand All @@ -343,7 +336,7 @@ switch (_faction) do
["GrpSyndikat_DC","NATO_DC_Badge"]
];
};
case "ind_l_f" :{
case (_faction in ["ind_l_f","npr"]) :{
_groupBadges = [
["GrpNPR_ASL","NATO_ASL_Badge"],
["GrpNPR_A1","NATO_A1_Badge"],
Expand All @@ -361,7 +354,7 @@ switch (_faction) do
["GrpNPR_DC","NATO_DC_Badge"]
];
};
case "3ifb" :{
case (_faction in ["3ifb"]) :{
_groupBadges = [
["Grp3IFB_ASL","NATO_ASL_Badge"],
["Grp3IFB_A1","NATO_A1_Badge"],
Expand Down
18 changes: 9 additions & 9 deletions f/briefing/fn_createBriefing.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -49,13 +49,13 @@ if (serverCommandAvailable "#kick" || !isMultiplayer) then {
// The following code blocks include faction-specific briefing files.

// BLUFOR > NATO
if (_unitfaction in ["blu_f","blu_t_f","blu_w_f"]) exitwith {
if (_unitfaction in ["blu_f","blu_t_f","blu_w_f","nato","natowoodland","natopacific"]) exitwith {
#include "f_briefing_nato.sqf"
[_unitfaction] call _fnc_debug;
};

// FIA
if (_unitfaction in ["blu_g_f","ind_g_f","opf_g_f"]) exitwith {
if (_unitfaction in ["blu_g_f","ind_g_f","opf_g_f","fia"]) exitwith {
#include "f_briefing_fia.sqf"
[_unitfaction] call _fnc_debug;
};
Expand All @@ -67,44 +67,44 @@ if (_unitfaction in ["blu_gen_f"]) exitwith {
};

// OPFOR > CSAT
if (_unitfaction in ["opf_f","opf_t_f"]) exitwith {
if (_unitfaction in ["opf_f","opf_t_f","csat","csatpacific"]) exitwith {
#include "f_briefing_csat.sqf"
[_unitfaction] call _fnc_debug;
};

// OPFOR > Spetsnaz
if (_unitfaction in ["opf_r_f"]) exitwith {
if (_unitfaction in ["opf_r_f","spetsnaz"]) exitwith {
#include "f_briefing_spetsnaz.sqf"
[_unitfaction] call _fnc_debug;
};

// INDEPENDENT > AAF
if (_unitfaction in ["ind_f"]) exitwith {
if (_unitfaction in ["ind_f","aaf"]) exitwith {
#include "f_briefing_aaf.sqf"
[_unitfaction] call _fnc_debug;
};

// INDEPENDENT > LDF
if (_unitfaction in ["ind_e_f"]) exitwith {
if (_unitfaction in ["ind_e_f","ldf"]) exitwith {
#include "f_briefing_ldf.sqf"
[_unitfaction] call _fnc_debug;
};

// INDEPENDENT > SYNDIKAT
if (_unitfaction in ["ind_c_f"]) exitwith {
if (_unitfaction in ["ind_c_f","syndikat"]) exitwith {
#include "f_briefing_syndikat.sqf"
[_unitfaction] call _fnc_debug;
};

// INDEPENDENT > NPR (Looters)
if (_unitfaction in ["ind_l_f"]) exitwith {
if (_unitfaction in ["ind_l_f","npr"]) exitwith {
#include "f_briefing_npr.sqf"
[_unitfaction] call _fnc_debug;
};


// BLUFOR > CTRG
if (_unitfaction in ["blu_ctrg_f"]) exitwith {
if (_unitfaction in ["blu_ctrg_f","ctrg"]) exitwith {
#include "f_briefing_ctrg.sqf"
[_unitfaction] call _fnc_debug;
};
Expand Down
39 changes: 22 additions & 17 deletions f/groupMarkers/f_setLocalGroupMarkers.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -22,53 +22,63 @@ params [

private _groups = [];

// Markers seen by players in NATO, NATO (Pacific) & CTRG slots.
if (_unitfaction in ["blu_f","blu_t_f","blu_ctrg_f","blu_w_f"]) then {
// Markers seen by players in NATO, NATO (Pacific) & NATO (Woodland) slots.
if (_unitfaction in ["blu_f","blu_t_f","blu_w_f","nato","natowoodland","natopacific"]) then {
_groups = f_var_groupData_blufor_nato;
};

// Markers seen by players in FIA & CTRG slots.
if (_unitfaction in ["blu_g_f","blu_ctrg_f"]) then {
// Markers seen by players in FIA slots. Move "fia" to OPFOR FIA or INDFOR FIA if using them.
if (_unitfaction in ["blu_g_f","fia"]) then {
_groups = f_var_groupData_blufor_fia;
};

// Markers seen by players in gendarmerie slots.
// Markers seen by players in Gendarmerie slots.
if (_unitfaction in ["blu_gen_f"]) then {
_groups = f_var_groupData_blufor_gen;
};

NikkoJT marked this conversation as resolved.
Show resolved Hide resolved
// Markers seen by players in CTRG slots.
if (_unitfaction in ["blu_ctrg_f","ctrg"]) then {
_groups = f_var_groupData_blufor_ctrg;
};

// Markers seen by players in CSAT & CSAT (Pacific) slots.
if (_unitfaction in ["opf_f","opf_t_f"]) then {
if (_unitfaction in ["opf_f","opf_t_f","csat","csatpacific"]) then {
_groups = f_var_groupData_opfor_csat;
};

// Markers seen by players in OPFOR-FIA slots.
// Markers seen by players in OPFOR-FIA slots. Add "fia" if using "fia" with Virtual Faction, and remove it from BLUFOR FIA.
if (_unitfaction in ["opf_g_f"]) then {
_groups = f_var_groupData_opfor_fia;
};

// Markers seen by players in Spetsnaz slots.
if (_unitfaction in ["opf_r_f"]) then {
if (_unitfaction in ["opf_r_f","spetsnaz"]) then {
_groups = f_var_groupData_opfor_spetsnaz;
};

// Markers seen by players in NPR (Looters) slots.
if (_unitfaction in ["ind_l_f","npr"]) then {
_groups = f_var_groupData_opfor_npr;
};

// Markers seen by players in AAF slots.
if (_unitfaction in ["ind_f"]) then {
if (_unitfaction in ["ind_f","aaf"]) then {
_groups = f_var_groupData_indfor_aaf;
};

// Markers seen by players in LDF slots.
if (_unitfaction in ["ind_e_f"]) then {
if (_unitfaction in ["ind_e_f","ldf"]) then {
_groups = f_var_groupData_indfor_ldf;
};

// Markers seen by players in INDEPENDENT-FIA slots.
// Markers seen by players in INDEPENDENT-FIA slots. Add "fia" if using "fia" with Virtual Faction, and remove it from BLUFOR FIA.
if (_unitfaction in ["ind_g_f"]) then {
_groups = f_var_groupData_indfor_fia;
};

// Markers seen by players in SYNDIKAT slots.
if (_unitfaction in ["ind_c_f"]) then {
if (_unitfaction in ["ind_c_f","syndikat"]) then {
_groups = f_var_groupData_indfor_syn;
};

Expand All @@ -77,11 +87,6 @@ if (_unitfaction in ["3ifb"]) then {
_groups = f_var_groupData_indfor_3ifb;
};

// Markers seen by players in NPR (Looters) slots.
if (_unitfaction in ["ind_l_f"]) then {
_groups = f_var_groupData_indfor_npr;
};

// Markers seen by players in Civilian slots.
if (_unitfaction in ["civ_f","civ_idap_f"]) then {
_groups = f_var_groupData_civ;
Expand Down
Loading