1 /************************************************************** 2 * _____ __ _____ * 3 * / _ \ | | ____ ___ ___ / | | * 4 * / /_\ \ | | _/ __ \ \ \/ / / | |_ * 5 * / | \| |__\ ___/ > < / ^ / * 6 * \____|__ /|____/ \___ >/__/\_ \ \____ | * 7 * \/ \/ \/ |__| * 8 * * 9 ************************************************************** 10 * (c) Free Lunch Design 2003 * 11 * Written by Johan Peitz * 12 * http://www.freelunchdesign.com * 13 ************************************************************** 14 * This source code is released under the The GNU * 15 * General Public License (GPL). Please refer to the * 16 * document license.txt in the source directory or * 17 * http://www.gnu.org for license information. * 18 **************************************************************/ 19 20 21 22 #ifndef _PLAYER_H_ 23 #define _PLAYER_H_ 24 25 #include "actor.h" 26 27 28 // struct for the player 29 typedef struct { 30 Tactor *actor; 31 32 int score; 33 int jumping; 34 int jump_pressed; 35 int eat_pressed; 36 int eat_counter; 37 38 int angle; 39 40 int ammo; 41 int lives; 42 int health; 43 int wounded; 44 45 int dy; 46 47 // pick up related 48 int cherries; 49 int stars; 50 int cherries_taken; 51 int stars_taken; 52 } Tplayer; 53 54 55 // the player 56 Tplayer player; 57 58 // functions 59 void draw_player(BITMAP *bmp, Tplayer *p, int x, int y); 60 void wound_player(Tplayer *p); 61 void kill_player(Tplayer *p); 62 63 #endif