mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Fix missing refuel menu on static fuel stations (#4533)
* fix static fuel stations * Directly compile menus and remove XEH from buildings
This commit is contained in:
parent
2151fcad8f
commit
cc3b669fcd
@ -144,13 +144,11 @@ class CfgVehicles {
|
||||
class House_F: House {};
|
||||
|
||||
class House_Small_F: House_F {
|
||||
class EventHandlers;
|
||||
|
||||
class ACE_Actions {
|
||||
class ACE_MainActions {
|
||||
displayName = ECSTRING(interaction,MainAction);
|
||||
selection = "";
|
||||
distance = 10;
|
||||
distance = 5;
|
||||
condition = "true";
|
||||
};
|
||||
};
|
||||
@ -501,10 +499,6 @@ class CfgVehicles {
|
||||
|
||||
// Vanilla buildings
|
||||
class Land_Fuelstation_Feed_F: House_Small_F {
|
||||
class EventHandlers {
|
||||
class CBA_Extended_EventHandlers: CBA_Extended_EventHandlers {};
|
||||
};
|
||||
|
||||
transportFuel = 0; //50k
|
||||
MACRO_REFUEL_ACTIONS
|
||||
GVAR(hooks)[] = {{0,0,-0.5}};
|
||||
@ -512,10 +506,6 @@ class CfgVehicles {
|
||||
};
|
||||
|
||||
class Land_fs_feed_F: House_Small_F {
|
||||
class EventHandlers {
|
||||
class CBA_Extended_EventHandlers: CBA_Extended_EventHandlers {};
|
||||
};
|
||||
|
||||
transportFuel = 0; //50k
|
||||
MACRO_REFUEL_ACTIONS
|
||||
GVAR(hooks)[] = {{-0.4,0.022,-.23}};
|
||||
|
@ -11,6 +11,20 @@ if (isServer) then {
|
||||
_this call FUNC(resetLocal);
|
||||
}] call CBA_fnc_addEventHandler;
|
||||
|
||||
// workaround for static fuel stations
|
||||
if (hasInterface) then {
|
||||
{
|
||||
if (
|
||||
configName _x isKindOf "Building" &&
|
||||
{isClass (_x >> "ACE_Actions" >> "ACE_MainActions" >> QGVAR(Refuel))} &&
|
||||
{getNumber (_x >> "scope") == 2}
|
||||
) then {
|
||||
TRACE_1("Compiling menu",configName _x);
|
||||
[configName _x] call EFUNC(interact_menu,compileMenu);
|
||||
};
|
||||
} count ('true' configClasses (configFile >> "CfgVehicles"));
|
||||
};
|
||||
|
||||
|
||||
#ifdef DEBUG_MODE_FULL
|
||||
diag_log text format ["[ACE-refuel] Showing CfgVehicles with vanilla transportFuel"];
|
||||
|
Loading…
Reference in New Issue
Block a user