modexHiganbanaPageSetup(&gvar.video);
gvar.video.page[1].dx=gvar.video.page[0].dx=16;
gvar.video.page[1].dy=gvar.video.page[0].dy=16;
modexHiganbanaPageSetup(&gvar.video);
gvar.video.page[1].dx=gvar.video.page[0].dx=16;
gvar.video.page[1].dy=gvar.video.page[0].dy=16;
* this time, we render the distinctive pattern to another offscreen location and just copy.
* note this version is much faster too! */
{
* this time, we render the distinctive pattern to another offscreen location and just copy.
* note this version is much faster too! */
{
//4 this dose the sprite? wwww
/* fill pattern offset with a distinctive pattern */
for (i=0;i < gvar.video.page[0].width;i++) {
//4 this dose the sprite? wwww
/* fill pattern offset with a distinctive pattern */
for (i=0;i < gvar.video.page[0].width;i++) {
vga_write_sequencer(0x02/*map mask*/,1 << (i&3));
for (j=0;j < VMEMHEIGHT;j++,o += gvar.video.page[0].stridew)
vga_state.vga_graphics_ram[o] = (i^j)&15; // VRL samples put all colors in first 15!
vga_write_sequencer(0x02/*map mask*/,1 << (i&3));
for (j=0;j < VMEMHEIGHT;j++,o += gvar.video.page[0].stridew)
vga_state.vga_graphics_ram[o] = (i^j)&15; // VRL samples put all colors in first 15!
h = vrl_header->height + overdraw + y - ry;
w = (x + vrl_header->width + (overdraw*2) + 3/*round up*/ - rx) & (~3);
if ((rx+w) > gvar.video.page[0].width) w = gvar.video.page[0].width-rx;
h = vrl_header->height + overdraw + y - ry;
w = (x + vrl_header->width + (overdraw*2) + 3/*round up*/ - rx) & (~3);
if ((rx+w) > gvar.video.page[0].width) w = gvar.video.page[0].width-rx;
/* block copy pattern to where we will draw the sprite */
vga_setup_wm1_block_copy();
o2 = gvar.video.page[0].pagesize;
/* block copy pattern to where we will draw the sprite */
vga_setup_wm1_block_copy();
o2 = gvar.video.page[0].pagesize;
for (i=0;i < h;i++,o += gvar.video.page[0].stridew,o2 += (w >> 2)) vga_wm1_mem_block_copy(o2,o,w >> 2);
/* must restore Write Mode 0/Read Mode 0 for this code to continue drawing normally */
vga_restore_rm0wm0();
for (i=0;i < h;i++,o += gvar.video.page[0].stridew,o2 += (w >> 2)) vga_wm1_mem_block_copy(o2,o,w >> 2);
/* must restore Write Mode 0/Read Mode 0 for this code to continue drawing normally */
vga_restore_rm0wm0();