]>
git.gir.st - VIper.git/blob - viiper.h
4 #define SHORTHELP "%s [OPTIONS] [FIELDSIZE]\n"
12 " WxH (width 'x' height)\n" \
13 " defaults to 30x20\n" \
16 " hjkl: move left/down/up/right\n" \
17 " p: pause / unpause\n" \
18 " r: start a new game\n" \
24 struct snake
* next
; /* points to tail */
31 int s
; /* spawn time (for bonus) */
70 void snake_advance (void);
71 void spawn_item (int type
, int value
, struct item
* p_item
);
72 void consume_item (struct item
* i
);
73 void show_playfield (void);
74 void draw_sprites (int erase_r
, int erase_c
);
75 void pause_game (void);
76 int end_screen(char* message
);
77 void snake_append (struct snake
** s
, int row
, int col
);
78 void remove_bonus (struct item
* i
);
81 int getctrlseq (void);
82 void append_movement (int d
);
83 void move_ph (int line
, int col
);
84 void clamp_fieldsize (void);
85 void timer_setup (int enable
);
86 void signal_setup (void);
87 void signal_handler (int signum
);
88 void screen_setup (int enable
);
89 void raw_mode(int enable
);
91 /* for getctrlseq() */
96 CTRSEQ_CURSOR_LEFT
= -7,
97 CTRSEQ_CURSOR_DOWN
= -8,
98 CTRSEQ_CURSOR_UP
= -9,
99 CTRSEQ_CURSOR_RIGHT
= -10,