Skip to content

Commit

Permalink
General - Relative script_component.hpp includes (#1599)
Browse files Browse the repository at this point in the history
Co-authored-by: PabstMirror <pabstmirror@gmail.com>
  • Loading branch information
jonpas and PabstMirror authored Sep 12, 2023
1 parent eab161e commit ba78984
Show file tree
Hide file tree
Showing 28 changed files with 28 additions and 29 deletions.
2 changes: 1 addition & 1 deletion addons/jam/jam_finish/script_component.hpp
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
#define SUBCOMPONENT finish
#include "\x\cba\addons\jam\script_component.hpp"
#include "..\script_component.hpp"
2 changes: 1 addition & 1 deletion addons/jr/jr_prep/script_component.hpp
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
#define SUBCOMPONENT prep
#include "\x\cba\addons\jr\script_component.hpp"
#include "..\script_component.hpp"
2 changes: 1 addition & 1 deletion addons/ui/flexiMenu/data/menu_arma2.hpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//#include "\x\cba\addons\ui\script_component.hpp"
//#include "..\..\script_component.hpp"

#define _DefaultAspectRatio 3 / 4
#define _SX (safeZoneX+safeZoneW / 2) // screen centre x
Expand Down
2 changes: 1 addition & 1 deletion addons/ui/flexiMenu/data/menu_buttonList.hpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//#include "\x\cba\addons\ui\script_component.hpp"
//#include "..\..\script_component.hpp"

#define _imagePath(TOKEN) QUOTE(PATHTOF(flexiMenu)\data\buttonList\TOKEN.paa)
#define _SX (safeZoneX + safeZoneW / 2) // screen centre x
Expand Down
2 changes: 1 addition & 1 deletion addons/ui/flexiMenu/data/menu_iconRow.hpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//#include "\x\cba\addons\ui\script_component.hpp"
//#include "..\..\script_component.hpp"

#define _imagePath(TOKEN) QUOTE(PATHTOF(flexiMenu)\data\arma2\TOKEN.paa)
#define _SX (safeZoneX + safeZoneW / 2) // screen centre x
Expand Down
2 changes: 1 addition & 1 deletion addons/ui/flexiMenu/data/menu_popup.hpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// #include "\x\cba\addons\ui\script_component.hpp"
// #include "..\..\script_component.hpp"

#define _imagePath(TOKEN) QUOTE(PATHTOF(flexiMenu)\data\popup\TOKEN.paa)
#define _SX (safeZoneX + safeZoneW / 2) //screen centre x
Expand Down
2 changes: 1 addition & 1 deletion addons/ui/flexiMenu/data/menu_rose.hpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
//#define DEBUG_MODE_FULL
//#include "\x\cba\addons\ui\script_component.hpp"
//#include "..\..\script_component.hpp"

#define _DefaultAspectRatio 3 / 4
#define _SX (safeZoneX + safeZoneW / 2) //screen centre x
Expand Down
2 changes: 1 addition & 1 deletion addons/ui/flexiMenu/fnc_add.sqf
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
//#define DEBUG_MODE_FULL
#include "\x\cba\addons\ui\script_component.hpp"
#include "..\script_component.hpp"

TRACE_1("",_this);

Expand Down
2 changes: 1 addition & 1 deletion addons/ui/flexiMenu/fnc_execute.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

// Perform menu action execution along with related menu behaviour changes.
//-----------------------------------------------------------------------------
#include "\x\cba\addons\ui\script_component.hpp"
#include "..\script_component.hpp"

private _arrayID = _this;
private _actionData = GVAR(menuActionData) select _arrayID;
Expand Down
2 changes: 1 addition & 1 deletion addons/ui/flexiMenu/fnc_getMenuDef.sqf
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// Desc: determine menuDef to use, based on variable param variations
//-----------------------------------------------------------------------------
//#define DEBUG_MODE_FULL
#include "\x\cba\addons\ui\script_component.hpp"
#include "..\script_component.hpp"

private _target = _this select 0;
private _menuSources = _this select 1; // [_target, _menuSources];
Expand Down
2 changes: 1 addition & 1 deletion addons/ui/flexiMenu/fnc_getMenuOption.sqf
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// Desc: parse and set menu option record values
// _this = [_menuDefs select 0, _menuDefs select 1 select N] (header & one menu def)
//-----------------------------------------------------------------------------
#include "\x\cba\addons\ui\script_component.hpp"
#include "..\script_component.hpp"
#include "DIKASCIIMap.hpp"

#define _flexiMenuSeparatorLine "<img image='\x\cba\addons\ui\flexiMenu\data\popup\separator.paa'/>" //<t size='1'> </t> <t underline='true'>a c</t>
Expand Down
2 changes: 1 addition & 1 deletion addons/ui/flexiMenu/fnc_keyDown.sqf
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
//#define DEBUG_MODE_FULL
#include "\x\cba\addons\ui\script_component.hpp"
#include "..\script_component.hpp"

#define _minObjDist(_var) (if (_var isKindOf "CAManBase") then {3} else {(2 max (1.4 + (sizeOf typeOf _var) / 2))}) // minimum object interaction distance: arbitrary distance. Might not work with very long/large vehicles. TODO: Find a very fast way to determine vehicle size.

Expand Down
2 changes: 1 addition & 1 deletion addons/ui/flexiMenu/fnc_keyUp.sqf
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#include "\x\cba\addons\ui\script_component.hpp"
#include "..\script_component.hpp"

params ["", "_dikCode", "_shift", "_ctrlKey", "_alt"];

Expand Down
2 changes: 1 addition & 1 deletion addons/ui/flexiMenu/fnc_list.sqf
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
disableSerialization;
// Desc: Fill and show an embedded listbox on dialog menu.
//-----------------------------------------------------------------------------
#include "\x\cba\addons\ui\script_component.hpp"
#include "..\script_component.hpp"

private _menuDefs = _this call FUNC(getMenuDef);
//-----------------------------------------------------------------------------
Expand Down
2 changes: 1 addition & 1 deletion addons/ui/flexiMenu/fnc_menu.sqf
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
disableSerialization;
//#define DEBUG_MODE_FULL
#include "\x\cba\addons\ui\script_component.hpp"
#include "..\script_component.hpp"
//-----------------------------------------------------------------------------
// TODO: Menu string parameter substitutions. Eg: _action="[%ID%] call func". Eg: %ID%,<ID>
// TODO: Consider adding: a base IDC override value.
Expand Down
2 changes: 1 addition & 1 deletion addons/ui/flexiMenu/fnc_menuShortcut.sqf
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// Desc: "keyDown" EH for menu dialog
//-----------------------------------------------------------------------------
#include "\x\cba\addons\ui\script_component.hpp"
#include "..\script_component.hpp"

if (isDedicated || !dialog) exitWith {};

Expand Down
2 changes: 1 addition & 1 deletion addons/ui/flexiMenu/fnc_mouseButtonDown.sqf
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#include "\x\cba\addons\ui\script_component.hpp"
#include "..\script_component.hpp"
#define _rightMouseButton 1

params ["_display", "_button", "_x", "_y", "_shiftKey", "_ctrlKey", "_altKey"];;
Expand Down
2 changes: 1 addition & 1 deletion addons/ui/flexiMenu/fnc_openMenuByDef.sqf
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#include "\x\cba\addons\ui\script_component.hpp"
#include "..\script_component.hpp"

#define _minObjDist(_var) (if (_var isKindOf "CAManBase") then {3} else {(2 max (1.4 + (sizeOf typeOf _var) / 2))}) // minimum object interaction distance: arbitrary distance. Might not work with very long/large vehicles. TODO: Find a very fast way to determine vehicle size.

Expand Down
2 changes: 1 addition & 1 deletion addons/ui/flexiMenu/fnc_remove.sqf
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
//#define DEBUG_MODE_FULL
#include "\x\cba\addons\ui\script_component.hpp"
#include "..\script_component.hpp"

// _this = ["player", [DIK_LSHIFT], -3, ["mission\weapon_menuDef.sqf", ["main"]]]

Expand Down
2 changes: 1 addition & 1 deletion addons/ui/flexiMenu/fnc_setObjectMenuSource.sqf
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#include "\x\cba\addons\ui\script_component.hpp"
#include "..\script_component.hpp"

// params: [_object, menuSource]
(_this select 0) setVariable [QGVAR(flexiMenu_source), _this select 1];
2 changes: 1 addition & 1 deletion addons/ui/flexiMenu/init.sqf
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#include "\x\cba\addons\ui\script_component.hpp"
#include "..\script_component.hpp"

if (isDedicated) exitWith {false};

Expand Down
3 changes: 2 additions & 1 deletion addons/xeh/xeh_a3/config.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#include "script_component.hpp"
#define SUBCOMPONENT a3
#include "..\script_component.hpp"

class CfgPatches {
class SUBADDON {
Expand Down
2 changes: 0 additions & 2 deletions addons/xeh/xeh_a3/script_component.hpp

This file was deleted.

2 changes: 1 addition & 1 deletion addons/xeh/xeh_contact/script_component.hpp
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
#define SUBCOMPONENT contact
#include "\x\cba\addons\xeh\script_component.hpp"
#include "..\script_component.hpp"
2 changes: 1 addition & 1 deletion addons/xeh/xeh_csla/script_component.hpp
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
#define SUBCOMPONENT csla
#include "\x\cba\addons\xeh\script_component.hpp"
#include "..\script_component.hpp"
2 changes: 1 addition & 1 deletion addons/xeh/xeh_sog/script_component.hpp
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
#define SUBCOMPONENT sog
#include "\x\cba\addons\xeh\script_component.hpp"
#include "..\script_component.hpp"
2 changes: 1 addition & 1 deletion addons/xeh/xeh_ws/script_component.hpp
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
#define SUBCOMPONENT ws
#include "\x\cba\addons\xeh\script_component.hpp"
#include "..\script_component.hpp"
2 changes: 1 addition & 1 deletion optionals/legacy_jr/legacy_jr_prep/script_component.hpp
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
#define SUBCOMPONENT prep
#include "\x\cba\addons\legacy_jr\script_component.hpp"
#include "..\script_component.hpp"

0 comments on commit ba78984

Please sign in to comment.