]> 4ch.mooo.com Git - 16.git/commitdiff
showing row and colum drawing the fore loop in draw row is causing it to be slow...
authorsparky4 <sparky4@cock.li>
Thu, 26 Jan 2017 16:43:43 +0000 (10:43 -0600)
committersparky4 <sparky4@cock.li>
Thu, 26 Jan 2017 16:43:43 +0000 (10:43 -0600)
src/lib/16_tail.h
src/lib/scroll16.c
src/lib/scroll16.h

index a90d9ca749011459cb012a315f30307d6289ce13..932d557f56bcc74505a72ba412d754236056e298 100755 (executable)
@@ -44,7 +44,7 @@
        if(IN_KeyDown(sc_F9)){ pagenorendermap=!pagenorendermap;                                IN_UserInput(1,1); } \\r
        if(IN_KeyDown(sc_F7)){ ZC_ShowMV(&mv, 0, 1);                                                    IN_UserInput(1,1); } \\r
        if(IN_KeyDown(sc_F6)){ ZC_ShowMV(&mv, 0, 0);                                                    IN_UserInput(1,1); } \\r
-       if(IN_KeyDown(sc_F3)){ pagedelayrendermap=!pagedelayrendermap;                  IN_UserInput(1,1); } \\r
+       if(IN_KeyDown(sc_F5)){ pagedelayrendermap=!pagedelayrendermap;                  IN_UserInput(1,1); } \\r
        if(IN_KeyDown(sc_T)){ gvar.video.rss=!gvar.video.rss;                                           IN_UserInput(1,1); } \\r
        if(IN_KeyDown(sc_P)){ modexpdump(&gvar.video.page[0]);                                  IN_UserInput(1,1); }\r
 \r
index 0e2e847b0edacca87a7efbd9a4444cf6b28d7dd4..640db904f870a02db38d7fc732bbc11a7647f1fa 100755 (executable)
@@ -762,11 +762,10 @@ char global_temp_status_textC[512];
 void near mapDrawRow(map_view_t *mv, int tx, int ty, word y, player_t *player, word poopoffset)\r
 {\r
        int x, i;\r
-#ifdef SHOWDRAWRCREND\r
-       if(!y)  y+=TILEWH*2;\r
-       else    y-=TILEWH*2;\r
-//     printf("y: %d\n", y);\r
-#endif\r
+if(pagedelayrendermap)\r
+       if(!y)  y+=TILEWH;\r
+       else    y-=TILEWH;\r
+\r
        poopoffset%=player[0].enti.speed;\r
 //     printf("y: %d\n", poopoffset);\r
 //     sprintf(global_temp_status_textR, "y:%u", poopoffset); modexprint(mv[0].page, player[0].enti.x, player[0].enti.y-28, 1, 2, 1, global_temp_status_textR);\r
@@ -774,7 +773,7 @@ void near mapDrawRow(map_view_t *mv, int tx, int ty, word y, player_t *player, w
        i=ty * mv->map->width + tx;\r
        for(x=poopoffset; x<(mv->page->sw+mv->dxThresh)/(poopoffset+1) && tx < mv->map->width; x+=mv->map->tiles->tileWidth, tx++) {\r
                if(i>=0) {\r
-                       if(pagedelayrendermap) delay(400);\r
+                       if(pagedelayrendermap) delay(20);\r
                        /* we are in the map, so copy! */\r
                        mapDrawTile(mv->map->tiles, mv->map->data[i], mv->page, x, y);\r
                }\r
@@ -785,11 +784,10 @@ void near mapDrawRow(map_view_t *mv, int tx, int ty, word y, player_t *player, w
 void near mapDrawCol(map_view_t *mv, int tx, int ty, word x, player_t *player, word poopoffset)\r
 {\r
        int y, i;\r
-#ifdef SHOWDRAWRCREND\r
-       if(!x)  x+=TILEWH*2;\r
-       else    x-=TILEWH*2;\r
-//     printf("x: %d\n", x);\r
-#endif\r
+if(pagedelayrendermap)\r
+       if(!x)  x+=TILEWH;\r
+       else    x-=TILEWH;\r
+\r
        poopoffset%=player[0].enti.speed;\r
 //printf("x: %d\n", poopoffset);\r
 //     sprintf(global_temp_status_textR, "x:%u", poopoffset); modexprint(mv[0].page, player[0].enti.x, player[0].enti.y-28, 1, 2, 1, global_temp_status_textR);\r
@@ -800,7 +798,7 @@ void near mapDrawCol(map_view_t *mv, int tx, int ty, word x, player_t *player, w
           i + 1 row above and one below */\r
        for(y=poopoffset; y<(mv->page->sh+mv->dyThresh)/(poopoffset+1) && ty < mv->map->height; y+=mv->map->tiles->tileHeight, ty++) {\r
                if(i>=0) {\r
-                       if(pagedelayrendermap) delay(400);\r
+                       if(pagedelayrendermap) delay(20);\r
                        /* we are in the map, so copy away! */\r
                        mapDrawTile(mv->map->tiles, mv->map->data[i], mv->page, x, y);\r
                }\r
index 643c68f0fd55ec62b14018c163fb1d95f588160f..9c86327eadb6d9125128e4843a859813b4d11bfd 100755 (executable)
 #define PCXBMPPTR      PCXBMPVAR\r
 \r
 //row and colum drawing routines\r
-//#define FULLRCREND\r
-#define SHOWDRAWRCREND\r
-#define DRAWCOLNUM player[plid].enti.q//mv->page[0].dx\r
-#define DRAWROLNUM player[plid].enti.q//mv->page[0].dy\r
+#define FULLRCREND\r
+#define DRAWCOLNUM mv->page[0].dx\r
+#define DRAWROLNUM mv->page[0].dy\r
+//#define DRAWCOLNUM player[plid].enti.q\r
+//#define DRAWROLNUM player[plid].enti.q\r
 \r
 typedef struct {\r
        map_t *map;\r