Only for VC++ for now, and only tested on the 10.0 compiler (2010) with GM 8.1.141. Some older 8.1 GM versions should work, back perhaps to when get_function_address was added.
You need to call the gm::init method with the address of get_function_address, as in the test dll. After that the other functionality should work (creating gm::Value objects, calling gm functions, etc.).
Doxygen Documentation
Current Features
- Call GM methods.
- Access some built in variables for the self and other instances.
- Access user defined variables.
- Supports multiple GM 8.1 versions.
- Provide the ability to call all Game Maker functions (any missing?).
- Provide the ability to get an instance pointer from an instance id.
- Access to some GM resources, such as sprites and textures.
Planned for 1.0.0
- Support common toolsets.
- Support all commonly used GM versions.
- Ensure everything works when mutliple versions of the GMAPI built by different toolsets with different configurations are present in a single game, everything works.
Downloads
Source 0.0.7: 7z zip
Binaries 0.0.7: 7z zip
Binaries archives include headers, and compiled builds for dll/static, debug/release. Requires VC++ Runtimes)
SVN
Get older versions from http://willnewbery.com/gmapi/
Change List
0.0.7 - 2012-09-28
Direct3D8 header usage is now opt-in. Define GMAPI_USE_D3D, else the interfaces will be typed to void.
Added access to GM's Sprite and Texture objects, including the IDirect3DTexture8 objects used.
gm::call adds an extra empty argument since it appears to be expected by certain GM functions.
Changed CPU instructions inserted into the start of external_call (HOOK_VERSION changed to 3).
Added some files for Code::Blocks and GCC and corrected some issues. These platforms are still unsupported.
0.0.6 - 2012-08-07
Added access to GM's IDirect3DDevice8*.
Added "unsigned argcnt, Value *args" overloads to some GM functions.
Completed code to handle multiple GMAPI instances in a single process (when 2 or more extensions use different GMAPI builds in a single game).
Added the RefString class to accept the readonly borrowed ref strings from GM.
Added the ability to get and set existing user defined variables and array elements (just zero initialise them in GML first or such).
0.0.5 - 2012-07-29
Rewrote all the string interfacing code. String objects are now used rather than a pointer and a few utility methods.
Wrote a simple GM unit test program to go with the Test project.
0.0.4 - 2011-10-17
Added particle functions.
Added d3d functions.
Added more comments to public header files.
Added some more gm::Instance fields.
Added functionality to get instance pointer from an id.
Corrected self and other instance pointer register use.
0.0.3 - 2011-09-29
Fixed mistake with releaseStr
Moved all assembly to single file
0.0.2 - 2011-09-29
Initial public version
Edited by SyncViews, 28 September 2012 - 10:00 PM.











