Skip to content

Commit

Permalink
Added multi-side support
Browse files Browse the repository at this point in the history
  • Loading branch information
Giallustio committed Oct 5, 2015
1 parent a0626ce commit c8d49d0
Show file tree
Hide file tree
Showing 8 changed files with 76 additions and 30 deletions.
3 changes: 3 additions & 0 deletions =BTC=co@22_Hearts_and_Minds.Altis/core/def/mission.sqf
Expand Up @@ -349,6 +349,7 @@ btc_player_side = west;
btc_respawn_marker = "respawn_west";
switch (true) do {
case (_p_en == 0) : {
btc_hq = btc_hq_red;
btc_enemy_side = east;
btc_type_units = ["O_G_Soldier_F","O_G_Soldier_TL_F","O_G_Soldier_AR_F","O_G_engineer_F","O_G_Soldier_exp_F","O_G_Soldier_GL_F","O_G_Soldier_LAT_F"];
btc_type_crewmen = "O_G_Soldier_F";
Expand All @@ -358,6 +359,7 @@ switch (true) do {
btc_type_gl = ["O_GMG_01_F","O_GMG_01_high_F"];
};
case (_p_en == 1 && isClass(configFile >> "cfgVehicles" >> "CAF_AG_ME_T_AK47")) : {
btc_hq = btc_hq_red;
btc_enemy_side = east;
btc_type_units = ["CAF_AG_ME_AK47","CAF_AG_ME_T_AK74","CAF_AG_ME_T_PKM","CAF_AG_ME_T_RPK74","CAF_AG_ME_T_RPG","CAF_AG_ME_T_GL"];
btc_type_crewmen = "CAF_AG_ME_T_AK47";
Expand All @@ -368,6 +370,7 @@ switch (true) do {
btc_civ_type_units = ["CAF_AG_ME_CIV","CAF_AG_ME_CIV_02","CAF_AG_ME_CIV_03","CAF_AG_ME_CIV_04"];
};
default {
btc_hq = btc_hq_red;
btc_enemy_side = east;
btc_type_units = ["O_G_Soldier_F","O_G_Soldier_TL_F","O_G_Soldier_AR_F","O_G_engineer_F","O_G_Soldier_exp_F","O_G_Soldier_GL_F","O_G_Soldier_LAT_F"];
btc_type_crewmen = "O_G_Soldier_F";
Expand Down
Expand Up @@ -12,7 +12,7 @@ if (count _this > 2) then {_units = _this select 2;} else {_units = _pos nearEnt

[_x] spawn btc_fnc_civ_add_weapons;

[_x] joinSilent btc_hq_red;
[_x] joinSilent btc_hq;
[_x] joinSilent GrpNull;

_array_id = _x getVariable "btc_rep_eh_added";
Expand Down
2 changes: 1 addition & 1 deletion =BTC=co@22_Hearts_and_Minds.Altis/core/fnc/db/load.sqf
Expand Up @@ -89,7 +89,7 @@ _array_ho = profileNamespace getVariable ["btc_hm_ho",[]];
} foreach _array_ho;

_ho = profileNamespace getVariable ["btc_hm_ho_sel",objNull];
btc_hq_red getVariable ["info_hideout",_ho];
btc_hq getVariable ["info_hideout",_ho];
//CACHE

btc_cache_cities = + btc_city_all;
Expand Down
2 changes: 1 addition & 1 deletion =BTC=co@22_Hearts_and_Minds.Altis/core/fnc/db/save.sqf
Expand Up @@ -64,7 +64,7 @@ _array_ho = [];
} foreach btc_hideouts;
profileNamespace setVariable ["btc_hm_ho",_array_ho];

profileNamespace setVariable ["btc_hm_ho_sel",(btc_hq_red getVariable ["info_hideout",objNull])];
profileNamespace setVariable ["btc_hm_ho_sel",(btc_hq getVariable ["info_hideout",objNull])];

//CACHE
_array_cache = [];
Expand Down
@@ -1,7 +1,7 @@

private ["_trigger","_array","_expl1","_expl2","_expl3","_man","_cond"];

[_this] joinSilent btc_hq_red;
[_this] joinSilent btc_hq;
[_this] joinSilent GrpNull;

while {(count (waypoints group _this)) > 0} do { deleteWaypoint ((waypoints group _this) select 0); };
Expand Down
4 changes: 2 additions & 2 deletions =BTC=co@22_Hearts_and_Minds.Altis/core/fnc/info/hideout.sqf
Expand Up @@ -5,11 +5,11 @@ if (count btc_hideouts == 0) exitWith {};

private ["_ho","_pos","_marker","_array"];

_ho = btc_hq_red getVariable ["info_hideout",objNull];
_ho = btc_hq getVariable ["info_hideout",objNull];

if (isNull _ho) then {
_ho = btc_hideouts select (floor random count btc_hideouts);
btc_hq_red setVariable ["info_hideout",_ho];
btc_hq setVariable ["info_hideout",_ho];
};

_pos = [
Expand Down
Expand Up @@ -32,7 +32,7 @@ if (_explosive && {_damage > 0.6}) then {

{deleteMarker _x} foreach _array;

if (btc_hq_red getVariable ["info_hideout",objNull] isEqualTo _hideout) then {btc_hq_red setVariable ["info_hideout",objNull]};
if (btc_hq getVariable ["info_hideout",objNull] isEqualTo _hideout) then {btc_hq setVariable ["info_hideout",objNull]};

if (count btc_hideouts == 0) then {[] execVM "core\fnc\common\final_phase.sqf";};

Expand Down
89 changes: 66 additions & 23 deletions =BTC=co@22_Hearts_and_Minds.Altis/mission.sqm
Expand Up @@ -25,7 +25,8 @@ class Mission
"ace_respawn",
"ace_captives",
"ace_repair",
"A3_Modules_F_Multiplayer"
"A3_Modules_F_Multiplayer",
"A3_Characters_F_INDEP"
};
addOnsAuto[]=
{
Expand All @@ -40,6 +41,7 @@ class Mission
"ace_captives",
"ace_repair",
"A3_Modules_F_Multiplayer",
"A3_Characters_F_INDEP",
"rhsusf_c_hmmwv",
"rhsusf_vehicles",
"RHS_US_A2Port_Armor",
Expand Down Expand Up @@ -74,7 +76,7 @@ class Mission
};
class Groups
{
items=32;
items=34;
class Item0
{
side="WEST";
Expand Down Expand Up @@ -105,6 +107,7 @@ class Mission
class Item0
{
position[]={8320.2334,75.940002,10044.377};
azimut=180;
id=1;
side="EAST";
vehicle="O_officer_F";
Expand Down Expand Up @@ -1020,6 +1023,46 @@ class Mission
};
};
};
class Item32
{
side="WEST";
class Vehicles
{
items=1;
class Item0
{
position[]={8321.8301,75.940002,10044.296};
azimut=180;
id=32;
side="WEST";
vehicle="B_Soldier_F";
leader=1;
skill=0.60000002;
text="btc_hq_blu";
init="if (isServer) then {this enableSimulation false;hideObjectGlobal this;this allowDamage false;};";
};
};
};
class Item33
{
side="GUER";
class Vehicles
{
items=1;
class Item0
{
position[]={8323.3779,75.940002,10044.296};
azimut=180;
id=33;
side="GUER";
vehicle="I_soldier_F";
leader=1;
skill=0.60000002;
text="btc_hq_green";
init="if (isServer) then {this enableSimulation false;hideObjectGlobal this;this allowDamage false;};";
};
};
};
};
class Vehicles
{
Expand All @@ -1028,7 +1071,7 @@ class Mission
{
position[]={8303.3174,76.190857,10075.396};
azimut=-35.819302;
id=32;
id=34;
side="EMPTY";
vehicle="rhsusf_m1025_d_m2";
skill=0.60000002;
Expand All @@ -1039,7 +1082,7 @@ class Mission
{
position[]={8297.7109,76.460014,10071.711};
azimut=-35.819302;
id=33;
id=35;
side="EMPTY";
vehicle="rhsusf_m1025_d_m2";
skill=0.60000002;
Expand All @@ -1050,7 +1093,7 @@ class Mission
{
position[]={8294.7607,75.982056,10054.311};
azimut=-32.3554;
id=34;
id=36;
side="EMPTY";
vehicle="RHS_M2A3";
skill=0.60000002;
Expand All @@ -1061,7 +1104,7 @@ class Mission
{
position[]={8332.0459,74.932884,10088.11};
azimut=-33.0196;
id=35;
id=37;
side="EMPTY";
vehicle="RHS_CH_47F_10";
skill=0.60000002;
Expand All @@ -1073,7 +1116,7 @@ class Mission
{
position[]={8317.4258,75.55719,10084.844};
azimut=-35.819302;
id=36;
id=38;
side="EMPTY";
vehicle="rhsusf_m1025_d_m2";
skill=0.60000002;
Expand All @@ -1084,7 +1127,7 @@ class Mission
{
position[]={8306.3936,75.492081,10095.719};
azimut=54.025799;
id=37;
id=39;
side="EMPTY";
vehicle="B_Truck_01_transport_F";
skill=0.60000002;
Expand All @@ -1095,7 +1138,7 @@ class Mission
{
position[]={8278.2324,77.207802,10077.172};
azimut=83.1604;
id=38;
id=40;
side="EMPTY";
vehicle="rhsusf_m1025_d_m2";
skill=0.60000002;
Expand All @@ -1106,7 +1149,7 @@ class Mission
{
position[]={8290.8086,76.579704,10084.995};
azimut=54.025799;
id=39;
id=41;
side="EMPTY";
vehicle="B_Truck_01_transport_F";
skill=0.60000002;
Expand All @@ -1117,7 +1160,7 @@ class Mission
{
position[]={8267.8184,78.472908,10064.535};
azimut=54.846901;
id=40;
id=42;
side="EMPTY";
vehicle="rhsusf_rg33_m2_d";
skill=0.60000002;
Expand All @@ -1128,7 +1171,7 @@ class Mission
{
position[]={8273.3438,78.904205,10058.275};
azimut=37.431702;
id=41;
id=43;
side="EMPTY";
vehicle="rhsusf_rg33_m2_d";
skill=0.60000002;
Expand All @@ -1139,7 +1182,7 @@ class Mission
{
position[]={8320.2695,74.51561,10105.956};
azimut=-34.7295;
id=42;
id=44;
side="EMPTY";
vehicle="Land_CargoBox_V1_F";
skill=0.60000002;
Expand All @@ -1150,7 +1193,7 @@ class Mission
{
position[]={8323.1582,73.944031,10113.102};
azimut=51.220901;
id=43;
id=45;
side="EMPTY";
vehicle="Land_HelipadSquare_F";
skill=0.60000002;
Expand All @@ -1162,7 +1205,7 @@ class Mission
{
position[]={8309.2539,75.963928,10068.322};
azimut=-34.7295;
id=44;
id=46;
side="EMPTY";
vehicle="Land_CargoBox_V1_F";
skill=0.60000002;
Expand All @@ -1173,7 +1216,7 @@ class Mission
{
position[]={8209.9434,76.416351,10021.622};
azimut=-27.934999;
id=45;
id=47;
side="EMPTY";
vehicle="RHS_AH64D";
skill=0.60000002;
Expand All @@ -1184,7 +1227,7 @@ class Mission
{
position[]={8209.9336,76.380455,10022.721};
azimut=51.220901;
id=46;
id=48;
side="EMPTY";
vehicle="Land_HelipadSquare_F";
skill=0.60000002;
Expand All @@ -1193,7 +1236,7 @@ class Mission
{
position[]={8358.6895,73.372658,10100.906};
azimut=-37.320667;
id=47;
id=49;
side="EMPTY";
vehicle="B_Truck_01_ammo_F";
skill=0.60000002;
Expand All @@ -1204,7 +1247,7 @@ class Mission
{
position[]={8353.4756,73.568039,10097.638};
azimut=-37.320667;
id=48;
id=50;
side="EMPTY";
vehicle="B_Truck_01_fuel_F";
skill=0.60000002;
Expand All @@ -1215,7 +1258,7 @@ class Mission
{
position[]={8348.7539,73.829521,10094.76};
azimut=-37.320667;
id=49;
id=51;
side="EMPTY";
vehicle="B_Truck_01_Repair_F";
skill=0.60000002;
Expand All @@ -1225,7 +1268,7 @@ class Mission
class Item18
{
position[]={8316.8945,75.622955,10074.888};
id=50;
id=52;
side="EMPTY";
vehicle="Flag_NATO_F";
skill=0.60000002;
Expand All @@ -1234,7 +1277,7 @@ class Mission
{
position[]={8241.458,77.378105,10048.173};
azimut=-27.934999;
id=51;
id=53;
side="EMPTY";
vehicle="RHS_UH1Y_d";
skill=0.60000002;
Expand All @@ -1245,7 +1288,7 @@ class Mission
{
position[]={8240.2227,77.387703,10049.465};
azimut=51.220901;
id=52;
id=54;
side="EMPTY";
vehicle="Land_HelipadSquare_F";
skill=0.60000002;
Expand Down

0 comments on commit c8d49d0

Please sign in to comment.