Refuel - Improved fuel hose texture (#8983)

* Added custom fuel hose

* Fixed indentation

* Added model config for hose

* Added model config for hose
This commit is contained in:
Samuel Deutsch 2022-08-17 04:00:54 -07:00 committed by GitHub
parent 286537cd54
commit 7a64ccb7a5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 28 additions and 1 deletions

View File

@ -42,6 +42,18 @@
class CBA_Extended_EventHandlers; class CBA_Extended_EventHandlers;
class CfgNonAIVehicles {
class GVAR(fuelHoseSegment) {
access = 0;
scope = 2;
displayName = "Fuel Hose";
simulation = "ropesegment";
autocenter = 0;
animated = 0;
model = QPATHTOF(data\hose.p3d);
};
};
class CfgVehicles { class CfgVehicles {
class ACE_Module; class ACE_Module;
class ACE_moduleRefuelSettings: ACE_Module { class ACE_moduleRefuelSettings: ACE_Module {
@ -83,6 +95,14 @@ class CfgVehicles {
destrType = "DestructNo"; destrType = "DestructNo";
}; };
class Rope;
class GVAR(fuelHose): Rope {
hiddenSelections[] = {"rope"};
hiddenSelectionsTextures[] = {"#(argb,8,8,3)color(0.009,0.009,0.009,1.0,co)"};
segmentType = QGVAR(fuelHoseSegment);
model = QPATHTOF(data\hose.p3d);
};
class All; class All;
class Static: All {}; class Static: All {};
class Building: Static {}; class Building: Static {};

View File

@ -0,0 +1,7 @@
class CfgModels {
class hose {
sectionsInherit = "";
sections[] = {"rope"};
skeletonName = "";
};
};

BIN
addons/refuel/data/hose.p3d Normal file

Binary file not shown.

View File

@ -69,7 +69,7 @@ params [
_attachPos = _attachPos select (_hookDistances find selectMin _hookDistances); _attachPos = _attachPos select (_hookDistances find selectMin _hookDistances);
}; };
private _hoseLength = _source getVariable [QGVAR(hoseLength), GVAR(hoseLength)]; private _hoseLength = _source getVariable [QGVAR(hoseLength), GVAR(hoseLength)];
private _rope = ropeCreate [_ropeTarget, _attachPos, _nozzle, [0, -0.20, 0.12], _hoseLength]; private _rope = ropeCreate [_ropeTarget, _attachPos, _nozzle, [0, -0.20, 0.12], _hoseLength, [], [], QGVAR(fuelHose)];
_nozzle setVariable [QGVAR(rope), _rope, true]; _nozzle setVariable [QGVAR(rope), _rope, true];
_nozzle setVariable [QGVAR(attachPos), _attachPos, true]; _nozzle setVariable [QGVAR(attachPos), _attachPos, true];
_nozzle setVariable [QGVAR(source), _source, true]; _nozzle setVariable [QGVAR(source), _source, true];