C/C++ SDK: Module's for OfflineList.

If you have some comments or if you want more function please contact me at Replouf66@Hotmail.com

If you make a module for OfflineList please contact me, I will test it and propose it on my web site.
Replouf66@Hotmail.com

Before start:

Declaration needed:

typedef void (__stdcall FSetSize)(char **rom, long *size, long newSize); // call this function to inflate or deflate the size of the rom.
typedef struct {
   char *crc; // indicate the crc of the rom file.
   char *name; // indicate the name of the game.
   char *named; // indicate the rom naming.
   long num; // indicate the release number of the rom.
} s_gameModule;
typedef struct {
   char **rom; // this is just a pointer to an array of char.
   int *size; // this is just a pointer to the size of the rom.
   s_game *s_game; //struct with information about the rom.
} s_edit;


Function Summary
void __stdcall closeModule()
          This function is called when the module is deactivated.
void __stdcall configModule()
          If the user can configure the module this function will be called.
void __stdcall editRom(FSetSize resize, s_edit edit) *needed*
          Function to patch, edit or modify a rom.
char* __stdcall getAuthor()
          This function returns the Author of the module.
char* __stdcall getSDKVersion()
         This function returns the SDK version used by the plugin. *needed*
char* __stdcall getName()
          This function returns the name of the module.
char* __stdcall getSmallComment()
          This function returns a small comment to describe the module.
char* __stdcall getVersion()
          This function returns the version of the module.
void __stdcall initModule(char* dir)
         This function is called when the module is activated.
void __stdcall rename(long language)
         This function is called at startup of OfflineList and when the user change the selected language.

 

Function Detail

closeModule

void __stdcall closeModule()
This function is called when the module is deactivated.


Don't forget to free the memory allocated by your module.



configModule

void __stdcall configModule()
If the user can configure the module this function will be called.



editRom *needed*

void __stdcall editRom(FSetSize resize, s_edit edit)
Function to patch, edit or modify a rom.
Parameters:
resize - the function's address to inflate or deflate the rom.

edit - a record that contains the rom, its size and some informations.


getAuthor

char* __stdcall getAuthor()
This function returns the author of the module.
Returns:
a PCHAR indicating the author of the module.

getName

char* __stdcall getName()
This function returns the name of the module.
Returns:
a PCHAR indicating the name of the module.

getSDKVersion *needed*

char* __stdcall getSDKVersion()
This function returns the SDK version used by the plugin.
You need to return a valid version to recieve the correct struct.

Returns:
a char* indicating the plugin version.


getSmallComment

char* __stdcall getSmallComment()
This function returns a comment to describe the module.
Returns:
a PCHAR indicating what the module do.

getVersion

char* __stdcall getVersion()
This function returns the version of the module.
Returns:
a PCHAR indicating the module version.


initModule

void __stdcall initModule(char* dir)
This function is called when the module is activated.


You can store file configuration or anything in the directory "dir" you need to create it if it doesn't exist.

Parameters:
dir - the path where you can store file.


rename

void __stdcall rename(long language)
This procedure is called at startup of OfflineList and when the user change the selected language.


The language value:

- 0 : English

- 1 : French

- 2 : Chinese (Simp)

- 3 : Chinese (Trad)

- 4 : German

- 5 : Dutch

- 6 : Italian

- 7 : Japanese

- 8 : Norwegian

- 9 : Polish

- 10 : Portuguese (Brazil)

- 11 : Spanish

- 12 : Spanish (Mexico)

- 13 : Swedish

- 14 : Danish

- 15 : Czech

- 16 : ...

Parameters:
language - Indicating the language selected in OfflineList.