-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathA3A1.4Barb Spawn Custom Specops Vic.sqf
140 lines (100 loc) · 5.23 KB
/
A3A1.4Barb Spawn Custom Specops Vic.sqf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
//Execute on Global
//Vars:
_typeBike = "B_GEN_Offroad_01_GEN_F"; //FrostB: Custom Vehicle
_whoSpawn = "FrostsBite"; //FrostB: The person who has it spawned near them
_specOpps = ["Digital","Cipher","FrostsBite"]; //FrostB: The Specopps Team who can get in
if (name player == _whoSpawn) exitwith {
_markerX = [markersX,player] call BIS_fnc_nearestPosition;
_sideX = side player;
_nameX = if (_sideX == Occupants) then {nameOccupants} else {nameInvaders};
//FrostB: following location checks are disabled
//if (sidesX getVariable [_markerX,sideUnknown] != _sideX) exitWith {hint format ["You need to be close to a zone belonging to %1 in order to request a vehicle",_nameX]};
//if ((!(_markerX in airportsX)) and (!(_markerX in seaports)) and (!(_markerX in outposts))) exitWith {hint "You need to be close to an Airbase, Seaport or Outpost of your side in order to request a vehicle"};
//if (not(player inArea _markerX)) exitWith {hint "You need to be close to an Airbase, Seaport or Outpost in order to request a vehicle"};
//FrostB: Selects from normal list:
//_typeBike = if (_sideX == Occupants) then {selectRandom vehNATOLightUnarmed} else {selectRandom vehCSATLightUnarmed};
//FrostB: CLears last one:
if (!isNull lastVehicleSpawned) then
{
if (lastVehicleSpawned distance player < 100) then {deleteVehicle moto};
};
hint "Vehicle available";
_pos = [];
_radius = 10;
while {_pos isEqualTo []} do
{
_pos = (position player) findEmptyPosition [5,_radius,"I_Truck_02_covered_F"];
_radius = _radius + 10;
};
lastVehicleSpawned = createVehicle [_typeBike,_pos, [], 10, "NONE"];
[lastVehicleSpawned] call A3A_fnc_AIVEHinit; //FrostB: allows garbage cleaning and the good stuff
//FrostB: Globalizes the identity of last spawn specopp vehical
missionNamespace setVariable ["lastSpecOppVeh",lastVehicleSpawned];
};
if (name player in _specOpps) exitwith {
sleep(1);
lastVehicleSpawned = missionNamespace getVariable "lastSpecOppVeh"; //FrostB: Sets the identity of the last spawned vehicle to the specific player
};
//Execute on Global
//Vars:
_whoSpawn = "FrostsBite"; //FrostB: The person who has it spawned near them
_specOpps = ["Digital","Cipher","FrostsBite"]; //FrostB: The Specopps Team who can get in
if (name player == _whoSpawn) exitwith {
lastVehicleSpawned = cursorTarget;
//FrostB: Globalizes the identity of last spawn specopp vehical
missionNamespace setVariable ["lastSpecOppVeh",lastVehicleSpawned];
};
if (name player in _specOpps) exitwith {
sleep(1);
lastVehicleSpawned = missionNamespace getVariable "lastSpecOppVeh"; //FrostB: Sets the identity of the last spawned vehicle to the specific player
};
//Execute on Global
//Vars:
_typeBike = "B_GEN_Offroad_01_GEN_F"; //FrostB: Custom Vehicle
_whoSpawn = "FrostsBite"; //FrostB: The person who has it spawned near them
_specOpps = ["Digital","Cipher","FrostsBite"]; //FrostB: The Specopps Team who can get in
if (name player == _whoSpawn) exitwith {
_markerX = [markersX,player] call BIS_fnc_nearestPosition;
_sideX = side player;
_nameX = if (_sideX == Occupants) then {nameOccupants} else {nameInvaders};
//FrostB: following location checks are disabled
//if (sidesX getVariable [_markerX,sideUnknown] != _sideX) exitWith {hint format ["You need to be close to a zone belonging to %1 in order to request a vehicle",_nameX]};
//if ((!(_markerX in airportsX)) and (!(_markerX in seaports)) and (!(_markerX in outposts))) exitWith {hint "You need to be close to an Airbase, Seaport or Outpost of your side in order to request a vehicle"};
//if (not(player inArea _markerX)) exitWith {hint "You need to be close to an Airbase, Seaport or Outpost in order to request a vehicle"};
//FrostB: Selects from normal list:
//_typeBike = if (_sideX == Occupants) then {selectRandom vehNATOLightUnarmed} else {selectRandom vehCSATLightUnarmed};
//FrostB: CLears last one:
if (!isNull moto) then
{
if (moto distance player < 100) then {deleteVehicle moto};
};
hint "Vehicle available";
_pos = [];
_radius = 10;
while {_pos isEqualTo []} do
{
_pos = (position player) findEmptyPosition [5,_radius,"I_Truck_02_covered_F"];
_radius = _radius + 10;
};
moto = createVehicle [_typeBike,_pos, [], 10, "NONE"];
[moto] call A3A_fnc_AIVEHinit; //FrostB: allows garbage cleaning and the good stuff
//FrostB: Globalizes the identity of last spawn specopp vehical
missionNamespace setVariable ["lastSpecOppVeh",moto];
};
if (name player in _specOpps) exitwith {
sleep(1);
moto = missionNamespace getVariable "lastSpecOppVeh"; //FrostB: Sets the identity of the last spawned vehicle to the specific player
};
//Execute on Global
//Vars:
_whoSpawn = "FrostsBite"; //FrostB: The person who has it spawned near them
_specOpps = ["Digital","Cipher","FrostsBite"]; //FrostB: The Specopps Team who can get in
if (name player == _whoSpawn) exitwith {
moto = cursorTarget;
//FrostB: Globalizes the identity of last spawn specopp vehical
missionNamespace setVariable ["lastSpecOppVeh",moto];
};
if (name player in _specOpps) exitwith {
sleep(1);
moto = missionNamespace getVariable "lastSpecOppVeh"; //FrostB: Sets the identity of the last spawned vehicle to the specific player
};