mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
aecafe673b
* Fix "Recharge" interaction showing on destroyed drone * Add "Follow Unit" action * Improve condition check * UGV Following via PFH that updates WP Pos * Use HOLD WP for all Follow Actions Since FOLLOW WP would stop working on AI Soldiers after some time. * Allow selecting a follow distance * Follow Distance under separate interaction, just like Loiter Alt Only visible when a HOLD waypoint is selected, which is pretty much always going to have been created by the "Follow" interaction. * Localize "Follow" Interaction * Show structuredText Hint when following/changing distance * Variable for cursorTarget Reuse * Better isKindOf condition use * Make "Ship"-kind vehicles followable * Clean up Comments and systemChat Debugs * Comment explanation for custom PFH solution over vanilla "Follow"-WP * Trim excess brackets from setWaypointPosition argument Co-Authored-By: johnb432 <58661205+johnb432@users.noreply.github.com> * Broader determination for UGV follow distances Co-Authored-By: PabstMirror <pabstmirror@gmail.com> * Prevent infinite PFH loop if follow target is deleted Co-Authored-By: PabstMirror <pabstmirror@gmail.com> * Delete Follow WP when PFH terminates * The ternary rules Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com> * Various requested changes Co-Authored-By: johnb432 <58661205+johnb432@users.noreply.github.com> --------- Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com> Co-authored-by: PabstMirror <pabstmirror@gmail.com>
22 lines
553 B
Plaintext
22 lines
553 B
Plaintext
#include "..\script_component.hpp"
|
|
/*
|
|
* Author: marc_book
|
|
* Tests if unit can refuel the target UAV
|
|
*
|
|
* Arguments:
|
|
* 0: Player <OBJECT>
|
|
* 1: UAV <OBJECT>
|
|
*
|
|
* Return Value:
|
|
* Can the player rechange the UAV <BOOL>
|
|
*
|
|
* Example:
|
|
* [player, theUAV] call ace_logistics_uavbattery_fnc_canRefuelUAV
|
|
*
|
|
* Public: No
|
|
*/
|
|
|
|
params ["_caller", "_target"];
|
|
|
|
(alive _target) && {"ACE_UAVBattery" in (_caller call EFUNC(common,uniqueItems))} && {(fuel _target) < 1} && {(speed _target) < 1} && {!(isEngineOn _target)} && {(_target distance _caller) <= 4}
|