diff --git a/Dalamud.Boot/Dalamud.Boot.vcxproj b/Dalamud.Boot/Dalamud.Boot.vcxproj
index 53f4a7985..95eb9d12c 100644
--- a/Dalamud.Boot/Dalamud.Boot.vcxproj
+++ b/Dalamud.Boot/Dalamud.Boot.vcxproj
@@ -44,7 +44,7 @@
CPPDLLTEMPLATE_EXPORTS;_WINDOWS;_USRDLL;%(PreprocessorDefinitions)
- Console
+ Windows
true
false
dbghelp.lib;%(AdditionalDependencies)
@@ -103,4 +103,4 @@
-
\ No newline at end of file
+
diff --git a/Dalamud.Injector.Boot/Dalamud.Injector.Boot.vcxproj b/Dalamud.Injector.Boot/Dalamud.Injector.Boot.vcxproj
index 9470c83e0..b035ba848 100644
--- a/Dalamud.Injector.Boot/Dalamud.Injector.Boot.vcxproj
+++ b/Dalamud.Injector.Boot/Dalamud.Injector.Boot.vcxproj
@@ -45,7 +45,7 @@
CPPDLLTEMPLATE_EXPORTS;_WINDOWS;_USRDLL;%(PreprocessorDefinitions)
- Console
+ Windows
true
false
..\lib\CoreCLR;%(AdditionalLibraryDirectories)
@@ -110,4 +110,4 @@
-
\ No newline at end of file
+
diff --git a/Dalamud.Injector.Boot/main.cpp b/Dalamud.Injector.Boot/main.cpp
index f74504d6a..096d9fb33 100644
--- a/Dalamud.Injector.Boot/main.cpp
+++ b/Dalamud.Injector.Boot/main.cpp
@@ -2,15 +2,20 @@
#include
#include
+#include
#include "..\lib\CoreCLR\CoreCLR.h"
#include "..\lib\CoreCLR\boot.h"
-int wmain(int argc, char** argv)
+int wWinMain(_In_ HINSTANCE hInstance, _In_opt_ HINSTANCE hPrevInstance, _In_ LPWSTR lpCmdLine, _In_ int nShowCmd)
{
#ifndef NDEBUG
ConsoleSetup(L"Dalamud.Injector");
#endif
+ int argc = 0;
+ LPWSTR* argv = CommandLineToArgvW(GetCommandLineW(), &argc);
+ //ShowWindow(GetConsoleWindow(), SW_HIDE);
+
printf("Dalamud.Injector, (c) 2021 XIVLauncher Contributors\nBuilt at: %s@%s\n\n", __DATE__, __TIME__);
wchar_t _module_path[MAX_PATH];
@@ -34,7 +39,7 @@ int wmain(int argc, char** argv)
if (result != 0)
return result;
- typedef void (CORECLR_DELEGATE_CALLTYPE* custom_component_entry_point_fn)(int, char**);
+ typedef void (CORECLR_DELEGATE_CALLTYPE* custom_component_entry_point_fn)(int, wchar_t**);
custom_component_entry_point_fn entrypoint_fn = reinterpret_cast(entrypoint_vfn);
printf("Running Dalamud Injector... ");