Distributing Executables

Started by
3 comments, last by slynk 13 years, 7 months ago
Erm I made a small test of the game I've been making and decided to send it to my girlfriend's computer for test; however, when she tried launching the game, it crashed. It works on my computer (the executable, I'm not hitting run in the compiler.) I included the allegro dll that was necessary and had her download the "Microsoft Visual C++ 2010 Redistributable Package (x86)" since I used Visual Studio 2010 to build the project. Is there something else I'm missing? It just crashes, no error message other than the "Would you like to send a crash report" window that pops up. She's using xp, I'm running windows 7. She's 32 bit, I'm 64.

The game used some images. I thought they would be thrown into the executable, am I wrong about this? If so where do I have her put them? Do I need to move them so they are in some sort of relative path in my code as apposed to the absolute one I have right now?

Thanks in advanced.
Advertisement
Your app with need to have a folder with all it's required data files. The data files will need to have their proper paths as well. If you just load them from the program folder in your code, then put them all in one folder.

If you load them from sub folders, then you are going to need those subfolders as well.

eg:

GAMEFOLDER
-Game.exe
--ImagesFolder
---sprite.png
--SoundsFolder
---kabom.wav
---gameover.wav
--MusicFolder
---bkg.mp3

There is a utility program that comes with allegro to let you pack all your files into a single archive and load them from there.
Ok, I made a folder where my main.cpp file is called "Resources", dropped the tileset.dat file into it, and changed the code to "Resources\\tileset.dat" but Visual Studio can't find it when I hit run. I tried right clicking the "Resource Files" section in the solution explorer, and add existing item but it still crashed. Then I made a filter and named it "Resources" and dropped the file in the solution explorer into. Nothing I do makes it work. Am I doing something wrong in my attempts to use a relative path? Do I need to use a full path and it will be converted to a relative one at compile time?
Never mind, was using the wrong .dat file. I'll send her the new project with the resource files and see if it works.
That worked. Thank you very much. ^^

This topic is closed to new replies.

Advertisement