Jump to content


Photo

Porting To Gml To Gex!


  • Please log in to reply
2 replies to this topic

#1 Speewave123

Speewave123

    GMC Member

  • New Member
  • 67 posts

Posted 19 May 2007 - 07:09 PM

HOW TO PORT GML Scripts to GEX!

NOTE: Never Do this with SXMS! :(
NOTE 2: Ask the Authors permission before posting the GEX! they could possibly be making a GEX!

open the GML Script in GM7 and write up the code from dll like this:

//GML Example...

    external_call                 (global.dumbdll , some_initfunc,  ty_cdecl,   ty_real, 0)
// GM7 function                 if they used the   the function      dll export  return
// to get DLL Data             DLL with global

// 0 is #of arguments.
// arguments are data fed to the dll ex: DLLPlaySong ("sonic.mid",0) playing a midi looping 0 times!

// for every Argument there are 2 thing u need to have: argument#,ty_&&&&
// argument0 is argument number 1, for ty_ you'll need either string or real (numeric)

the easy part is porting to the Builder

Load DLL
Add functions
name (name the code u want to give to GM7 ex: some_initfunc would be Dumb_Init()
arguments, # of arguments
export: thats either cdecl or something else(i forgot)
return: return as string or real

arguments: as many arguments as u chose a list will pop up with Radio buttions

select what they return: Real or String

and thats how to port DLLs to GEX

fyi: for noob purposes i broke down gml with explainations of functions!

Edited by Speewave123, 19 May 2007 - 07:10 PM.

  • 0

#2 e_barroga

e_barroga

    ES Studios Leader

  • GMC Member
  • 2443 posts

Posted 19 May 2007 - 08:26 PM

open the GML Script in GM7 and write up the code from dll like this


That doesn't make total sense, really. So after reading that, I open up the GML Script in GM7, the code is already there (since I'm looking at a function from 39dll).

Basically, what you're telling me is, if I load the dll in the extension maker, then start adding the functions (setting their arguments, result type, and calling convention).... it'll work properly?

Result type would mostly be string, but, how do I know what calling convention to use?

export: thats either cdecl or something else(i forgot)

That's just practically useless to state because it's repeating what it says on the help. You're like defining it, but not explaining what to do.

Edited by e_barroga, 19 May 2007 - 08:27 PM.

  • 0

#3 BZGaming

BZGaming

    GMC Member

  • New Member
  • 514 posts

Posted 20 May 2007 - 05:38 PM

what you have as external_call up there should be external_define, external_call needs to be called separately and with different parameters.

BZ
  • 0




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users