[AD] MSVC Crash

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


(You might complain that this is off topic - I don't know - but I'm subscribed to this and not any other, so here goes)

I've got an annoying problem with my game: It runs perfectly in DOS, but under Windows (MSVC) it crashes on the following line:

tank[t].grab = create_bitmap(pic->w, pic->h);

I know this, because I've done some logging, and it will print to a file immediately before this line, but not immediately after. To try and isolate the problem, I got rid of the 'tank[t].grab = ' bit, and replaced pic->w and pic->h with their actual values, to get the following:

create_bitmap(46, 48);

And it still crashes. If I change either the 46 or the 48 to 35 or below, it doesn't crash, which is REALLY weird. Any ideas? (I know it's impossible to say from such little information, but I really can't think what else is relevant. For the full source code, download http://www.geerswj.clara.net/shrapnel.zip and look in shrapnel.cpp, DrawTanks(); ) All I can say is that it used to work when the program used 16-bit color depth, and now that I've brought it down to 8 it's crashing.

I'm running W.I.P. 3.9.31 under Win98 R2, on an Intel machine with a TNT2.

Andy Geers
--
Bart's Blackboard Quote:
I will not use abbrev.

Andrew Geers
mailto:andy@xxxxxxxxxx
http://www.geerswj.clara.net




Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/