--- Daodan/src/Daodan.c 2009/03/18 07:48:30 276 +++ Daodan/src/Daodan.c 2009/04/17 13:31:04 297 @@ -5,6 +5,9 @@ #include "Oni.h" #include "BFW_Utility.h" +#include "oni_gl.h" +#include "daodan_gl.h" + HMODULE DDrDLLModule; HMODULE DDrONiModule; @@ -41,6 +44,9 @@ bool DDrPatch_Init() // Sets the fadetime to 4800 by default DDrPatch_Int16 (OniExe + 0x0011ab0e, 0x12c0); + // Patch for alt-tab and the start menu + DDrPatch_Byte (OniExe + 0x00026010, 0xC3); + // Hackish fix for Konoko not kicking guns // const char kickgun_patch[] = { 0x00, 0x05, 0x00, 0x00, 0x00, 0xC7, 0x05, 0x1C, 0xC9, 0x5E, 0x00, 0x70, 0xB8, 0x43, 0x00, 0xC7, 0x05, 0x20, 0xC9, 0x5E, 0x00, 0x20, 0xBE, 0x43 }; // DDrPatch_Const (OniExe + 0x000dc420, kickgun_patch); @@ -62,7 +68,10 @@ void __cdecl DDrMain(int argc, char* arg // Safe startup message printer DDrPatch_MakeJump(UUrStartupMessage, DDrStartupMessage); - // Test performance patch + // Daodan device mode enumeration function + DDrPatch_MakeJump(gl_enumerate_valid_display_modes, daodan_enumerate_valid_display_modes); + + // Performance patch DDrPatch_MakeJump(UUrMachineTime_High, DDrMachineTime_High); DDrPatch_MakeJump(UUrMachineTime_High_Frequency, DDrMachineTime_High_Frequency); DDrPatch_MakeJump(UUrMachineTime_Sixtieths, DDrMachineTime_Sixtieths);