word stridew; /* width/4 */ /* VGA */\r
word pagesize; /* page size */\r
word pi; /* increment page by this much to preserve location */\r
+ int tlx,tly;\r
//newer vars\r
//TODO: find where they are used\r
sword delta; // How much should we shift the page for smooth scrolling\r
-Subproject commit 667d71906b174472d4a2432c5c5c0d7167187be8
+Subproject commit 757ace2b7f7887731a0b7aaf00306b6682fe5fac
/* sync */\r
void shinku(global_game_variables_t *gv)\r
{\r
- word x = (0) + gv->video.page[/*!*/(gv->video.p)].dx; // follow the screen\r
- word y = (0) + gv->video.page[/*!*/(gv->video.p)].dy; // follow the screen\r
+ word x = gv->video.page[/*!*/(gv->video.p)].dx - (gv->video.page[(gv->video.p)].tlx); // follow the screen\r
+ word y = gv->video.page[/*!*/(gv->video.p)].dy - (gv->video.page[(gv->video.p)].tly); // follow the screen\r
word col = 2, bgcol = 1, type = 1;//w = 64, h = 8,\r
if(elapsed_timer(gv) >= (1.0 / gv->kurokku.frames_per_second))\r
{\r
}\r
\r
// while(!IN_KeyDown(sc_Escape) && !IN_KeyDown(sc_Space) && !IN_KeyDown(sc_Enter)){ FUNCTIONKEYSHOWMV }\r
+ gvar.video.page[0].tlx=mv[0].tx*TILEWH;\r
+ gvar.video.page[0].tly=mv[0].ty*TILEWH;\r
shinku(&gvar);\r
#ifdef FADE\r
modexFadeOn(4, gpal);\r
#endif\r
while(!IN_KeyDown(sc_Escape) && player[0].enti.hp>0)\r
{\r
+ gvar.video.page[0].tlx=mv[0].tx*TILEWH;\r
+ gvar.video.page[0].tly=mv[0].ty*TILEWH;\r
shinku(&gvar);\r
//top left corner & bottem right corner of map veiw be set as map edge trigger since maps are actually square\r
//to stop scrolling and have the player position data move to the edge of the screen with respect to the direction\r