i+=mv->map->width - tx;
}
//modexCopyPageRegion(mv[1].page, mv[0].page, 0, 0, 0, 0, mv[0].page->width, mv[0].page->height);
- _fmemmove(mv[1].page->data, mv[0].page->data, mv[0].page->pagesize);
+ /* block copy pattern to where we will draw the sprite */
+ vga_setup_wm1_block_copy();
+ _fmemcpy(mv[1].page->data, mv[0].page->data, mv[0].page->pagesize);
+ /* must restore Write Mode 0/Read Mode 0 for this code to continue drawing normally */
+ vga_restore_rm0wm0();
modexCopyPageRegion(mv[3].page, mv[!(mv->video->p)].page, 0/**/, 0/**/, 0, 128, 28, 36);
}
if(pageflipflop){
if(gv->video.r){
//modexCopyPageRegion(&(gv->video.page[(gv->video.p)]), &(gv->video.page[(!gv->video.p)]), 0, 0, 0, 0, gv->video.page[gv->video.p].width, gv->video.page[!gv->video.p].height);
+ /* block copy pattern to where we will draw the sprite */
+ vga_setup_wm1_block_copy();
_fmemmove((gv->video.page[(gv->video.p)]).data, (gv->video.page[(!gv->video.p)]).data, gv->video.page[(!gv->video.p)].pagesize);
+ /* must restore Write Mode 0/Read Mode 0 for this code to continue drawing normally */
+ vga_restore_rm0wm0();
modexShowPage(&(gv->video.page[gv->video.p]));
gv->video.p=!gv->video.p;
gv->video.r=!gv->video.r;
//IN_initplayer(&player, 1);
#ifndef SPRITE
- modexClearRegion(mv[1].page, player[0].x-4, player[0].y-TILEWH, 24, 32, 15);
+ modexClearRegion(mv[1].page, player[0].x, player[0].y-TILEWH, 24, 32, 15);
#else
//PBUFSFUN(mv[1].page, player[0].x-4, player[0].y-TILEWH, 24, 64, 24, 32, PLAYERBMPDATA);
PBUFSFUN(mv[1].page, player[0].x-4, player[0].y-TILEWH, 24, 64, 24, 32, &pp);
printf("tile resolution: %dx", gvar.video.page[0].tw); printf("%d \n", gvar.video.page[0].th);
printf("middle tile position: %dx", gvar.video.page[0].tilemidposscreenx); printf("%d\n", gvar.video.page[0].tilemidposscreeny);
modexprintmeminfo(&gvar.video);
- //printf("mv[%u].tx: %d", pan.pn, mv[pan.pn].tx); printf(" mv[%u].ty: %d ", pan.pn, mv[pan.pn].ty); printf("gvar.video.p=%u\n", gvar.video.p);
+ //printf("mv[%u].tx: %d", pan.pn, mv[pan.pn].tx); printf(" mv[%u].ty: %d ", pan.pn, mv[pan.pn].ty);
+ printf("gvar.video.p=%u ", gvar.video.p); printf("gvar.video.r=%u ", gvar.video.r);
printf("pageflipflop=%u\n", pageflipflop);
printf("\ngvar.video.tickclk=%f\n", gvar.video.tickclk);
printf("gvar.video.clk=%f", gvar.video.clk);