Page 1 of 1

Load Separate .ged-files

PostPosted: Sat Feb 12, 2005 10:51 am
by Fenrir
I've made a menu sytem in one .ged-file. It looks like this:

New Game
Load Game
Options
Credits
Exit Game

When I click on "New Game", it loads a separate .ged-file, no problem at all while in GE. When I have exported the menu as a .exe, the "New Game" wont load the .ged. What's wrong? How can I make GE understand that while exporting the menu to .exe, it should do the same with the separate .ged?

PostPosted: Sat Feb 12, 2005 1:39 pm
by willg101
Did you try exporting all of your files to *.exe and then changing the load game command to
Code: Select all
LoadGame("<yourgame.exe>");

PostPosted: Sat Feb 12, 2005 6:25 pm
by Fenrir
willg101 wrote:Did you try exporting all of your files to *.exe and then changing the load game command to
Code: Select all
LoadGame("<yourgame.exe>");


Well that worked, thanks. :D
However so did copying only the .geds. :oops: Shame on me for not trying before asking for help. Sorry. :oops: :oops:

PostPosted: Sun Feb 13, 2005 3:41 pm
by makslane
How to LoadGame works:

Example: LoadGame("game.ged");

- In editor mode, load the game.ged game
- In exported version, load the game.exe or game.dat file

You can't load .ged in exported games.
You must export the first level as .exe and the other as .dat (game data only)

.exe

PostPosted: Thu Jun 02, 2005 5:46 pm
by CdaMarinersFan
I can't load .exe files from an exe file. Any help?

PostPosted: Thu Jun 02, 2005 6:21 pm
by BeyondtheTech
I'm intrigued by this command, as I've never used it before. I'm considering using it for a number of reasons: 1. My exported game as a single EXE file on the PocketPC can get huge! and 2. GE doesn't have some required commands, so I could possibly run another non-GE program to do it.


So, please correct my theories and questions, since I don't have the program at work here. :?

1. Using the LoadGame command will exit the current EXE as the new one is loaded, or will both programs be running concurrently? Do I need to code ExitGame after LoadGame so they won't run at the same time and eat up speed/resources?

2. I can use this command to load any .EXE executable, even if it wasn't generated by Game Editor?

3. At the point I'm about to export the game to an EXE file, I have to manually change all the LoadGame commands to point to ".EXE" files instead of ".GED" files, and back again when I'm editing the game? Or can I just say LoadGame("Level2") and it will automatically detect if it's running as a GED or EXE file?

The reason for #2 is that I was hoping for a "date" and "time" variables to be imported in the next version (one of the wanted features I posted in the other forum). For instance, I want to make the program detect the month so it can change characters or environment depending on the actual season, or if it's day or nighttime. I also want to calculate Internet time, or Star Trek Stardates based on the actual time.

One workaround theory was that I would have someone create a very small EXE in another language such as eVC++ (something that didn't require a runtime library on the PocketPC) to get the system date and time and write it into a file. Then, my GameEditor EXE game would use the LoadGame command to run it, then open the generated text file to "retrieve" the data. Would've saved me a lot of trouble if it could be implemented into Game Editor, but this is the simple dilemma I'm facing.

PostPosted: Fri Jun 03, 2005 12:21 pm
by makslane
To load a level in editor or exported game, just use:
LoadGame("filename.ged");

You can't use LoadGame to execute executable files.