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

Major Update 240707 #25

Merged
merged 6 commits into from
Jul 7, 2024
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
2 changes: 1 addition & 1 deletion Missionframework/KPLIB_transportConfigs.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ KPLIB_transportConfigs = [
["rhsusf_mtvr_mk27_apk_wd", -6.5, [0,0.9,-0.3],[0,-0.6,-0.3],[0,-2.1,-0.3],[0,-3.6,-0.3]],
["rhsusf_mtvr_mk27_apk_m2_wd", -6.5, [0,0.9,-0.75],[0,-0.6,-0.75],[0,-2.1,-0.75],[0,-3.6,-0.75]],
["rhusf_m1077a1_flatrack_Base", -6.5, [0,2,0.1],[0,0.6,0.1],[0,-0.8,0.1],[0,-2.2,0.1]],
["rhusf_m1077a1_flatrack_wd", -6.5, [0,2,0.1],[0,0.6,0.1],[0,-0.8,0.1],[0,-2.2,0.1]],
["rhusf_m1077a1_wd", -6.5, [0,2,0.1],[0,0.6,0.1],[0,-0.8,0.1],[0,-2.2,0.1]],
["rhsusf_m871_trailer_wd", -6.5, [-0,4.2,0.65],[0.73,2.8,0.65],[-0.73,2.8,0.65],[0.73,1.4,0.65],[-0.73,1.4,0.65],[0.73,0,0.65],[-0.73,0,0.65],[0.73,-1.4,0.65],[-0.73,-1.4,0.65],[0.73,-2.8,0.65],[-0.73,-2.8,0.65],[-0,4.2,1.68],[0.73,2.8,1.68],[-0.73,2.8,1.68],[0.73,1.4,1.68],[-0.73,1.4,1.68],[0.73,0,1.68],[-0.73,0,1.68],[0.73,-1.4,1.68],[-0.73,-1.4,1.68],[0.73,-2.8,1.68],[-0.73,-2.8,1.68]],
["rhsusf_m870_trailer_wd", -6.5, [0.73,2.9,0.25],[-0.73,2.9,0.25],[0.73,1.5,0.25],[-0.73,1.5,0.25],[0.73,0.1,0.25],[-0.73,0.1,0.25],[0.73,-1.3,0.25],[-0.73,-1.3,0.25],[0.73,-2.7,0.25],[-0.73,-2.7,0.25],[0.73,-4.1,0.25],[-0.73,-4.1,0.25],[0.73,2.9,1.28],[-0.73,2.9,1.28],[0.73,1.5,1.28],[-0.73,1.5,1.28],[0.73,0.1,1.28],[-0.73,0.1,1.28],[0.73,-1.3,1.28],[-0.73,-1.3,1.28],[0.73,-2.7,1.28],[-0.73,-2.7,1.28],[0.73,-4.1,1.28],[-0.73,-4.1,1.28]],
["SX2220", -6.5, [0,0.15,-0.6],[0,-1.35,-0.6],[0,-2.85,-0.6]],
Expand Down
2 changes: 1 addition & 1 deletion Missionframework/functions/fn_spawnVehicle.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ if (_spawnPos isEqualTo []) exitWith {
// If it's a chopper, spawn it flying
if (_classname in KPLIB_o_helicopters) then {
_newvehicle = createVehicle [_classname, _spawnpos, [], 0, 'FLY'];
_newvehicle flyInHeight (80 + (random 120));
_newvehicle flyInHeight (100 + (random 120));
_newvehicle allowDamage false;
} else {
_newvehicle = _classname createVehicle _spawnpos;
Expand Down
11 changes: 7 additions & 4 deletions Missionframework/scripts/client/civinformant/civinfo_escort.sqf
Original file line number Diff line number Diff line change
@@ -1,26 +1,29 @@
scriptName "civinfo_escort";

params ["_informant"];
private [ "_nearestfob", "_is_near_fob", "_grp" ];

waitUntil {sleep 0.5; local _unit};
waitUntil {sleep 0.5; local _informant};

if (KPLIB_civinfo_debug > 0) then {[format ["civinfo_escort called on: %1 - Parameters: [%2]", debug_source, _informant], "CIVINFO"] remoteExecCall ["KPLIB_fnc_log", 2];};

private _is_near_fob = false;
_is_near_fob = false;

waitUntil {
sleep 5;
private _nearestfob = [getPos _informant] call KPLIB_fnc_getNearestFob;
_nearestfob = [ getpos _informant ] call KPLIB_fnc_getNearestFob;
_is_near_fob = false;
if (count _nearestfob == 3) then {
_is_near_fob = ((_informant distance _nearestfob) < 30);
};

!alive _informant || (_is_near_fob && (vehicle _informant == _informant))
};

if (alive _informant) then {
if (_is_near_fob) then {
sleep 5;
private _grp = createGroup [KPLIB_side_civilian, true];
_grp = createGroup [KPLIB_side_civilian, true];
[_informant] joinSilent _grp;
if (KPLIB_ace) then {
private _isCuffed = _informant getVariable ["ace_captives_isHandcuffed", false];
Expand Down
Original file line number Diff line number Diff line change
@@ -1,25 +1,21 @@
scriptName "remote_call_prisoner";

params [ "_unit" ];
private [ "_nearestfob", "_is_near_fob", "_is_near_blufor", "_grp", "_waypoint", "_nearblufor" ];
private [ "_nearestfob", "_is_near_fob", "_is_near_blufor", "_grp", "_waypoint" ];

waitUntil {
sleep 0.5;
local _unit
};
waitUntil {sleep 0.5; local _unit};

if ( typeof _unit == KPLIB_b_heliPilotUnit ) exitWith {};

_is_near_fob = false;
_is_near_blufor = true;

waitUntil { sleep 5;

waitUntil {
sleep 5;
_nearestfob = [ getpos _unit ] call KPLIB_fnc_getNearestFob;
if ( count _nearestfob == 3) then {
if ( ( _unit distance _nearestfob ) < 30 ) then {
_is_near_fob = true;
};
_is_near_fob = false;
if (count _nearestfob == 3) then {
_is_near_fob = ((_unit distance _nearestfob) < 30);
};

_is_near_blufor = false;
Expand Down
3 changes: 3 additions & 0 deletions Missionframework/scripts/server/ai/SAM_turret_manager.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,9 @@ while {KPLIB_endgame == 0} do {
if (_groupDestroyed) exitWith {};
if (!alive _x || !alive gunner _x || side _x != KPLIB_side_enemy) then {
_groupDestroyed = true;
} else {
_x setVehicleAmmo 1;
_x setFuel 1;
};
} forEach _groupVehicles;
if (_groupDestroyed) then {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ while { KPLIB_endgame == 0 } do {

_spawn_marker = "";
while { _spawn_marker == "" } do {
_spawn_marker = [1500,4000,true] call KPLIB_fnc_getOpforSpawnPoint;
_spawn_marker = [(KPLIB_range_pointActivation*1),(KPLIB_range_pointActivation*4),true] call KPLIB_fnc_getOpforSpawnPoint;
if ( _spawn_marker == "" ) then {
sleep (150 + (random 150));
};
Expand Down
10 changes: 5 additions & 5 deletions Missionframework/scripts/server/patrols/send_paratroopers.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ sleep 0.2;
{_x doFollow leader _para_group} forEach units _para_group;
sleep 0.2;

_newvehicle flyInHeight 100;
_newvehicle flyInHeight 150;

_waypoint = _pilot_group addWaypoint [_targetpos, 25];
_waypoint setWaypointType "MOVE";
Expand Down Expand Up @@ -92,21 +92,21 @@ _waypoint setWaypointType "MOVE";
_waypoint setWaypointCompletionRadius 50;
_pilot_group setCurrentWaypoint [_para_group, 1];

_newvehicle flyInHeight 100;
_newvehicle flyInHeight 150;

waitUntil {sleep 1;
!(alive _newvehicle) || (damage _newvehicle > 0.2 ) || (_newvehicle distance _targetpos < 400)
};

_newvehicle flyInHeight 100;
_newvehicle flyInHeight 150;

{
unassignVehicle _x;
moveout _x;
sleep 0.5;
} forEach (units _para_group);

_newvehicle flyInHeight 100;
_newvehicle flyInHeight 150;

sleep 0.2;
while {(count (waypoints _pilot_group)) != 0} do {deleteWaypoint ((waypoints _pilot_group) select 0);};
Expand All @@ -116,7 +116,7 @@ sleep 0.2;
{_x doFollow leader _para_group} foreach units _para_group;
sleep 0.2;

_newvehicle flyInHeight 100;
_newvehicle flyInHeight 150;

_waypoint = _pilot_group addWaypoint [_targetpos, 200];
_waypoint setWaypointBehaviour "COMBAT";
Expand Down