From: "J.A. Bijsterbosch" Newsgroups: comp.os.msdos.djgpp Subject: Re: ?Win95 crash from Allegro:Set_pallete? Date: 23 Mar 1998 18:28:26 GMT Organization: Bijsterbosch Productions Lines: 56 Message-ID: <01bd5649$434468c0$LocalHost@none> References: NNTP-Posting-Host: asd1-p79.worldonline.nl To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Precedence: bulk Hello James, James W Sager Iii schreef in artikel ... > I could use help as this is beyond my control. > This code works fine under DOS, Really?, it seems that you set the graphics mode before you have even initialised Allegro itself. > > #include "allegro.h" > //Just a .pcx file with pallete information. > //Make up any ol .pcx to test it. > BITMAP *BUTTON; > PALLETE stndpal; > > void main(void) Please, if you want to be taken seriously make this: int main(void) > { > //640 x 480 mode > set_gfx_mode(0,640,480,1024,1024); Move the above line to a place after you've initialised Allegro and it's components. > allegro_init(); > install_mouse(); > install_timer(); Like here. > BUTTON=load_pcx("butup.pcx",stndpal); > set_pallete(stndpal); > lbl:; > show_mouse(screen); > //allow you to use the mouse :) > while (true) > { > } > } > > Any hints or suggestions would be appreciated... I have absolutely NO > idea why 'set_pallete' would crash the 'puter. Well, make the changes and see what happens.. ;-)) -- Greetings from sunny Amsterdam, Jan Bijsterbosch email: bijster AT worldonline DOT nl http://home.worldonline.nl/~bijster