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