• Advertisement
  • entries
    437
  • comments
    1000
  • views
    336489

gmSDL 0.1 (preview)

Sign in to follow this  

131 views

First: Part 1 of my GameMonkey Script article went up over the weekend. It's linked on the front page [smile] - you'll want to read it before the next one goes up as part 2 assumes you know the info in the first article.

Second: I released a 0.1 preview of gmSDL, my SDL binding for GameMonkey Script. If you hook this up to your application you add the abilities of SDL to your scripting environment, allowing you to use graphics and input (and eventually sound). This binding is pretty early, hence the journal release but is already usable. I'm hoping that I can bind the majority of SDL with this thing and provide a simple exe for people to 'just run it'. It's like a lower level of GMGX right now...
Sign in to follow this  


4 Comments


Recommended Comments

GameMonkey is pretty awesome, I really should try it out one day.

As for the .NET bindings, why would you rather a port then P/Invoked functions? If we do port it, I'd wait until GM2.0.

Share this comment


Link to comment
Not really looked into the P/Invoked stuff - I might have to. I did try to write a wrapper in C++/CLI (or whatever it was) and I found it a pain because we needed to pass around instances of various classes too much. I'll look into P/Invoke now... Cheers!

I'm curious about GM2 - I hope Greg releases a preview soon!

EDIT: P/Invoke - now I remember why I never used it - GMScript doesn't work too well as a DLL right now - mainly because it's C++ based and everything is in classes. I have no idea how to use P/Invoke on the stuff from the DLL without writing a C/DLL wrapper first and THEN using P/Invoke - but that sounds like a ballache to me.

Share this comment


Link to comment
Ahhh, it might be better to do a full port instead anyway. Giving GM bindings to .NET and vise versa would be pretty cool. You could even then give it access to the Tao Framework making GM able to use OpenGL, SDL, GLFW, etc.

Speaking of whic, how are you going about making gmSDL?

Share this comment


Link to comment
gmSDL is just a straight binding to GMScript. Pretty easy once you know the GM API and how to bind types and functions. The binding is compiled into an exe (really simple, literally says "load this script and run until GM has no more threads running") and linked with SDL. I'm probably going to expand the simple exe to allow you to specify which scripts to load, etc. That is, after I've quashed some of the many outstanding TODO items for gmSDL.

I've got a simple pacman style level renderer knocked up in GM script with the SDL bindings right now - pretty cool [cool].

Share this comment


Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Advertisement