Index: Daodan/src/Daodan.c
===================================================================
--- Daodan/src/Daodan.c	(revision 987)
+++ Daodan/src/Daodan.c	(revision 990)
@@ -12,4 +12,5 @@
 #include "Daodan_Config.h"
 #include "patches/Patches.h"
+#include "bink-proxy.h"
 #include "_Version.h"
 
@@ -35,5 +36,12 @@
 	DDrConfig(argc, argv);
 
+	if(GetKeyState(VK_SHIFT) & 0x8000) {
+		DDrStartupMessage("Daodan: Shift");
+		guitest(DDrONiModule);
+	}
+
 	DD_Patch_Init();
+
+	BinkProxyInit();
 
 	ONiMain(argc, argv);
Index: Daodan/src/Daodan_Config.c
===================================================================
--- Daodan/src/Daodan_Config.c	(revision 987)
+++ Daodan/src/Daodan_Config.c	(revision 990)
@@ -62,5 +62,5 @@
 		if (!_stricmp(section, "options"))
 			ini_section = s_options;
-		else if (!_stricmp(section, "patch"))
+		else if (!_stricmp(section, "patch") || !_stricmp(section, "patches"))
 			ini_section = s_patch;
 		else if (!_stricmp(section, "bsl"))
Index: Daodan/src/Daodan_Patch.c
===================================================================
--- Daodan/src/Daodan_Patch.c	(revision 987)
+++ Daodan/src/Daodan_Patch.c	(revision 990)
@@ -168,4 +168,10 @@
 	DDrPatch_MakeJump(&trampoline[pos], (void*)disasm.EIP);
 	DDrPatch_NOOP(from, (void*)disasm.EIP - from);
+
+	DWORD oldp;
+	if (!VirtualProtect(trampoline, 40, PAGE_EXECUTE_READWRITE, &oldp)) {
+		DDrStartupMessage("Daodan: Detour: Could not mark page for trampoline as executable: from address 0x%08x", from);
+		return (void*)-1;
+	}
 	DDrPatch_MakeJump(from, to);
 /*
@@ -213,5 +219,6 @@
     DDrStartupMessage("");
     DDrStartupMessage("");
-     */
+*/
+
 	return trampoline;
 }
Index: Daodan/src/Oni_Symbols.h
===================================================================
--- Daodan/src/Oni_Symbols.h	(revision 987)
+++ Daodan/src/Oni_Symbols.h	(revision 990)
@@ -114,4 +114,6 @@
 // Oni's main method?
 DefFunc(void, ONiMain, __cdecl, (int ArgCount, char *ArgList[]), 0x004d3280);
+
+DefFunc(uint16_t, CLrGetCommandLine, ONICALL, (int inArgc, const char* inArgv[], char*** outArgV), 0x0043ffd0);
 
 // Initialization code, used to hook in windowed modes
Index: Daodan/src/_Version.h
===================================================================
--- Daodan/src/_Version.h	(revision 987)
+++ Daodan/src/_Version.h	(revision 990)
@@ -6,5 +6,5 @@
 
 #define DAODAN_VERSION_MAJOR 3
-#define DAODAN_VERSION_MINOR 6
+#define DAODAN_VERSION_MINOR 7
 #define DAODAN_VERSION_STRING STRINGIZE(DAODAN_VERSION_MAJOR) "." STRINGIZE(DAODAN_VERSION_MINOR)
 
Index: Daodan/src/bink-proxy.c
===================================================================
--- Daodan/src/bink-proxy.c	(revision 990)
+++ Daodan/src/bink-proxy.c	(revision 990)
@@ -0,0 +1,320 @@
+#include "bink-proxy.h"
+
+#include <windows.h>
+#include "Daodan_Utility.h"
+
+
+static HMODULE realbink = 0;
+
+typedef void (__stdcall *BINKBUFFERBLIT) (void* buf, void* rects, uint32_t numrects);
+typedef void (__stdcall *BINKBUFFERCLOSE) (void* buf);
+typedef int32_t (__stdcall *BINKBUFFERLOCK) (void* buf);
+typedef void* (__stdcall *BINKBUFFEROPEN) (void* wnd, uint32_t width, uint32_t height, uint32_t bufferflags);
+typedef int32_t (__stdcall *BINKBUFFERSETOFFSET) (void* buf, int32_t destx, int32_t desty);
+typedef int32_t (__stdcall *BINKBUFFERUNLOCK) (void* buf);
+typedef void (__stdcall *BINKCLOSE) (void* bnk);
+typedef int32_t (__stdcall *BINKCOPYTOBUFFER) (void* bnk, void* dest, int32_t destpitch, uint32_t destheight, uint32_t destx, uint32_t desty, uint32_t flags);
+typedef int32_t (__stdcall *BINKDOFRAME) (void* bnk);
+typedef int32_t (__stdcall *BINKGETRECTS) (void* bnk, uint32_t flags);
+typedef void (__stdcall *BINKNEXTFRAME) (void* bnk);
+typedef void* (__stdcall *BINKOPEN) (const char* name, uint32_t flags);
+typedef void* (__stdcall *BINKOPENDIRECTSOUND) (uint32_t param);
+typedef void (__stdcall *BINKSERVICE) (void* bink);
+typedef void (__stdcall *BINKSETIOSIZE) (uint32_t iosize);
+typedef int32_t (__stdcall *BINKSETSOUNDONOFF) (void* bnk, int32_t onoff);
+typedef int32_t (__stdcall *BINKSETSOUNDSYSTEM) (void* open, uint32_t param);
+typedef void (__stdcall *BINKSETVOLUME) (void* bnk, int32_t volume);
+typedef int32_t (__stdcall *BINKWAIT) (void* bnk);
+
+static BINKBUFFERBLIT BinkBufferBlit = 0;
+static BINKBUFFERCLOSE BinkBufferClose = 0;
+static BINKBUFFERLOCK BinkBufferLock = 0;
+static BINKBUFFEROPEN BinkBufferOpen = 0;
+static BINKBUFFERSETOFFSET BinkBufferSetOffset = 0;
+static BINKBUFFERUNLOCK BinkBufferUnlock = 0;
+static BINKCLOSE BinkClose = 0;
+static BINKCOPYTOBUFFER BinkCopyToBuffer = 0;
+static BINKDOFRAME BinkDoFrame = 0;
+static BINKGETRECTS BinkGetRects = 0;
+static BINKNEXTFRAME BinkNextFrame = 0;
+static BINKOPEN BinkOpen = 0;
+static BINKOPENDIRECTSOUND BinkOpenDirectSound = 0;
+static BINKSERVICE BinkService = 0;
+static BINKSETIOSIZE BinkSetIOSize = 0;
+static BINKSETSOUNDONOFF BinkSetSoundOnOff = 0;
+static BINKSETSOUNDSYSTEM BinkSetSoundSystem = 0;
+static BINKSETVOLUME BinkSetVolume = 0;
+static BINKWAIT BinkWait = 0;
+
+
+void __stdcall BinkProxyInit()
+{
+	if (GetFileAttributes("realbink.dll") != INVALID_FILE_ATTRIBUTES)
+	{
+		DWORD err;
+
+ 		DDrStartupMessage("Daodan: Loading real Bink DLL");
+		realbink = LoadLibrary("realbink.dll");
+		err = GetLastError();
+		if(realbink)
+		{
+
+			BinkBufferBlit = (BINKBUFFERBLIT)GetProcAddress(realbink, "_BinkBufferBlit@12");
+			if(!BinkBufferBlit)
+			{
+				DDrStartupMessage("Daodan: Retrieving function address from real Bink DLL failed for: BinkBufferBlit");
+				goto exit_err;
+			}
+			BinkBufferClose = (BINKBUFFERCLOSE)GetProcAddress(realbink, "_BinkBufferClose@4");
+			if(!BinkBufferClose)
+			{
+				DDrStartupMessage("Daodan: Retrieving function address from real Bink DLL failed for: BinkBufferClose");
+				goto exit_err;
+			}
+			BinkBufferLock = (BINKBUFFERLOCK)GetProcAddress(realbink, "_BinkBufferLock@4");
+			if(!BinkBufferLock)
+			{
+				DDrStartupMessage("Daodan: Retrieving function address from real Bink DLL failed for: BinkBufferLock");
+				goto exit_err;
+			}
+			BinkBufferOpen = (BINKBUFFEROPEN)GetProcAddress(realbink, "_BinkBufferOpen@16");
+			if(!BinkBufferOpen)
+			{
+				DDrStartupMessage("Daodan: Retrieving function address from real Bink DLL failed for: BinkBufferOpen");
+				goto exit_err;
+			}
+			BinkBufferSetOffset = (BINKBUFFERSETOFFSET)GetProcAddress(realbink, "_BinkBufferSetOffset@12");
+			if(!BinkBufferSetOffset)
+			{
+				DDrStartupMessage("Daodan: Retrieving function address from real Bink DLL failed for: BinkBufferSetOffset");
+				goto exit_err;
+			}
+			BinkBufferUnlock = (BINKBUFFERUNLOCK)GetProcAddress(realbink, "_BinkBufferUnlock@4");
+			if(!BinkBufferUnlock)
+			{
+				DDrStartupMessage("Daodan: Retrieving function address from real Bink DLL failed for: BinkBufferUnlock");
+				goto exit_err;
+			}
+			BinkClose = (BINKCLOSE)GetProcAddress(realbink, "_BinkClose@4");
+			if(!BinkClose)
+			{
+				DDrStartupMessage("Daodan: Retrieving function address from real Bink DLL failed for: BinkClose");
+				goto exit_err;
+			}
+			BinkCopyToBuffer = (BINKCOPYTOBUFFER)GetProcAddress(realbink, "_BinkCopyToBuffer@28");
+			if(!BinkCopyToBuffer)
+			{
+				DDrStartupMessage("Daodan: Retrieving function address from real Bink DLL failed for: BinkCopyToBuffer");
+				goto exit_err;
+			}
+			BinkDoFrame = (BINKDOFRAME)GetProcAddress(realbink, "_BinkDoFrame@4");
+			if(!BinkDoFrame)
+			{
+				DDrStartupMessage("Daodan: Retrieving function address from real Bink DLL failed for: BinkDoFrame");
+				goto exit_err;
+			}
+			BinkGetRects = (BINKGETRECTS)GetProcAddress(realbink, "_BinkGetRects@8");
+			if(!BinkGetRects)
+			{
+				DDrStartupMessage("Daodan: Retrieving function address from real Bink DLL failed for: BinkGetRects");
+				goto exit_err;
+			}
+			BinkNextFrame = (BINKNEXTFRAME)GetProcAddress(realbink, "_BinkNextFrame@4");
+			if(!BinkNextFrame)
+			{
+				DDrStartupMessage("Daodan: Retrieving function address from real Bink DLL failed for: BinkNextFrame");
+				goto exit_err;
+			}
+			BinkOpen = (BINKOPEN)GetProcAddress(realbink, "_BinkOpen@8");
+			if(!BinkOpen)
+			{
+				DDrStartupMessage("Daodan: Retrieving function address from real Bink DLL failed for: BinkOpen");
+				goto exit_err;
+			}
+			BinkOpenDirectSound = (BINKOPENDIRECTSOUND)GetProcAddress(realbink, "_BinkOpenDirectSound@4");
+			if(!BinkOpenDirectSound)
+			{
+				DDrStartupMessage("Daodan: Retrieving function address from real Bink DLL failed for: BinkOpenDirectSound");
+				goto exit_err;
+			}
+			BinkService = (BINKSERVICE)GetProcAddress(realbink, "_BinkService@4");
+			if(!BinkService)
+			{
+				DDrStartupMessage("Daodan: Retrieving function address from real Bink DLL failed for: BinkService");
+				goto exit_err;
+			}
+			BinkSetIOSize = (BINKSETIOSIZE)GetProcAddress(realbink, "_BinkSetIOSize@4");
+			if(!BinkSetIOSize)
+			{
+				DDrStartupMessage("Daodan: Retrieving function address from real Bink DLL failed for: BinkSetIOSize");
+				goto exit_err;
+			}
+			BinkSetSoundOnOff = (BINKSETSOUNDONOFF)GetProcAddress(realbink, "_BinkSetSoundOnOff@8");
+			if(!BinkSetSoundOnOff)
+			{
+				DDrStartupMessage("Daodan: Retrieving function address from real Bink DLL failed for: BinkSetSoundOnOff");
+				goto exit_err;
+			}
+			BinkSetSoundSystem = (BINKSETSOUNDSYSTEM)GetProcAddress(realbink, "_BinkSetSoundSystem@8");
+			if(!BinkSetSoundSystem)
+			{
+				DDrStartupMessage("Daodan: Retrieving function address from real Bink DLL failed for: BinkSetSoundSystem");
+				goto exit_err;
+			}
+			BinkSetVolume = (BINKSETVOLUME)GetProcAddress(realbink, "_BinkSetVolume@8");
+			if(!BinkSetVolume)
+			{
+				DDrStartupMessage("Daodan: Retrieving function address from real Bink DLL failed for: BinkSetVolume");
+				goto exit_err;
+			}
+			BinkWait = (BINKWAIT)GetProcAddress(realbink, "_BinkWait@4");
+			if(!BinkWait)
+			{
+				DDrStartupMessage("Daodan: Retrieving function address from real Bink DLL failed for: BinkWait");
+				goto exit_err;
+			}
+
+		} else {
+			char msg[100];
+			FormatMessage(FORMAT_MESSAGE_FROM_SYSTEM, NULL, err, 0, msg, 100, NULL);
+			DDrStartupMessage("Daodan: Loading real Bink DLL failed with error %i: %s", err, msg);
+		}
+	}
+
+	return;
+
+exit_err:
+	realbink = 0;
+	return;
+}
+
+
+
+
+void __stdcall _BinkBufferBlit(void* buf, void* rects, uint32_t numrects)
+{
+	if (realbink)
+		BinkBufferBlit(buf, rects, numrects);
+}
+
+void __stdcall _BinkBufferClose(void* buf)
+{
+	if (realbink)
+		BinkBufferClose(buf);
+}
+
+int32_t __stdcall _BinkBufferLock(void* buf)
+{
+	if (realbink)
+		return BinkBufferLock(buf);
+	return 0;
+}
+
+void* __stdcall _BinkBufferOpen(void* wnd, uint32_t width, uint32_t height, uint32_t bufferflags)
+{
+	if (realbink)
+		return BinkBufferOpen(wnd, width, height, bufferflags);
+	return 0;
+}
+
+int32_t __stdcall _BinkBufferSetOffset(void* buf, int32_t destx, int32_t desty)
+{
+	if (realbink)
+		return BinkBufferSetOffset(buf, destx, desty);
+	return 0;
+}
+
+int32_t __stdcall _BinkBufferUnlock(void* buf)
+{
+	if (realbink)
+		return BinkBufferUnlock(buf);
+	return 0;
+}
+
+void __stdcall _BinkClose(void* bnk)
+{
+	if (realbink)
+		BinkClose(bnk);
+}
+
+int32_t __stdcall _BinkCopyToBuffer(void* bnk, void* dest, int32_t destpitch, uint32_t destheight, uint32_t destx, uint32_t desty, uint32_t flags)
+{
+	if (realbink)
+		return BinkCopyToBuffer(bnk, dest, destpitch, destheight, destx, desty, flags);
+	return 0;
+}
+
+int32_t __stdcall _BinkDoFrame(void* bnk)
+{
+	if (realbink)
+		return BinkDoFrame(bnk);
+	return 0;
+}
+
+int32_t __stdcall _BinkGetRects(void* bnk, uint32_t flags)
+{
+	if (realbink)
+		return BinkGetRects(bnk, flags);
+	return 0;
+}
+
+void __stdcall _BinkNextFrame(void* bnk)
+{
+	if (realbink)
+		BinkNextFrame(bnk);
+}
+
+void* __stdcall _BinkOpen(const char* name, uint32_t flags)
+{
+	if (realbink)
+		return BinkOpen(name, flags);
+	return 0;
+}
+
+void* __stdcall _BinkOpenDirectSound(uint32_t param)
+{
+	if (realbink)
+		return BinkOpenDirectSound(param);
+	return 0;
+}
+
+void __stdcall _BinkService(void* bink)
+{
+	if (realbink)
+		BinkService(bink);
+}
+
+void __stdcall _BinkSetIOSize(uint32_t iosize)
+{
+	if (realbink)
+		BinkSetIOSize(iosize);
+}
+
+int32_t __stdcall _BinkSetSoundOnOff(void* bnk, int32_t onoff)
+{
+	if (realbink)
+		return BinkSetSoundOnOff(bnk, onoff);
+	return 0;
+}
+
+int32_t __stdcall _BinkSetSoundSystem(void* open, uint32_t param)
+{
+	if (realbink)
+		return BinkSetSoundSystem(open, param);
+	return 0;
+}
+
+void __stdcall _BinkSetVolume(void* bnk, int32_t volume)
+{
+	if (realbink)
+		BinkSetVolume(bnk, volume);
+}
+
+int32_t __stdcall _BinkWait(void* bnk)
+{
+	if (realbink)
+		return BinkWait(bnk);
+	return 0;
+}
+
+
Index: Daodan/src/bink-proxy.h
===================================================================
--- Daodan/src/bink-proxy.h	(revision 990)
+++ Daodan/src/bink-proxy.h	(revision 990)
@@ -0,0 +1,29 @@
+#ifndef _BINK_PROXY_H_
+#define _BINK_PROXY_H_
+
+#include "stdint.h"
+
+void __stdcall BinkProxyInit();
+
+void __stdcall _BinkBufferBlit(void* buf, void* rects, uint32_t numrects);
+void __stdcall _BinkBufferClose(void* buf);
+int32_t __stdcall _BinkBufferLock(void* buf);
+void* __stdcall _BinkBufferOpen(void* wnd, uint32_t width, uint32_t height, uint32_t bufferflags);
+int32_t __stdcall _BinkBufferSetOffset(void* buf, int32_t destx, int32_t desty);
+int32_t __stdcall _BinkBufferUnlock(void* buf);
+void __stdcall _BinkClose(void* bnk);
+int32_t  __stdcall _BinkCopyToBuffer(void* bnk, void* dest, int32_t destpitch, uint32_t destheight, uint32_t destx, uint32_t desty, uint32_t flags);
+int32_t  __stdcall _BinkDoFrame(void* bnk);
+int32_t  __stdcall _BinkGetRects(void* bnk, uint32_t flags);
+void __stdcall _BinkNextFrame(void* bnk);
+void* __stdcall _BinkOpen(const char* name, uint32_t flags);
+void* __stdcall _BinkOpenDirectSound(uint32_t param);
+void __stdcall _BinkService(void* bink);
+void __stdcall _BinkSetIOSize(uint32_t iosize);
+int32_t  __stdcall _BinkSetSoundOnOff(void* bnk, int32_t onoff);
+int32_t  __stdcall _BinkSetSoundSystem(void* open, uint32_t param);
+void __stdcall _BinkSetVolume(void* bnk, int32_t volume);
+int32_t  __stdcall _BinkWait(void* bnk);
+
+
+#endif
Index: Daodan/src/binkw32.def
===================================================================
--- Daodan/src/binkw32.def	(revision 987)
+++ Daodan/src/binkw32.def	(revision 990)
@@ -2,88 +2,22 @@
 
 EXPORTS
+	_BinkBufferBlit@12	@1
+	_BinkBufferClose@4	@4
+	_BinkBufferLock@4	@7
+	_BinkBufferOpen@16	@8
+	_BinkBufferSetOffset@12	@11
+	_BinkBufferUnlock@4	@14
+	_BinkClose@4	@16
+	_BinkCopyToBuffer@28	@18
+	_BinkDoFrame@4	@20
+	_BinkGetRects@8	@24
+	_BinkNextFrame@4	@33
+	_BinkOpen@8	@34
+	_BinkOpenDirectSound@4	@35
+	_BinkService@4	@41
+	_BinkSetIOSize@4	@45
+	_BinkSetSoundOnOff@8	@48
+	_BinkSetSoundSystem@8	@49
+	_BinkSetVolume@8	@52
+	_BinkWait@4	@53
 
-        _BinkBufferBlit@12          = REALBINK._BinkBufferBlit@12          @1
-	_BinkBufferCheckWinPos@12   = REALBINK._BinkBufferCheckWinPos@12   @2
-	_BinkBufferClear@8          = REALBINK._BinkBufferClear@8          @3
-	_BinkBufferClose@4          = REALBINK._BinkBufferClose@4          @4
-	_BinkBufferGetDescription@4 = REALBINK._BinkBufferGetDescription@4 @5
-	_BinkBufferGetError@0       = REALBINK._BinkBufferGetError@0       @6
-	_BinkBufferLock@4           = REALBINK._BinkBufferLock@4           @7
-	_BinkBufferOpen@16          = REALBINK._BinkBufferOpen@16          @8
-	_BinkBufferSetDirectDraw@8  = REALBINK._BinkBufferSetDirectDraw@8  @9
-	_BinkBufferSetHWND@8        = REALBINK._BinkBufferSetHWND@8        @10
-	_BinkBufferSetOffset@12     = REALBINK._BinkBufferSetOffset@12     @11
-	_BinkBufferSetResolution@12 = REALBINK._BinkBufferSetResolution@12 @12
-	_BinkBufferSetScale@12      = REALBINK._BinkBufferSetScale@12      @13
-	_BinkBufferUnlock@4         = REALBINK._BinkBufferUnlock@4         @14
-	_BinkCheckCursor@20         = REALBINK._BinkCheckCursor@20         @15
-	_BinkClose@4                = REALBINK._BinkClose@4                @16
-	_BinkCloseTrack@4           = REALBINK._BinkCloseTrack@4           @17
-	_BinkCopyToBuffer@28        = REALBINK._BinkCopyToBuffer@28        @18
-	_BinkDDSurfaceType@4        = REALBINK._BinkDDSurfaceType@4        @19
-	_BinkDoFrame@4              = REALBINK._BinkDoFrame@4              @20
-	_BinkGetError@0             = REALBINK._BinkGetError@0             @21
-	_BinkGetKeyFrame@12         = REALBINK._BinkGetKeyFrame@12         @22
-	_BinkGetRealtime@12         = REALBINK._BinkGetRealtime@12         @23
-	_BinkGetRects@8             = REALBINK._BinkGetRects@8             @24
-	_BinkGetSummary@8           = REALBINK._BinkGetSummary@8           @25
-	_BinkGetTrackData@8         = REALBINK._BinkGetTrackData@8         @26
-	_BinkGetTrackID@8           = REALBINK._BinkGetTrackID@8           @27
-	_BinkGetTrackMaxSize@8      = REALBINK._BinkGetTrackMaxSize@8      @28
-	_BinkGetTrackType@8         = REALBINK._BinkGetTrackType@8         @29
-	_BinkGoto@12                = REALBINK._BinkGoto@12                @30
-	_BinkIsSoftwareCursor@8     = REALBINK._BinkIsSoftwareCursor@8     @31
-	_BinkLogoAddress@0          = REALBINK._BinkLogoAddress@0          @32
-	_BinkNextFrame@4            = REALBINK._BinkNextFrame@4            @33
-	_BinkOpen@8                 = REALBINK._BinkOpen@8                 @34
-	_BinkOpenDirectSound@4      = REALBINK._BinkOpenDirectSound@4      @35
-	_BinkOpenMiles@4            = REALBINK._BinkOpenMiles@4            @36
-	_BinkOpenTrack@8            = REALBINK._BinkOpenTrack@8            @37
-	_BinkOpenWaveOut@4          = REALBINK._BinkOpenWaveOut@4          @38
-	_BinkPause@8                = REALBINK._BinkPause@8                @39
-	_BinkRestoreCursor@4        = REALBINK._BinkRestoreCursor@4        @40
-	_BinkService@4              = REALBINK._BinkService@4              @41
-	_BinkSetError@4             = REALBINK._BinkSetError@4             @42
-	_BinkSetFrameRate@8         = REALBINK._BinkSetFrameRate@8         @43
-	_BinkSetIO@4                = REALBINK._BinkSetIO@4                @44
-	_BinkSetIOSize@4            = REALBINK._BinkSetIOSize@4            @45
-	_BinkSetPan@8               = REALBINK._BinkSetPan@8               @46
-	_BinkSetSimulate@4          = REALBINK._BinkSetSimulate@4          @47
-	_BinkSetSoundOnOff@8        = REALBINK._BinkSetSoundOnOff@8        @48
-	_BinkSetSoundSystem@8       = REALBINK._BinkSetSoundSystem@8       @49
-	_BinkSetSoundTrack@4        = REALBINK._BinkSetSoundTrack@4        @50
-	_BinkSetVideoOnOff@8        = REALBINK._BinkSetVideoOnOff@8        @51
-	_BinkSetVolume@8            = REALBINK._BinkSetVolume@8            @52
-	_BinkWait@4                 = REALBINK._BinkWait@4                 @53
-	_ExpandBink@56              = REALBINK._ExpandBink@56              @54
-	_ExpandBundleSizes@8        = REALBINK._ExpandBundleSizes@8        @55
-	_RADSetMemory@8             = REALBINK._RADSetMemory@8             @56
-	_RADTimerRead@0             = REALBINK._RADTimerRead@0             @57
-	_YUV_blit_16a1bpp@52        = REALBINK._YUV_blit_16a1bpp@52        @58
-	_YUV_blit_16a1bpp_mask@52   = REALBINK._YUV_blit_16a1bpp_mask@52   @59
-	_YUV_blit_16a4bpp@52        = REALBINK._YUV_blit_16a4bpp@52        @60
-	_YUV_blit_16a4bpp_mask@52   = REALBINK._YUV_blit_16a4bpp_mask@52   @61
-	_YUV_blit_16bpp@48          = REALBINK._YUV_blit_16bpp@48          @62
-	_YUV_blit_16bpp_mask@48     = REALBINK._YUV_blit_16bpp_mask@48     @63
-	_YUV_blit_24bpp@48          = REALBINK._YUV_blit_24bpp@48          @64
-	_YUV_blit_24bpp_mask@48     = REALBINK._YUV_blit_24bpp_mask@48     @65
-	_YUV_blit_24rbpp@48         = REALBINK._YUV_blit_24rbpp@48         @66
-	_YUV_blit_24rbpp_mask@48    = REALBINK._YUV_blit_24rbpp_mask@48    @67
-	_YUV_blit_32abpp@52         = REALBINK._YUV_blit_32abpp@52         @68
-	_YUV_blit_32abpp_mask@52    = REALBINK._YUV_blit_32abpp_mask@52    @69
-	_YUV_blit_32bpp@48          = REALBINK._YUV_blit_32bpp@48          @70
-	_YUV_blit_32bpp_mask@48     = REALBINK._YUV_blit_32bpp_mask@48     @71
-	_YUV_blit_32rabpp@52        = REALBINK._YUV_blit_32rabpp@52        @72
-	_YUV_blit_32rabpp_mask@52   = REALBINK._YUV_blit_32rabpp_mask@52   @73
-	_YUV_blit_32rbpp@48         = REALBINK._YUV_blit_32rbpp@48         @74
-	_YUV_blit_32rbpp_mask@48    = REALBINK._YUV_blit_32rbpp_mask@48    @75
-	_YUV_blit_UYVY@48           = REALBINK._YUV_blit_UYVY@48           @76
-	_YUV_blit_UYVY_mask@48      = REALBINK._YUV_blit_UYVY_mask@48      @77
-	_YUV_blit_YUY2@48           = REALBINK._YUV_blit_YUY2@48           @78
-	_YUV_blit_YUY2_mask@48      = REALBINK._YUV_blit_YUY2_mask@48      @79
-	_YUV_blit_YV12@52           = REALBINK._YUV_blit_YV12@52           @80
-	_YUV_init@4                 = REALBINK._YUV_init@4                 @81
-	_radfree@4                  = REALBINK._radfree@4                  @82
-	_radmalloc@4                = REALBINK._radmalloc@4                @83
-
-
Index: Daodan/src/guitest.c
===================================================================
--- Daodan/src/guitest.c	(revision 990)
+++ Daodan/src/guitest.c	(revision 990)
@@ -0,0 +1,47 @@
+#include <windows.h>
+
+LRESULT CALLBACK WndProc(HWND, UINT, WPARAM, LPARAM);
+
+guitest(HMODULE hInstance, int nCmdShow)
+{
+	MSG  msg;    
+	HWND hwnd;
+	WNDCLASSW wc;
+
+	wc.style         = CS_HREDRAW | CS_VREDRAW;
+	wc.cbClsExtra    = 0;
+	wc.cbWndExtra    = 0;
+	wc.lpszClassName = L"Window";
+	wc.hInstance     = hInstance;
+	wc.hbrBackground = GetSysColorBrush(COLOR_3DFACE);
+	wc.lpszMenuName  = NULL;
+	wc.lpfnWndProc   = WndProc;
+	wc.hCursor       = LoadCursor(NULL, IDC_ARROW);
+	wc.hIcon         = LoadIcon(NULL, IDI_APPLICATION);
+
+	RegisterClassW(&wc);
+	hwnd = CreateWindowW( wc.lpszClassName, L"Window",
+		WS_OVERLAPPEDWINDOW | WS_VISIBLE,
+		100, 100, 350, 250, NULL, NULL, hInstance, NULL);  
+
+	ShowWindow(hwnd, nCmdShow);
+	UpdateWindow(hwnd);
+
+	while( GetMessage(&msg, NULL, 0, 0)) {
+		DispatchMessage(&msg);
+	}
+
+	return (int) msg.wParam;
+}
+
+LRESULT CALLBACK WndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
+{
+	switch(msg)
+	{
+		case WM_DESTROY:
+			PostQuitMessage(0);
+			return 0;      
+	}
+
+	return DefWindowProcW(hwnd, msg, wParam, lParam);
+}
Index: Daodan/src/patches/Patches.c
===================================================================
--- Daodan/src/patches/Patches.c	(revision 987)
+++ Daodan/src/patches/Patches.c	(revision 990)
@@ -350,5 +350,8 @@
 void DD_Patch_DisableCmdLine()
 {
-	DDrPatch_Int32 ((int*)(OniExe + 0x000d3570), 0xc3c03366);
+	// Replace start of OniParseCommandLine with XOR ax,ax; RET
+//	DDrPatch_Int32 ((int*)(OniExe + 0x000d3570), 0xc3c03366);
+	// Replace start of OniParseCommandLine with XOR eax,eax; RET
+	DDrPatch_Int32 ((int*)(OniExe + 0x000d3570), 0x00c3c033);
 }
 
