source: Daodan/MSVC/Oni_Symbols.c@ 748

Last change on this file since 748 was 579, checked in by gumby, 14 years ago

Finally back up to pre data loss standards

File size: 9.0 KB
RevLine 
[567]1/*;symbol(name, value) .global name; .set name, 0x00400000 + value
2symbol macro name, value
3.global name
4mov name, value
5endm
6
7;MSVC6.0 stdlib
8DefVar( , _oni_malloc , 0x0051fc24 )
9DefVar( , _oni_free , 0x0051fbf5 )
10
11DefVar( , _oni_fopen , 0x0051ea9f )
12DefVar( , _oni_fflush , 0x0051eab2 )
13DefVar( , _oni_fprintf , 0x0051ebbf )
14DefVar( , _oni_vsprintf , 0x0051e860 )
15
16;Oni Engine
17DefVar( , _ONiMain , 0x004d3280 )
18symbol ( @ONrPlatform_Initialize@4 , 0x0050f670 )
19DefVar( , _ONrPlatform_WindowProc@16 , 0x0050f7a0 )
20symbol ( @ONrCheater@4 , 0x004f5c30 )
21
22DefVar( , _g_Instance , 0x0021f9e4 )
23DefVar( , _ONgPlatformData , 0x0023100c )
24DefVar( , _ONgGameState , 0x005ece7c )
25DefVar( , _ai2_deaf , 0x005ec0c1 )
26DefVar( , _AKgDebug_DebugMaps , 0x002b2204 )
27DefVar( , _BFgDebugFileEnable , 0x0055c8d0 )
28DefVar( , _SSgSearchOnDisk , 0x005eb758 )
29
30DefVar( , _opt_sound , 0x002370fc )
31DefVar( , _opt_ignore_private_data , 0x002370f0 )
32
33;Oni Persistance
34symbol ( @ONrPersist_GetGamma@0 , 0x0050f450 )
35symbol ( @ONrPersist_GetWonGame@0 , 0x0050f660 )
36
37;BFW_Utility
38DefVar( , _UUrStartupMessage , 0x00424860 )
39symbol ( @UUrMachineTime_High@0 , 0x00426480 )
40symbol ( @UUrMachineTime_High_Frequency@0 , 0x004264b0 )
41symbol ( @UUrMachineTime_Sixtieths@0 , 0x004263e0 )
42symbol ( @UUrPlatform_Initialize@0 , 0x00426010 )
43symbol ( @UUrPlatform_Terminate@0 , 0x00426310 )
44DefVar( , _AUrMessageBox , 0x004378c0 )
45
46DefVar( , _ONgFileStartup , 0x005711b8 )
47
48LMotoko
49
50DefVar( , _M3gResolutionSwitch , 0x00531634 )
51
52L OpenGL
53symbol ( @gl_enumerate_valid_display_modes@4 , 0x004083a0 )
54symbol ( @gl_platform_set_pixel_format@4 , 0x00407b50 )
55symbol ( @gl_platform_initialize@0 , 0x00407da0 )
56
57
58
59; Character
60symbol ( @ONrGameState_NewCharacter@16 , 0x004dac50 )
61symbol ( @ONrGameState_GetPlayerCharacter@0 , 0x004b63a7 )
62symbol ( @ONrGetActiveCharacter@4 , 0x004f1180 )
63
64; Console
65symbol ( @TSrContext_DrawText@20 , 0x0042DF00 )
66symbol ( @TSrContext_New@24 , 0x0042EA30 )
67symbol ( @TMrInstance_GetDataPtr@12 , 0x004232E0 )
68symbol ( @TMrInstance_GetInstanceName@4 , 0x00423D90 )
69symbol ( @COrTextArea_Print@28 , 0x00431340 )
70
71DefVar( , _COgConsoleLines , 0x005cb468 )
72DefVar( , _COgFadeTimeValue , 0x00533f68 )
73DefVar( , _COgDefaultTextShade , 0x00533f70 )
74DefVar( , _COgDefaultTextShadow , 0x00533f74 )
75
76DefVar( , _TStColorFormattingCharacter , 0x00533DA0 )
77
78symbol ( @COrMessage_Print@12 , 0x004304B0 )
79symbol ( @COrMessage_Remove@4 , 0x00430640 )
80
81; ScriptingLanguage
82;symbol ( @SLrScript_Command_Register_ReturnType@20 , 0x00477b20 )
83;symbol ( @SLrScript_Command_Register_Void@16 , 0x00477b40 )
84;symbol ( @SLrGlobalVariable_Register_Int32@12 , 0x00477e30 )
85;symbol ( @SLrGlobalVariable_Register_Float@12 , 0x00477ec0 )
86;symbol ( @SLrGlobalVariable_Register_String@12 , 0x00477fe0 )
87
88; Messages
89symbol ( @SSrMessage_Find@4 , 0x0047F550 )
90symbol ( @ONiGameState_FindAutoPromptMessage@8 , 0x004FDBE0 )
91
92; Data
93symbol ( @TMrInstance_GetDataPtr_List@16 , 0x00423540 )
94*/
95#include "Daodan.h"
96#include "Oni.h"
97
98//////////////////////////////////////////////////////////////////////
99//Functions need:
100//In Oni_Symbols.c
101//1. DefFunc( name, address )
102//In Oni_Symbols.h
103//1. typedef return_type ( [calling_convention] *_name)( arguments );
104//2. ExtFunc( name )
105//////////////////////////////////////////////////////////////////////
106//Variables need:
107//In Oni_Symbols.c
108//1. DefVar( type, name, address );
109//In Oni_Symbols.h
110//1. DefVar( type, name, address <ignored> );
111//2. #define name *(_name)
112//Please do not use variable names that could be parts of other
113//names like "gl". That will screw things up. If you insist on doing
114//this, omit the #define step and dereference them yourself.
115//////////////////////////////////////////////////////////////////////
116//Please keep everything alphabatized. Kthanxbai
117//////////////////////////////////////////////////////////////////////
118
119#define DefFunc(name, address) _##name name = (_##name)address
120DefFunc( gl_enumerate_valid_display_modes , 0x004083a0 );
121DefFunc( gl_platform_set_pixel_format , 0x00407b50 );
122DefFunc( gl_platform_initialize , 0x00407da0 );
123
124DefFunc( oni_fopen , 0x0051ea9f );
125DefFunc( oni_fflush , 0x0051eab2 );
126DefFunc( oni_fprintf , 0x0051ebbf );
127
[573]128
129DefFunc( AI2iScript_Spawn , 0x004B4780 );
[567]130DefFunc( AUrMessageBox , 0x004378c0 );
131
132DefFunc( COrMessage_Print , 0x004304B0 );
133DefFunc( COrTextArea_Print , 0x00431340 );
[574]134//DefFunc( COrConsole_StatusLine_Display , 0x00431E70 );
[573]135
136DefFunc( OBJrObjectType_EnumerateObjects , 0x004D0080 );
137//DefFunc( OBJiObjectGroup_GetNumObjects ,
138
[574]139//DefFunc( ONiGameState_FindAutoPromptMessage , 0x004FDBE0 );
[567]140DefFunc( ONiMain , 0x004d3280 );
141
[573]142DefFunc( ONrCharacter_NewAnimationHook , 0x004E97A0 );
[567]143DefFunc( ONrCheater , 0x004f5c30 );
[573]144DefFunc( ONrCorpse_Create , 0x004EF340 );
[567]145DefFunc( ONrGameState_NewCharacter , 0x004dac50 );
[573]146DefFunc( ONrGameState_DeleteCharacter , 0x004DC480 );
[567]147DefFunc( ONrGetActiveCharacter , 0x004f1180 );
148DefFunc( ONrPersist_GetGamma , 0x0050f450 );
149DefFunc( ONrPersist_GetWonGame , 0x0050f660 );
150DefFunc( ONrPlatform_Initialize , 0x0050f670 );
151DefFunc( ONrPlatform_WindowProc , 0x0050f7a0 );
[573]152DefFunc( ONrCharacter_SetHitPoints , 0x004EB220 );
153
[568]154DefFunc( iSetCharacterClass , 0x004D99D0 );
[567]155
[568]156
[573]157DefFunc( SLrGlobalVariable_Register_Int32 , 0x00477e30 );
158DefFunc( SLrGlobalVariable_Register_Float , 0x00477ec0 );
159DefFunc( SLrGlobalVariable_Register_String , 0x00477fe0 );
160DefFunc( SLrScript_Command_Register_ReturnType , 0x00477b20 );
161DefFunc( SLrScript_Command_Register_Void , 0x00477b40 );
[567]162
163DefFunc( SSrMessage_Find , 0x0047F550 );
164
165DefFunc( TMrInstance_GetInstanceName , 0x00423D90 );
166DefFunc( TMrInstance_GetDataPtr , 0x004232E0 );
167
[573]168DefFunc( TSrContext_DrawText , 0x0042DF00 );
169DefFunc( TSrContext_New , 0x0042EA30 );
170DefFunc( TSrContext_SetShade , 0x0042EE50 );
171DefFunc( TRrAnimation_GetDuration , 0x00428740 );
172DefFunc( TRrAnimation_GetFrom , 0x00428720 );
173DefFunc( TRrAnimation_GetTo , 0x00428730 );
[567]174
175DefFunc( UUrMachineTime_High , 0x04026480 );
176DefFunc( UUrMachineTime_High_Frequency , 0x040264b0 );
177DefFunc( UUrMachineTime_Sixtieths , 0x040263e0 );
178DefFunc( UUrPlatform_Initialize , 0x04026010 );
179DefFunc( UUrPlatform_Terminate , 0x04026310 );
180DefFunc( UUrStartupMessage , 0x00424860 );
[573]181DefFunc( OBJrDoor_Open , 0x004C26C0 );
182DefFunc( OBJrDoor_ForceOpen , 0x004C1EE0 );
[574]183//DefFunc( OBJrConsole_GetByID , 0x004C0950 );
184DefFunc( OBJrConsole_OnActivate , 0x004C0880 );
[578]185DefFunc( ONrCharacter_SetAnimationExternal , 0x004EB340 );
[579]186DefFunc( ONrGameState_Timer_Start , 0x004FD370 );
[574]187#define DefVar(type, name, address) //type* _##name = (type*)address
[567]188
189DefVar( onibool, ai2_deaf, 0x005ec0c1 );
190
[569]191DefVar( HINSTANCE, g_Instance, 0x0061F9E4 );
[567]192
193DefVar( gl_api_t*, gl_api, 0x00560604 );
194DefVar( gl_engine_t*, gl_eng, 0x00560600 );
195DefVar( WORD*, gl_gamma_ramp, 0x0055fdfc );
196DefVar( int, gl_gamma_ramp_valid, 0x005603fc );
197
198DefVar( char, opt_ignore_private_data,0x006370f0 );
199DefVar( char, opt_sound, 0x006370fc );
200
201DefVar( char, AKgDebug_DebugMaps, 0x002b2204 );
202
203DefVar( bool, BFgDebugFileEnable, 0x0055c8d0 );
204
205DefVar( uint32_t, COgConsoleLines, 0x005cb468 );
206DefVar( uint32_t, COgDefaultTextShade, 0x00533f70 );
207DefVar( uint32_t, COgDefaultTextShadow, 0x00533f74 );
208DefVar( uint32_t, COgFadeTimeValue, 0x00533f68 );
209
210DefVar( FILE*, ONgFileStartup, 0x005711b8 );
211DefVar( GameState*, ONgGameState, 0x005ece7c );
212DefVar( ONtPlatformData,ONgPlatformData, 0x0053100c );
213
214DefVar( char, M3gResolutionSwitch, 0x00531634 );
215
216DefVar( bool, SSgSearchOnDisk, 0x005eb758 );
217
218/*
219extern gl_engine_t* gl;
220extern gl_api_t* gl_api;
221extern WORD gl_gamma_ramp[3 * 256];
222extern int gl_gamma_ramp_valid;
223*/
224
225#undef DefVar
226void _DDrDefine_Symbols() {
227
[578]228}
Note: See TracBrowser for help on using the repository browser.