TGMG
|
![](https://enigma-dev.org/forums/Themes/enigma_v4/images/xx.gif) |
Posted on: December 29, 2010, 09:44:42 am |
|
|
![Developer](membericons/developer.svg.png) Joined: Jun 2008
Posts: 107
|
Since I haven't been able to run enigma games on macos or iphone/android recently I decided to test how well the compile process works up to the running stage. I am really impressed with how well the enigma compiler works at the moment, with a small edit to the compiler and a definitions file which contains the empty functions that are needed for the game I was able to almost compile and link all of them. They do require certain modifications (see the errors I posted on tracker recently) such as removing switch statements, editing some of the actions, changing resource names, changing all '=' to '==' in expressions etc So first the games that I was testing are the top 10 most downloaded on 64D: 1) Platform shooter works (works but have to change = into ==)2) Online engine works but not server (works but requires commenting switch statements!)3) gceffects engine (has a variable called write/index! didn't finish replacing all variables)4) real water (linker error)5) Jenners platform engine ( works but have to change = into ==,has a variable named free!)6) Skidmark all (normal and unreg) works (but have to change = into ==)7) Online highscores (compiles successfully)8) Dndexample works (drag and drop objects)9) physics engine v2 (compiles but 2 linker errors sprite_add and _working_directory)10) segfaults the enigma compilerI haven't listed all the errors in the brackets as most have the = to == and require the switch statement removal. But a few really annoying things kept creeping up, first variable names, alot of game maker games use variables with names like 'index' 'write' 'pow' which won't work in enigma as they have been defined by something else. I gave up replacing all the variable names in the gceffects engine as there was so many. Another annoying thing is the way people name there resources, some are c++ keywords like 'catch' other contain spaces and more often the sprites have the same name as the objects etc. Which causes a compile error which would be very confusing to new users. Anyway onto the segfaults, you will need these definitions files to test all of them: actions: http://enigma.pastebin.com/tBZvy2C6others: http://enigma.pastebin.com/5JLTHQj8They also require a change to the enigma compiler: added to compile.cpp under the rest of them: wto << "enum //font names\n{\n"; for (int i = 0; i < es->fontCount; i++) wto << " " << es->fonts[i].name << " = " << es->fonts[i].id << ",\n"; wto << "};\n\n";
wto << "enum //timeline names\n{\n"; for (int i = 0; i < es->timelineCount; i++) wto << " " << es->timelines[i].name << " = " << es->timelines[i].id << ",\n"; wto << "};\n\n";
wto << "enum //path names\n{\n"; for (int i = 0; i < es->pathCount; i++) wto << " " << es->paths[i].name << " = " << es->paths[i].id << ",\n"; wto << "};\n\n";
Now the files: ackack: http://dl.dropbox.com/u/5072558/segfaulting/ENIGMA_ackackenginev1.7.gm6server: http://dl.dropbox.com/u/5072558/segfaulting/Enigma_Online%20Engine%20Server.gm6ackackengine gives: Writing modes and settings Writing object switch Writing resource names and maxima Writing events Checking for default code in ev[2, 0. Checking for default code in ev[0, 0. Checking for default code in ev[8, 0. Checking for default code in ev[6, 50. Checking for default code in ev[5, 86. Checking for default code in ev[9, 88. Checking for default code in ev[6, 4. Checking for default code in ev[7, 5. Checking for default code in ev[3, 0. Checking for default code in ev[7, 10. Invalid memory access of location 0x28 rip=0x7fff84df19bf
Segmentation fault
online server gives: >> Searching for `global` in globj->locals (19 entries) { acc_id, argument0, argument1, argument2, argument3, argument4, argument5, argument6, argument7, dll_cdecl, i, keyboard_string, name, pid, servertcp, tcp, ty_real, ty_string, username, end } Typeless Invalid memory access of location 0x0 rip=0x7fff84df20aa
Next i'm going to try and look into all the errors that I posted on the tracker and try and fix them if possible, although just the enigma plugin ones related to actions, would have no idea how to implement the parser ones (== and switch statements), and then hopefully do the next 10 which I hope will go much smoother.
|
|
« Last Edit: December 29, 2010, 04:11:35 pm by TGMG »
|
Logged
|
meGMbed 2.0 :: Embed you gm games in websites.
|
|
|
polygone
|
![](https://enigma-dev.org/forums/Themes/enigma_v4/images/xx.gif) |
Reply #1 Posted on: December 29, 2010, 10:36:00 am |
|
|
![Contributor](membericons/contributor.svg.png) Location: England Joined: Mar 2009
Posts: 794
|
Is anything planned with LGM to help resolve things like conflicting variable names? Like a smart syntax debugger tool which will search for syntax errors like this then allow the user to perform actions to resolve it (like renaming the variables).
|
|
|
Logged
|
I honestly don't know wtf I'm talking about but hopefully I can muddle my way through.
|
|
|
Josh @ Dreamland
|
![](https://enigma-dev.org/forums/Themes/enigma_v4/images/xx.gif) |
Reply #2 Posted on: December 29, 2010, 11:05:50 am |
|
|
Prince of all Goldfish
![Developer](membericons/developer.svg.png) Location: Pittsburgh, PA, USA Joined: Feb 2008
Posts: 2950
|
I just fixed that segfault a bit ago, but haven't yet committed it due to an issue that came with it. I'd appreciate it if you linked to them with their description (should the top 10 change).
|
|
|
Logged
|
"That is the single most cryptic piece of code I have ever seen." -Master PobbleWobble "I disapprove of what you say, but I will defend to the death your right to say it." -Evelyn Beatrice Hall, Friends of Voltaire
|
|
|
|
Josh @ Dreamland
|
![](https://enigma-dev.org/forums/Themes/enigma_v4/images/xx.gif) |
Reply #4 Posted on: December 29, 2010, 01:39:13 pm |
|
|
Prince of all Goldfish
![Developer](membericons/developer.svg.png) Location: Pittsburgh, PA, USA Joined: Feb 2008
Posts: 2950
|
Now if only the type coercer were so competent. That's what I get for adopting an even remotely standard method. ... ![Tongue :P](https://enigma-dev.org/forums/Smileys/somethingawful/tongue.gif)
|
|
|
Logged
|
"That is the single most cryptic piece of code I have ever seen." -Master PobbleWobble "I disapprove of what you say, but I will defend to the death your right to say it." -Evelyn Beatrice Hall, Friends of Voltaire
|
|
|
polygone
|
![](https://enigma-dev.org/forums/Themes/enigma_v4/images/xx.gif) |
Reply #5 Posted on: December 29, 2010, 03:21:18 pm |
|
|
![Contributor](membericons/contributor.svg.png) Location: England Joined: Mar 2009
Posts: 794
|
@polygone: LGM doesn't perform syntax checking, it delegates that task off to ENIGMA, since that's where the competent parser is.
OK. Would the interface not need to be done by LGM though?
|
|
|
Logged
|
I honestly don't know wtf I'm talking about but hopefully I can muddle my way through.
|
|
|
TheExDeus
|
![](https://enigma-dev.org/forums/Themes/enigma_v4/images/xx.gif) |
Reply #6 Posted on: December 29, 2010, 03:35:01 pm |
|
|
![Developer](membericons/developer.svg.png) Joined: Apr 2008
Posts: 1860
|
Another annoying thing is the way people name there resources, some are c++ keywords like 'catch' other contain spaces and more often the sprites have the same name as the objects etc. Which causes a compile error which would be very confusing to new users. Didn't parser already add prefixed like OBJ_ to objects and SPR_ to sprites? Because in IDE_EDIT you already have things like: variant enigma::OBJ_obj_0::myevent_draw() Thou in IDE_EDIT_resourcenames.h they are without them. I think this should be an easy fix, as just adding easy prefixes for all resource names.
|
|
|
Logged
|
|
|
|
|
|
IsmAvatar
|
![](https://enigma-dev.org/forums/Themes/enigma_v4/images/xx.gif) |
Reply #9 Posted on: December 29, 2010, 11:38:09 pm |
|
|
LateralGM Developer
![LGM Developer](membericons/lgm_developer.svg.png) Location: Pennsylvania/USA Joined: Apr 2008
Posts: 877
|
@polygone: LGM doesn't perform syntax checking, it delegates that task off to ENIGMA, since that's where the competent parser is.
OK. Would the interface not need to be done by LGM though?
What interface? I add a button somewhere that delegates to Enigma's checkForDuplicateVariables method? JButton b = new JButton("DupVars"); b.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { EnigmaDriver.checkForDuplicateVariables(); } }); add(b); done.
|
|
|
Logged
|
|
|
|
polygone
|
![](https://enigma-dev.org/forums/Themes/enigma_v4/images/xx.gif) |
Reply #10 Posted on: December 30, 2010, 09:39:19 am |
|
|
![Contributor](membericons/contributor.svg.png) Location: England Joined: Mar 2009
Posts: 794
|
I was thinking of something a little more extensive than that, like Word's spelling/grammar syntax tool. But it doesn't matter, I was thinking more long term, I know something like that wouldn't be added any time soon.
|
|
|
Logged
|
I honestly don't know wtf I'm talking about but hopefully I can muddle my way through.
|
|
|
|
Josh @ Dreamland
|
![](https://enigma-dev.org/forums/Themes/enigma_v4/images/xx.gif) |
Reply #12 Posted on: December 30, 2010, 03:33:51 pm |
|
|
Prince of all Goldfish
![Developer](membericons/developer.svg.png) Location: Pittsburgh, PA, USA Joined: Feb 2008
Posts: 2950
|
The hard part is actually doing anything with JEdit. I've been thinking a compatibility tool for GM users would be desirable.
The real struggle is getting people to be aware of the components of ENIGMA that GM simply doesn't offer. They'll have to ease into it, which means lots of compatibility settings. It wouldn't be wise to just replace all comparison = with == upon loading a GM6, because users wouldn't learn anything (they'd still use =, then file a bug report when it failed).
Right now the idea is to have two settings panes saved; one for creating EGM files, another for loading/creating GM6 files. That, however, requires collaboration between ism and myself, so...
|
|
|
Logged
|
"That is the single most cryptic piece of code I have ever seen." -Master PobbleWobble "I disapprove of what you say, but I will defend to the death your right to say it." -Evelyn Beatrice Hall, Friends of Voltaire
|
|
|
|
|