Jump to content
  • Advertisement
Sign in to follow this  
Pseudo-G

Allegro Runtime Error

This topic is 4872 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Well, after quite a lot of "persuading", I finally got allegro to work with msvc6 (yup, another incompetent programmer ^_^) But, anyways, I've gotten it to compile without any errors, but now it pops up a runtime error as soon as the program starts: "game.exe has encountered a problem and needs to close. We are sorry for the inconvenience." I cannot figure out what might cause this for the life of me... ...any of you guys (or girls) have any clue? BTW, here's the simple code i'm using, if it matters:
#include <iostream>
#include <allegro.h>
using namespace std;

int main(int argc, char *argv)
{
	allegro_init();
	install_keyboard();
	if (set_gfx_mode( GFX_AUTODETECT, 640, 480, 0, 0) < 0)
	{
		allegro_message("Unable to autodetect GFX mode", allegro_error);
	}

	readkey();

	return 0;
}
END_OF_MAIN();

Share this post


Link to post
Share on other sites
Advertisement
Are you compiling with the multi-threaded DLL's? I don't know if this would make a difference in this case, but I often hear that making sure your using multi-threaded DLL's will fix run time problems like this.

[Edited by - AsOne on November 22, 2005 8:18:24 PM]

Share this post


Link to post
Share on other sites
Well, I've looked through the docs, and I still can't come up with a clear description of what exactly the multi-threaded DLLs are. The best answer I can give is that I'm using "alleg.lib". Other than that, I don't know.

Share this post


Link to post
Share on other sites
Are you sure you are using the same exact version of the Allegro DLL as the lib you are linking against? Do you get any warnings when linking?

Share this post


Link to post
Share on other sites
Well, I got fed up with trying over and over, so I just re-downloaded Allegro and reinstalled it...and now it works 0.o

I did everything exactly the same as far as I can tell......well, at least now it works...

Thanks for your help, guys!

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!