summaryrefslogtreecommitdiffstats
path: root/Client/Functions/Client_InitTownsAndCamps.sqf
diff options
context:
space:
mode:
authorhybrid <hybrid@hybridlabs.pro>2026-06-11 19:53:22 +0300
committerhybrid <hybrid@hybridlabs.pro>2026-06-11 19:53:22 +0300
commitc055d44dcdb87e8db49fb23e632fc086aa44cce6 (patch)
tree7ac98d865915930bebc86b36b512a859c31538e5 /Client/Functions/Client_InitTownsAndCamps.sqf
downloada2wf_zargabad-c055d44dcdb87e8db49fb23e632fc086aa44cce6.tar.gz
a2wf_zargabad-c055d44dcdb87e8db49fb23e632fc086aa44cce6.tar.bz2
a2wf_zargabad-c055d44dcdb87e8db49fb23e632fc086aa44cce6.zip
init
Diffstat (limited to 'Client/Functions/Client_InitTownsAndCamps.sqf')
-rw-r--r--Client/Functions/Client_InitTownsAndCamps.sqf40
1 files changed, 40 insertions, 0 deletions
diff --git a/Client/Functions/Client_InitTownsAndCamps.sqf b/Client/Functions/Client_InitTownsAndCamps.sqf
new file mode 100644
index 0000000..cdddcbc
--- /dev/null
+++ b/Client/Functions/Client_InitTownsAndCamps.sqf
@@ -0,0 +1,40 @@
+Private ["_camp","_campSideID","_camps","_count","_count1","_marker","_town","_townSideID"];
+
+for [{_count = totalTowns - 1},{_count >= 0},{_count = _count - 1}] do {
+ _town = towns select _count;
+ _townSideID = _town getVariable "sideID";
+
+ if (sideID == _townSideID) then {
+ _marker = Format["%1Depot",str _town];
+ _marker setMarkerColorLocal ("Friendly" Call GetMarkerColoration);
+ };
+
+ while {true} do {
+ sleep .005;
+ _camps = _town getVariable "camps";
+ if !(isNil "_camps") exitWith {};
+ };
+ _camps = _town getVariable "camps";
+
+ for [{_count1 = count _camps - 1},{_count1 >= 0},{_count1 = _count1 - 1}] do {
+ _camp = _camps select _count1;
+ if !(isNull _camp) then {
+ _marker = Format["%1Camp%2",str _town,_camps find _camp];
+
+ while {true} do {
+ sleep .005;
+ _campSideID = _camp getVariable "sideID";
+ if !(isNil "_campSideID") exitWith {};
+ };
+ _campSideID = _camp getVariable "sideID";
+
+ if (sideID == _campSideID) then {
+ _marker setMarkerColorLocal ("Friendly" Call GetMarkerColoration);
+ } else{
+ if (_townSideID == sideID) then {
+ _marker setMarkerColorLocal ("Enemy" Call GetMarkerColoration);
+ };
+ };
+ };
+ };
+}; \ No newline at end of file