X-Git-Url: http://4ch.mooo.com/gitweb/?a=blobdiff_plain;ds=sidebyside;f=src%2Fscroll.c;h=2746ca4f1cc500316ba210f54ce75dc116b13871;hb=fdba3fc0da3fb172176d9f74a8c4c55a23250e8a;hp=338f1899ba9b2ae977edff7ff68fe30b0f7a9b0c;hpb=fb897d1288f61d27fa52c7bd05cddf8df40e1bca;p=16.git diff --git a/src/scroll.c b/src/scroll.c index 338f1899..2746ca4f 100755 --- a/src/scroll.c +++ b/src/scroll.c @@ -1,5 +1,5 @@ /* Project 16 Source Code~ - * Copyright (C) 2012-2016 sparky4 & pngwen & andrius4669 & joncampbell123 + * Copyright (C) 2012-2016 sparky4 & pngwen & andrius4669 & joncampbell123 & yakui-lover * * This file is part of Project 16. * @@ -34,13 +34,12 @@ static map_t map; player_t player[MaxPlayers]; map_view_t mv[4]; //word pn=0; //i forgot ww -//static planar_buf_t huge *pp; float t; sword bakapee; pan_t pan; //debugswitches boolean panswitch=0; -boolean pageflipflop=1; +//extern boolean pageflipflop=1; unsigned int i; const char *cpus; //static int persist_aniframe = 0; /* gonna be increased to 1 before being used, so 0 is ok for default */ @@ -49,7 +48,7 @@ boolean pageflipflop=1; word pg; //#ifdef FADE static word paloffset=0; - byte *dpal, *default_pal; + byte *dpal; //#endif byte *gpal; byte *ptr; @@ -92,13 +91,8 @@ void main(int argc, char *argv[]) _DEBUGF("Serial debug output printf test %u %u %u\n",1U,2U,3U); pan.pn=1; - //player[0].data = &pp; - //printf("starting timer "); start_timer(&gvar); - //printf("ok\n"); - -// atexit(qclean()); /* create the map */ fprintf(stderr, "testing map load~ "); @@ -115,7 +109,6 @@ void main(int argc, char *argv[]) /* data */ player[0].data = malloc(48*128); //TODO use exmm *player[0].data = bitmapLoadPcx("data/chikyuu.pcx"); // load sprite - //npctmp = bitmapLoadPcx("ptmp1.pcx"); // load sprite /* create the planar buffer */ ////++++ (player[0].data) = *planar_buf_from_bitmap(&p); @@ -133,8 +126,6 @@ void main(int argc, char *argv[]) #ifdef MODEX #ifdef FADE dpal = modexNewPal(); - default_pal = modexNewPal(); - *default_pal = *dpal; modexPalSave(dpal); modexFadeOff(4, dpal); #endif @@ -291,9 +282,9 @@ void main(int argc, char *argv[]) } if(IN_KeyDown(67)) //f9 { - modexClearRegion(mv[1].page, 0, 0, mv[1].page->width, mv[1].page->height, 32); - modexClearRegion(mv[2].page, 0, 0, mv[2].page->width, mv[2].page->height, 47); - modexClearRegion(mv[3].page, 0, 0, mv[3].page->width, mv[3].page->height, 45); + modexClearRegion(mv[1].page, 0, 0, mv[1].page->width, mv[1].page->height, 2); + modexClearRegion(mv[2].page, 0, 0, mv[2].page->width, mv[2].page->height, 3); + modexClearRegion(mv[3].page, 0, 0, mv[3].page->width, mv[3].page->height, 4); modexClearRegion(mv[3].page, 0, 0, 20, 36, 15); //IN_UserInput(1,1); } @@ -311,7 +302,7 @@ void main(int argc, char *argv[]) }*/ //9 - if(IN_KeyDown(10)){ modexPalOverscan(rand()%56); modexPalUpdate1(default_pal); IN_UserInput(1,1); } + if(IN_KeyDown(10)){ modexPalOverscan(rand()%56); modexPalUpdate1(dpal); IN_UserInput(1,1); } //if(IN_KeyDown(11)){ modexPalOverscan(15); } if((player[0].q==1) && !(player[0].x%TILEWH==0 && player[0].y%TILEWH==0)) break; //incase things go out of sync! }