home · contact · privacy
Client: Drop now redundant map centering systems.
[plomrogue] / src / client / map.c
index 75dd6dee5a6571ec6e5d89a694964628a03b04bf..f8ff0616bc502d683fc63d8d96bc15ab0b69eef3 100644 (file)
@@ -12,7 +12,7 @@
 #include <string.h> /* strlen(), strncmp() */
 #include "../common/try_malloc.h" /* try_malloc() */
 #include "../common/rexit.h" /* exit_trouble() */
-#include "../common/yx_uint8.h" /* yx_uint8 */
+//#include "../common/yx_uint8.h" /* yx_uint8 */
 #include "io.h" /* send() */
 #include "windows.h" /* struct Win, center_offset(), get_win_by_id() */
 #include "world.h" /* for global world */
@@ -21,7 +21,6 @@
 
 extern void map_scroll(char d)
 {
-    world.autofocus = 0;
     struct Win * win = get_win_by_id('m');
     uint16_t offset;
     if (('8' == d || '2' == d) && world.map.length > win->frame_size.y)
@@ -52,23 +51,6 @@ extern void map_scroll(char d)
 
 
 
-extern void map_center()
-{
-    struct Win * win_map = get_win_by_id('m');
-    struct yx_uint8 pos = world.look ? world.look_pos : world.player_pos;
-    win_map->center.y = pos.y;
-    win_map->center.x = pos.x * 2 + (pos.y % 2);
-}
-
-
-
-extern void toggle_autofocus()
-{
-    world.autofocus = world.autofocus ? 0 : 1;
-}
-
-
-
 extern void toggle_lookmode()
 {
     if (!world.look)
@@ -128,7 +110,6 @@ extern uint8_t lookmode_nav(char * command)
         {
             return 0;
         }
-        map_center();
         query_mapcell();
         return 1;
     }