Compilation failing on other PC's

8060f823d3b004e7f088076ae8a159c7
0
TheJjokerR 101 May 11, 2011 at 10:20

Hey again,

Today I compiled my game in Microsoft Visual Studio 2008, it’s using the IGAD template and I accidentally tested the debug mode on a different pc, so that didn’t work.

After that I compiled it in release mode and sent it to a friend, who said the game just shut down with no error right after passing the main menu.

So I tried it on my laptop and it launched fine, except for it launched in fallback mode. Here’s the code (from the template) related:

SDL_Init( SDL_INIT_VIDEO );
    SDL_SetVideoMode( SCRWIDTH, SCRHEIGHT, 32, SDL_OPENGL );
    SDL_EnableKeyRepeat( 0, 0 );
    bool vbo = true;
    if (!init()) 
    {
        SDL_SetVideoMode( SCRWIDTH, SCRHEIGHT, 32, SDL_HWSURFACE|SDL_DOUBLEBUF );
        SDL_Surface* s = SDL_GetVideoSurface();
        surface = new Surface( SCRWIDTH, SCRHEIGHT, (Pixel*)s->pixels, s->pitch );
        surface->InitCharset();
        vbo = false;
        SDL_WM_SetCaption( "Beach Defence: A project for IGAD! - FALLBACK", NULL );
    }
    else SDL_WM_SetCaption( "Beach Defence: A project for IGAD!", NULL );

Fallback mode looks ugly, the window is SCRWIDTH by SCRHEIGHT, but the contents of the window(the screen) are black and white and the screen is drawn twice next to eachother. It’s also not detecting the cursor position properly(because of it being drawn twice).

Here’s the compile: http://www.gobrainless.com/nhtv/beachdefenceasd.rar

It might even react differently with you than it did on my laptop, seeing how my friend couldn’t even get past the main menu.

I’m doing nothing funny in the code that could mess this up, so I’m thinking it’s something with the template.

Any help is appreciated.

EDIT
I compiled a fresh version of the template and it’s showing the same issues. I am compiling on a 64x Windows 7 and it wont work properly on a 86x Windows XP. Is there a config somewhere where I compile it especially for the 64bit version by accident?

1 Reply

Please log in or register to post a reply.

A8433b04cb41dd57113740b779f61acb
0
Reedbeta 167 May 11, 2011 at 17:48

It looks like the template might require some OpenGL extensions (“vbo” likely refers to “vertex buffer object”, a commonly used extension). Probably your friend’s laptop either does not have up-to-date video drivers installed, or his hardware does not support this feature to begin with. I’d try having him update his drivers and then try your app again.