diff --git a/.github/workflows/arma.yml b/.github/workflows/arma.yml index 9d6cae1a..c20248bc 100644 --- a/.github/workflows/arma.yml +++ b/.github/workflows/arma.yml @@ -33,19 +33,21 @@ jobs: continue-on-error: true # No failure due to many false-positives build: - runs-on: windows-2019 + runs-on: windows-2022 steps: - name: Checkout the source code uses: actions/checkout@master - name: Pull Arma3Tools run: | echo ${{ secrets.CR_PAT }} | docker login -u ${{ secrets.CR_USER }} --password-stdin ghcr.io - docker pull ghcr.io/armaforces/arma3tools:latest + docker pull ghcr.io/armaforces/arma3tools:v2 - name: Build using HEMTT run: | - docker run -v "$(pwd):c:/workdir" -e CI=$True ghcr.io/armaforces/arma3tools:latest hemtt build --release --ci --time + docker run -v "$(pwd):c:/workdir" -e CI=$True ghcr.io/armaforces/arma3tools:v2 hemtt release - uses: actions/upload-artifact@v2 with: name: armaforces_mods - path: releases/*.zip + path: | + releases/*.zip + !releases/afm-latest.zip diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 3b3c51be..e2555f7e 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -7,7 +7,7 @@ on: jobs: build_addon: - runs-on: windows-2019 + runs-on: windows-2022 steps: - name: Set VERSION env run: echo VERSION=${GITHUB_REF:11} >> $GITHUB_ENV diff --git a/.gitignore b/.gitignore index 470200e6..09df7b0f 100644 --- a/.gitignore +++ b/.gitignore @@ -1,6 +1,5 @@ # Build output -addons/*.pbo -keys/* +.hemttout/* # Releases releases/* diff --git a/.hemtt/hooks/post_release/set_version.rhai b/.hemtt/hooks/post_release/set_version.rhai new file mode 100644 index 00000000..537559e0 --- /dev/null +++ b/.hemtt/hooks/post_release/set_version.rhai @@ -0,0 +1,14 @@ + +let modCpp = HEMTT_OUTPUT + .join("mod.cpp") + .open_file() + .read() +; + +modCpp.replace("0.0.0", `${HEMTT_PROJECT_VERSION_MAJOR}.${HEMTT_PROJECT_VERSION_MINOR}.${HEMTT_PROJECT_VERSION_PATCH}`); + +HEMTT_OUTPUT + .join("mod.cpp") + .create_file() + .write(modCpp) +; diff --git a/.hemtt/project.toml b/.hemtt/project.toml new file mode 100644 index 00000000..e9ee3396 --- /dev/null +++ b/.hemtt/project.toml @@ -0,0 +1,74 @@ + +name = "ArmaForces Mods" +mainprefix = "z" +prefix = "afm" + +[files] +include = [ + "LICENSE", + "mod.cpp", + "README.md", + "armaforces_mods_x64.dll", +] + +exclude = ["*.psd", "*.png", "*.tga"] + +[properties] +author = "ArmaForces" + +[version] +path = "addons/main/script_version.hpp" + +[asc] +exclude = [ + "initSettings.sqf", + "initKeybinds.sqf", + "initSettingsChannelNames.sqf", +] + +[hemtt.launch] +workshop = [ + "450814997", # CBA_A3 + "2369477168", # ADT +] +parameters = [ + "-name=dev", + "-window", +] + +[hemtt.launch.ace] +workshop = [ + "450814997", # CBA_A3 + "2369477168", # ADT + "463939057", # ACE +] +parameters = [ + "-name=dev", + "-window", +] + +[hemtt.launch.vn] +workshop = [ + "450814997", # CBA_A3 + "2369477168", # ADT +] +parameters = [ + "-name=dev", + "-window", +] +dlc = [ + "S.O.G. Prairie Fire", +] + +[hemtt.launch.ww2] +workshop = [ + "450814997", # CBA_A3 + "2369477168", # ADT +] +parameters = [ + "-name=dev", + "-window", +] +dlc = [ + "Spearhead 1944", +] diff --git a/addons/acre/CfgEventHandlers.hpp b/addons/acre/CfgEventHandlers.hpp index e90bed41..2a3f71f8 100644 --- a/addons/acre/CfgEventHandlers.hpp +++ b/addons/acre/CfgEventHandlers.hpp @@ -1,15 +1,15 @@ class Extended_PreStart_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preStart)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preStart)); }; }; class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; class Extended_PostInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_postInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_postInit)); }; }; diff --git a/addons/ai_disembark/CfgEventHandlers.hpp b/addons/ai_disembark/CfgEventHandlers.hpp index e67698a1..f7236398 100644 --- a/addons/ai_disembark/CfgEventHandlers.hpp +++ b/addons/ai_disembark/CfgEventHandlers.hpp @@ -1,10 +1,10 @@ class Extended_PreStart_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preStart)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preStart)); }; }; class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; diff --git a/addons/back_to_game/CfgEventHandlers.hpp b/addons/back_to_game/CfgEventHandlers.hpp index e90bed41..2a3f71f8 100644 --- a/addons/back_to_game/CfgEventHandlers.hpp +++ b/addons/back_to_game/CfgEventHandlers.hpp @@ -1,15 +1,15 @@ class Extended_PreStart_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preStart)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preStart)); }; }; class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; class Extended_PostInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_postInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_postInit)); }; }; diff --git a/addons/common/CfgEventHandlers.hpp b/addons/common/CfgEventHandlers.hpp index e90bed41..2a3f71f8 100644 --- a/addons/common/CfgEventHandlers.hpp +++ b/addons/common/CfgEventHandlers.hpp @@ -1,15 +1,15 @@ class Extended_PreStart_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preStart)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preStart)); }; }; class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; class Extended_PostInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_postInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_postInit)); }; }; diff --git a/addons/common/ui/RscModal.hpp b/addons/common/ui/RscModal.hpp index 34e2c318..51583345 100644 --- a/addons/common/ui/RscModal.hpp +++ b/addons/common/ui/RscModal.hpp @@ -1,5 +1,3 @@ -#include "script_component.hpp" - class RscText; class RscTitle; class RscButtonMenuOK; diff --git a/addons/common/ui/script_component.hpp b/addons/common/ui/script_component.hpp deleted file mode 100644 index 4d18f2ae..00000000 --- a/addons/common/ui/script_component.hpp +++ /dev/null @@ -1 +0,0 @@ -#include "\z\afm\addons\common\script_component.hpp" \ No newline at end of file diff --git a/addons/curator/CfgEventHandlers.hpp b/addons/curator/CfgEventHandlers.hpp index e90bed41..2a3f71f8 100644 --- a/addons/curator/CfgEventHandlers.hpp +++ b/addons/curator/CfgEventHandlers.hpp @@ -1,15 +1,15 @@ class Extended_PreStart_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preStart)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preStart)); }; }; class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; class Extended_PostInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_postInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_postInit)); }; }; diff --git a/addons/debug/XEH_PREP.hpp b/addons/debug/XEH_PREP.hpp deleted file mode 100644 index e69de29b..00000000 diff --git a/addons/debug/XEH_preStart.sqf b/addons/debug/XEH_preStart.sqf deleted file mode 100644 index a51262a3..00000000 --- a/addons/debug/XEH_preStart.sqf +++ /dev/null @@ -1,2 +0,0 @@ -#include "script_component.hpp" -#include "XEH_PREP.hpp" diff --git a/addons/debug_console/CfgEventHandlers.hpp b/addons/debug_console/CfgEventHandlers.hpp index ef1c7ff6..10d970a7 100644 --- a/addons/debug_console/CfgEventHandlers.hpp +++ b/addons/debug_console/CfgEventHandlers.hpp @@ -1,16 +1,16 @@ class Extended_PreStart_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preStart)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preStart)); }; }; class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; class Extended_PostInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_postInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_postInit)); }; }; diff --git a/addons/extension/CfgEventHandlers.hpp b/addons/extension/CfgEventHandlers.hpp index e90bed41..2a3f71f8 100644 --- a/addons/extension/CfgEventHandlers.hpp +++ b/addons/extension/CfgEventHandlers.hpp @@ -1,15 +1,15 @@ class Extended_PreStart_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preStart)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preStart)); }; }; class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; class Extended_PostInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_postInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_postInit)); }; }; diff --git a/addons/extension_attendance/CfgEventHandlers.hpp b/addons/extension_attendance/CfgEventHandlers.hpp index e90bed41..2a3f71f8 100644 --- a/addons/extension_attendance/CfgEventHandlers.hpp +++ b/addons/extension_attendance/CfgEventHandlers.hpp @@ -1,15 +1,15 @@ class Extended_PreStart_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preStart)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preStart)); }; }; class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; class Extended_PostInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_postInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_postInit)); }; }; diff --git a/addons/extension_main_menu/CfgEventHandlers.hpp b/addons/extension_main_menu/CfgEventHandlers.hpp index eb28e311..59bb374e 100644 --- a/addons/extension_main_menu/CfgEventHandlers.hpp +++ b/addons/extension_main_menu/CfgEventHandlers.hpp @@ -1,23 +1,23 @@ class Extended_PreStart_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preStart)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preStart)); }; }; class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; class Extended_PostInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_postInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_postInit)); }; }; class Extended_DisplayLoad_EventHandlers { class RscDisplayMain { ADDON = QUOTE(with uiNamespace do {\ - [_this select 0] call COMPILE_FILE(XEH_mainDisplay);\ + [_this select 0] call COMPILE_SCRIPT(XEH_mainDisplay);\ }); }; }; diff --git a/addons/fatigue/CfgEventHandlers.hpp b/addons/fatigue/CfgEventHandlers.hpp index e90bed41..2a3f71f8 100644 --- a/addons/fatigue/CfgEventHandlers.hpp +++ b/addons/fatigue/CfgEventHandlers.hpp @@ -1,15 +1,15 @@ class Extended_PreStart_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preStart)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preStart)); }; }; class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; class Extended_PostInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_postInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_postInit)); }; }; diff --git a/addons/flags/CfgEventHandlers.hpp b/addons/flags/CfgEventHandlers.hpp index e90bed41..2a3f71f8 100644 --- a/addons/flags/CfgEventHandlers.hpp +++ b/addons/flags/CfgEventHandlers.hpp @@ -1,15 +1,15 @@ class Extended_PreStart_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preStart)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preStart)); }; }; class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; class Extended_PostInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_postInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_postInit)); }; }; diff --git a/addons/flags/FlagsVanilla.hpp b/addons/flags/FlagsVanilla.hpp index a1f9239e..6028d607 100644 --- a/addons/flags/FlagsVanilla.hpp +++ b/addons/flags/FlagsVanilla.hpp @@ -33,6 +33,6 @@ class GVAR(Russia): Flag_White_F { displayName = "Flag (Russia)"; class EventHandlers { - init = '(_this select 0) setFlagTexture "\A3\UI_F_Enoch\Data\CfgMarkers\Russia_CA.paa"'; + init = "(_this select 0) setFlagTexture '\A3\UI_F_Enoch\Data\CfgMarkers\Russia_CA.paa'"; }; }; diff --git a/addons/friendly_fire/CfgEventHandlers.hpp b/addons/friendly_fire/CfgEventHandlers.hpp index 917a0acb..a614deb1 100644 --- a/addons/friendly_fire/CfgEventHandlers.hpp +++ b/addons/friendly_fire/CfgEventHandlers.hpp @@ -1,10 +1,10 @@ class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; class Extended_PostInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_postInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_postInit)); }; }; diff --git a/addons/fries/CfgEventHandlers.hpp b/addons/fries/CfgEventHandlers.hpp index 917a0acb..a614deb1 100644 --- a/addons/fries/CfgEventHandlers.hpp +++ b/addons/fries/CfgEventHandlers.hpp @@ -1,10 +1,10 @@ class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; class Extended_PostInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_postInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_postInit)); }; }; diff --git a/addons/grass/CfgEventHandlers.hpp b/addons/grass/CfgEventHandlers.hpp index e90bed41..2a3f71f8 100644 --- a/addons/grass/CfgEventHandlers.hpp +++ b/addons/grass/CfgEventHandlers.hpp @@ -1,15 +1,15 @@ class Extended_PreStart_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preStart)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preStart)); }; }; class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; class Extended_PostInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_postInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_postInit)); }; }; diff --git a/addons/insurgents/CfgEventHandlers.hpp b/addons/insurgents/CfgEventHandlers.hpp index e67698a1..f7236398 100644 --- a/addons/insurgents/CfgEventHandlers.hpp +++ b/addons/insurgents/CfgEventHandlers.hpp @@ -1,10 +1,10 @@ class Extended_PreStart_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preStart)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preStart)); }; }; class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; diff --git a/addons/insurgents/CfgInsurgentGear.hpp b/addons/insurgents/CfgInsurgentGear.hpp index 8613d08d..0d67ebf7 100644 --- a/addons/insurgents/CfgInsurgentGear.hpp +++ b/addons/insurgents/CfgInsurgentGear.hpp @@ -118,7 +118,7 @@ class GVAR(gear) { "U_I_E_Uniform_01_tanktop_F", "U_C_Mechanic_01_F", "U_C_HunterBody_grn", - "U_C_Poor_1", + "U_C_Poor_1" }; vests[] = { "V_Chestrig_blk", diff --git a/addons/killtracker/CfgEventHandlers.hpp b/addons/killtracker/CfgEventHandlers.hpp index 197c7f4a..5762cd34 100644 --- a/addons/killtracker/CfgEventHandlers.hpp +++ b/addons/killtracker/CfgEventHandlers.hpp @@ -1,11 +1,11 @@ class Extended_PreStart_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preStart)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preStart)); }; }; class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; diff --git a/addons/loading/CfgEventHandlers.hpp b/addons/loading/CfgEventHandlers.hpp index fe9f0936..f7c92e06 100644 --- a/addons/loading/CfgEventHandlers.hpp +++ b/addons/loading/CfgEventHandlers.hpp @@ -3,6 +3,6 @@ class Extended_DisplayLoad_EventHandlers { // RscDisplayLoadMission // RscDisplayNotFreeze class RscDisplayLoading { - ADDON = QUOTE(with uiNamespace do {call COMPILE_FILE(XEH_loadingDisplay)}); + ADDON = QUOTE(with uiNamespace do {call COMPILE_SCRIPT(XEH_loadingDisplay)}); }; }; diff --git a/addons/main/script_debug.hpp b/addons/main/script_debug.hpp index ecb33997..cea601d3 100644 --- a/addons/main/script_debug.hpp +++ b/addons/main/script_debug.hpp @@ -19,7 +19,6 @@ #define PREP_RECOMPILE_END }; call _recomp; PREFIX##_RECOMPILES pushBack _recomp; PREP_RECOMPILE_ADD_BUTTON; #else #define LINKFUNC(x) FUNC(x) - #define PREP_RECOMPILE_ADD_BUTTON /* */ - #define PREP_RECOMPILE_START /* */ - #define PREP_RECOMPILE_END /* */ + #define PREP_RECOMPILE_START ; + #define PREP_RECOMPILE_END ; #endif diff --git a/addons/main_menu/CfgEventHandlers.hpp b/addons/main_menu/CfgEventHandlers.hpp index 3c513cb5..897f9e9f 100644 --- a/addons/main_menu/CfgEventHandlers.hpp +++ b/addons/main_menu/CfgEventHandlers.hpp @@ -1,28 +1,28 @@ class Extended_PreStart_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preStart)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preStart)); }; }; class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; class Extended_PostInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_postInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_postInit)); }; }; class Extended_DisplayLoad_EventHandlers { class RscDisplayRemoteMissions { ADDON = QUOTE(with uiNamespace do {\ - ARR_2([_this select 0, 'RscDisplayRemoteMissions']) call COMPILE_FILE(XEH_multiplayerDisplay);\ + ARR_2([_this select 0, 'RscDisplayRemoteMissions']) call COMPILE_SCRIPT(XEH_multiplayerDisplay);\ }); }; class RscDisplayMultiplayerSetup { ADDON = QUOTE(with uiNamespace do {\ - ARR_2([_this select 0, 'RscDisplayMultiplayerSetup']) call COMPILE_FILE(XEH_multiplayerDisplay);\ + ARR_2([_this select 0, 'RscDisplayMultiplayerSetup']) call COMPILE_SCRIPT(XEH_multiplayerDisplay);\ }); }; }; diff --git a/addons/map/CfgEventHandlers.hpp b/addons/map/CfgEventHandlers.hpp index 917a0acb..a614deb1 100644 --- a/addons/map/CfgEventHandlers.hpp +++ b/addons/map/CfgEventHandlers.hpp @@ -1,10 +1,10 @@ class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; class Extended_PostInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_postInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_postInit)); }; }; diff --git a/addons/nightvision/CfgEventHandlers.hpp b/addons/nightvision/CfgEventHandlers.hpp index e90bed41..2a3f71f8 100644 --- a/addons/nightvision/CfgEventHandlers.hpp +++ b/addons/nightvision/CfgEventHandlers.hpp @@ -1,15 +1,15 @@ class Extended_PreStart_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preStart)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preStart)); }; }; class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; class Extended_PostInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_postInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_postInit)); }; }; diff --git a/addons/pointing/CfgEventHandlers.hpp b/addons/pointing/CfgEventHandlers.hpp index e90bed41..2a3f71f8 100644 --- a/addons/pointing/CfgEventHandlers.hpp +++ b/addons/pointing/CfgEventHandlers.hpp @@ -1,15 +1,15 @@ class Extended_PreStart_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preStart)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preStart)); }; }; class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; class Extended_PostInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_postInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_postInit)); }; }; diff --git a/addons/remotesensors/CfgEventHandlers.hpp b/addons/remotesensors/CfgEventHandlers.hpp index b928bc2d..9b160c16 100644 --- a/addons/remotesensors/CfgEventHandlers.hpp +++ b/addons/remotesensors/CfgEventHandlers.hpp @@ -1,5 +1,5 @@ class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; diff --git a/addons/respawn/CfgEventHandlers.hpp b/addons/respawn/CfgEventHandlers.hpp index e90bed41..2a3f71f8 100644 --- a/addons/respawn/CfgEventHandlers.hpp +++ b/addons/respawn/CfgEventHandlers.hpp @@ -1,15 +1,15 @@ class Extended_PreStart_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preStart)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preStart)); }; }; class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; class Extended_PostInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_postInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_postInit)); }; }; diff --git a/addons/safestart/CfgEventHandlers.hpp b/addons/safestart/CfgEventHandlers.hpp index d3d0d195..e0e1b0a9 100644 --- a/addons/safestart/CfgEventHandlers.hpp +++ b/addons/safestart/CfgEventHandlers.hpp @@ -1,15 +1,15 @@ class Extended_PreStart_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preStart)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preStart)); }; }; class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; class Extended_PostInit_EventHandlers { class ADDON { - clientInit = QUOTE(call COMPILE_FILE(XEH_postInitClient)); + clientInit = QUOTE(call COMPILE_SCRIPT(XEH_postInitClient)); }; }; diff --git a/addons/spectator/CfgEventHandlers.hpp b/addons/spectator/CfgEventHandlers.hpp index 73e079be..93b4ee55 100644 --- a/addons/spectator/CfgEventHandlers.hpp +++ b/addons/spectator/CfgEventHandlers.hpp @@ -1,16 +1,16 @@ class Extended_PreStart_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preStart)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preStart)); }; }; class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; class Extended_PostInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_postInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_postInit)); }; }; diff --git a/addons/tagging/CfgEventHandlers.hpp b/addons/tagging/CfgEventHandlers.hpp index 917a0acb..a614deb1 100644 --- a/addons/tagging/CfgEventHandlers.hpp +++ b/addons/tagging/CfgEventHandlers.hpp @@ -1,10 +1,10 @@ class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; class Extended_PostInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_postInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_postInit)); }; }; diff --git a/addons/tanks/CfgEventHandlers.hpp b/addons/tanks/CfgEventHandlers.hpp index e67698a1..f7236398 100644 --- a/addons/tanks/CfgEventHandlers.hpp +++ b/addons/tanks/CfgEventHandlers.hpp @@ -1,10 +1,10 @@ class Extended_PreStart_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preStart)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preStart)); }; }; class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; diff --git a/addons/tasks/CfgEventHandlers.hpp b/addons/tasks/CfgEventHandlers.hpp index e90bed41..2a3f71f8 100644 --- a/addons/tasks/CfgEventHandlers.hpp +++ b/addons/tasks/CfgEventHandlers.hpp @@ -1,15 +1,15 @@ class Extended_PreStart_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preStart)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preStart)); }; }; class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; class Extended_PostInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_postInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_postInit)); }; }; diff --git a/addons/towing/CfgEventHandlers.hpp b/addons/towing/CfgEventHandlers.hpp index 917a0acb..a614deb1 100644 --- a/addons/towing/CfgEventHandlers.hpp +++ b/addons/towing/CfgEventHandlers.hpp @@ -1,10 +1,10 @@ class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_preInit)); }; }; class Extended_PostInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_postInit)); + init = QUOTE(call COMPILE_SCRIPT(XEH_postInit)); }; }; diff --git a/extension/src/missions.rs b/extension/src/missions.rs index 1c388ec0..b620d4fb 100644 --- a/extension/src/missions.rs +++ b/extension/src/missions.rs @@ -22,7 +22,7 @@ impl Mission { } pub fn get_missions() -> Result, String> { - match reqwest::blocking::get(&format!("{}/missions", *crate::MISSION_API)) + match reqwest::blocking::get(format!("{}/missions", *crate::MISSION_API)) .unwrap() .json::>() { @@ -32,7 +32,7 @@ pub fn get_missions() -> Result, String> { } pub fn get_current_mission() -> Result { - let resp = match reqwest::blocking::get(&format!("{}/currentMission", *crate::MISSION_API)) { + let resp = match reqwest::blocking::get(format!("{}/currentMission", *crate::MISSION_API)) { Ok(r) => r, Err(e) => return Err(e.to_string()), }; @@ -63,7 +63,7 @@ struct AttendanceResponse { pub fn post_attendance(mission_id: &str, steam_id: &u64) -> Result<(), String> { let resp = reqwest::blocking::Client::new() - .post(&format!("{}/attendances", *crate::ATTENDANCE_API)) + .post(format!("{}/attendances", *crate::ATTENDANCE_API)) .header("X-API-KEY", crate::ATTENDANCE_TOKEN.clone()) .json(&AttendanceBody { mission_id, diff --git a/extension/src/server.rs b/extension/src/server.rs index 6491238e..6dc42605 100644 --- a/extension/src/server.rs +++ b/extension/src/server.rs @@ -44,7 +44,7 @@ impl arma_rs::ToArma for ServerStatus { } pub fn get_status() -> Result { - let resp = match reqwest::blocking::get(&format!("{}/status", *crate::SERVER_API)) { + let resp = match reqwest::blocking::get(format!("{}/status", *crate::SERVER_API)) { Ok(r) => r, Err(e) => return Err(e.to_string()), }; diff --git a/hemtt.exe b/hemtt.exe deleted file mode 100644 index 98836fa1..00000000 Binary files a/hemtt.exe and /dev/null differ diff --git a/include/a3/ui_f/hpp/defineResincl.inc b/include/a3/ui_f/hpp/defineResincl.inc index ee8ddd5d..a7fb97b3 100644 --- a/include/a3/ui_f/hpp/defineResincl.inc +++ b/include/a3/ui_f/hpp/defineResincl.inc @@ -1540,8 +1540,8 @@ enum #define IDC_FRIENDS_GAME_INVITE_VOICE 114 #define IDC_FRIENDS_PLAY_MESSAGE 115 #define IDC_FRIENDS_MISSIONS 152 -#define IDC_MULTI_BATTLEYE_FILTER 154 -#define IDC_MULTI_EXPANSIONS_FILTER 155 +// #define IDC_MULTI_BATTLEYE_FILTER 154 +// #define IDC_MULTI_EXPANSIONS_FILTER 155 // Send voice mail dialog #define IDC_SVM_TITLE 101 @@ -1682,7 +1682,7 @@ enum #define IDC_MP_QUICK_MAX_PING 111 #define IDC_MP_QUICK_BEST_SERVER 112 #define IDC_MP_QUICK_FIND_SERVER 113 -#define IDC_MP_QUICK_SHOW_SERVERS 114 +// #define IDC_MP_QUICK_SHOW_SERVERS 114 #define IDC_MP_QUICK_SHOW_SERVERS 114 #define IDC_MP_QUICK_MODE_TITLE 115 #define IDC_MP_QUICK_MODE_PICTURE 116 @@ -3173,4 +3173,4 @@ enum #define HZ_TANK_BOTH_TRACKS 32 -#endif \ No newline at end of file +#endif diff --git a/include/a3/ui_f/hpp/defineResinclDesign.inc b/include/a3/ui_f/hpp/defineResinclDesign.inc index 0c669371..69d4a869 100644 --- a/include/a3/ui_f/hpp/defineResinclDesign.inc +++ b/include/a3/ui_f/hpp/defineResinclDesign.inc @@ -328,19 +328,19 @@ #define IDC_RSCDISPLAYRESPAWN_MAP 1050 //--- RscDisplaySelectIsland -#define IDC_RSCDISPLAYSELECTISLAND_TITLE 1000 -#define IDC_RSCDISPLAYSELECTISLAND_NAME 1002 -#define IDC_RSCDISPLAYSELECTISLAND_AUTHOR 1003 -#define IDC_RSCDISPLAYSELECTISLAND_NAMEBACKGROUND 1004 -#define IDC_RSCDISPLAYSELECTISLAND_ISLANDPANORAMA 1200 -#define IDC_RSCDISPLAYSELECTISLAND_INTERLACING 1201 -#define IDC_RSCDISPLAYSELECTISLAND_CLOUD1 1202 -#define IDC_RSCDISPLAYSELECTISLAND_CLOUD2 1203 -#define IDC_RSCDISPLAYSELECTISLAND_CLOUD3 1204 -#define IDC_RSCDISPLAYSELECTISLAND_CLOUD4 1205 -#define IDC_RSCDISPLAYSELECTISLAND_ISLANDGROUP 2300 -#define IDC_RSCDISPLAYSELECTISLAND_BUTTONCONTINUE 2600 -#define IDC_RSCDISPLAYSELECTISLAND_BUTTONCANCEL 2700 +// #define IDC_RSCDISPLAYSELECTISLAND_TITLE 1000 +// #define IDC_RSCDISPLAYSELECTISLAND_NAME 1002 +// #define IDC_RSCDISPLAYSELECTISLAND_AUTHOR 1003 +// #define IDC_RSCDISPLAYSELECTISLAND_NAMEBACKGROUND 1004 +// #define IDC_RSCDISPLAYSELECTISLAND_ISLANDPANORAMA 1200 +// #define IDC_RSCDISPLAYSELECTISLAND_INTERLACING 1201 +// #define IDC_RSCDISPLAYSELECTISLAND_CLOUD1 1202 +// #define IDC_RSCDISPLAYSELECTISLAND_CLOUD2 1203 +// #define IDC_RSCDISPLAYSELECTISLAND_CLOUD3 1204 +// #define IDC_RSCDISPLAYSELECTISLAND_CLOUD4 1205 +// #define IDC_RSCDISPLAYSELECTISLAND_ISLANDGROUP 2300 +// #define IDC_RSCDISPLAYSELECTISLAND_BUTTONCONTINUE 2600 +// #define IDC_RSCDISPLAYSELECTISLAND_BUTTONCANCEL 2700 //--- RscSpectator #define IDC_RSCSPECTATOR_PLAYERNAMEBACKGROUND 1000 diff --git a/include/x/cba/addons/main/script_macros_common.hpp b/include/x/cba/addons/main/script_macros_common.hpp index 41a4faea..be13021c 100644 --- a/include/x/cba/addons/main/script_macros_common.hpp +++ b/include/x/cba/addons/main/script_macros_common.hpp @@ -197,7 +197,7 @@ Macro: LOG() ------------------------------------------- */ #ifdef DEBUG_MODE_FULL -#define LOG(MESSAGE) LOG_SYS_FILELINENUMBERS('LOG',MESSAGE) +#define LOG(MESSAGE) LOG_SYS('LOG',MESSAGE) #define LOG_1(MESSAGE,ARG1) LOG(FORMAT_1(MESSAGE,ARG1)) #define LOG_2(MESSAGE,ARG1,ARG2) LOG(FORMAT_2(MESSAGE,ARG1,ARG2)) #define LOG_3(MESSAGE,ARG1,ARG2,ARG3) LOG(FORMAT_3(MESSAGE,ARG1,ARG2,ARG3)) @@ -265,7 +265,7 @@ Macro: WARNING() ------------------------------------------- */ #ifdef DEBUG_MODE_NORMAL -#define WARNING(MESSAGE) LOG_SYS_FILELINENUMBERS('WARNING',MESSAGE) +#define WARNING(MESSAGE) LOG_SYS('WARNING',MESSAGE) #define WARNING_1(MESSAGE,ARG1) WARNING(FORMAT_1(MESSAGE,ARG1)) #define WARNING_2(MESSAGE,ARG1,ARG2) WARNING(FORMAT_2(MESSAGE,ARG1,ARG2)) #define WARNING_3(MESSAGE,ARG1,ARG2,ARG3) WARNING(FORMAT_3(MESSAGE,ARG1,ARG2,ARG3)) @@ -304,7 +304,7 @@ Macro: ERROR() Author: Spooner ------------------------------------------- */ -#define ERROR(MESSAGE) LOG_SYS_FILELINENUMBERS('ERROR',MESSAGE) +#define ERROR(MESSAGE) LOG_SYS('ERROR',MESSAGE) #define ERROR_1(MESSAGE,ARG1) ERROR(FORMAT_1(MESSAGE,ARG1)) #define ERROR_2(MESSAGE,ARG1,ARG2) ERROR(FORMAT_2(MESSAGE,ARG1,ARG2)) #define ERROR_3(MESSAGE,ARG1,ARG2,ARG3) ERROR(FORMAT_3(MESSAGE,ARG1,ARG2,ARG3)) @@ -854,6 +854,8 @@ Macro: ISNILS() #define COMPILE_FILE2(var1) COMPILE_FILE2_SYS('var1') #define COMPILE_FILE2_CFG(var1) COMPILE_FILE2_CFG_SYS('var1') +#define COMPILE_SCRIPT(var1) compileScript ['PATHTO_SYS(PREFIX,COMPONENT_F,var1)'] + #define VERSIONING_SYS(var1) class CfgSettings \ { \ @@ -1812,9 +1814,9 @@ Macro: IS_ADMIN_LOGGED /* ------------------------------------------- Macro: FILE_EXISTS - Check if a file exists on machines with interface + Check if a file exists - Reports "false" if the file does not exist and throws an error in RPT. + Reports "false" if the file does not exist. Parameters: FILE - Path to the file @@ -1828,17 +1830,4 @@ Macro: FILE_EXISTS Author: commy2 ------------------------------------------- */ -#define FILE_EXISTS(FILE) (call {\ - private _return = false;\ - isNil {\ - private _control = (uiNamespace getVariable ["RscDisplayMain", displayNull]) ctrlCreate ["RscHTML", -1];\ - if (isNull _control) then {\ - _return = loadFile (FILE) != "";\ - } else {\ - _control htmlLoad (FILE);\ - _return = ctrlHTMLLoaded _control;\ - ctrlDelete _control;\ - };\ - };\ - _return\ -}) +#define FILE_EXISTS(FILE) (fileExists (FILE)) diff --git a/tools/Publish.ps1 b/tools/Publish.ps1 deleted file mode 100644 index b4d325a4..00000000 --- a/tools/Publish.ps1 +++ /dev/null @@ -1,30 +0,0 @@ -param ( - [string] $version, - [string] $workshopId, - [string] $addonDir -) - -if ($env:CI) {Write-Host "CI Detected! Skipping Steam Workshop upload";Exit} - -$choice = Read-Host -Prompt "Do you want to publish '$version' on Steam Workshop? (y/N)" -if ('y' -ne $choice.ToLower()) { - Write-Host "Skipping Steam Workshop upload" - Exit -} - -try { - $publisherPath = (Get-ItemProperty -Path Registry::"HKEY_CURRENT_USER\Software\Bohemia Interactive\publisher" -ErrorAction Stop).path -} catch { - Throw "Can't find Publisher path in registry" -} - -$modPath = $PSScriptRoot + "/../releases/$version/$addonDir" | Resolve-Path - -$publisherArguments = @( - "update", - "/id:$workshopId", - "/changeNote:""Automatic mod upload""", - "/path:""$modPath""" -) - -Start-Process -FilePath "$publisherPath\PublisherCmd.exe" -NoNewWindow -Wait -ArgumentList $publisherArguments diff --git a/tools/Set-Version.ps1 b/tools/Set-Version.ps1 deleted file mode 100644 index 6c71fcca..00000000 --- a/tools/Set-Version.ps1 +++ /dev/null @@ -1,10 +0,0 @@ -param ( - [string] $version, - [string] $addonDir -) - -$modCppPath = $PSScriptRoot + "/../releases/$version/$addonDir/mod.cpp" - -$replaced = (Get-Content $modCppPath) -replace "0.0.0", "$version" - -$replaced | Out-File $modCppPath