src/Player.hh
branchnew_graphics
changeset 417 c503e0c6a740
parent 414 cede5463b845
equal deleted inserted replaced
416:38cba347a3a9 417:c503e0c6a740
   150     /**
   150     /**
   151      * Increment player killcounter by one.
   151      * Increment player killcounter by one.
   152      */
   152      */
   153     void addKill ();
   153     void addKill ();
   154 
   154 
       
   155 #if GRAPHICS_ENABLED    
   155     /*
   156     /*
   156      * Drawing requires the skin texture, which is loaded on-demand when draw is called
   157      * Drawing requires the skin texture, which is loaded on-demand when draw is called
   157      */
   158      */
   158     static bool skin_loaded;
   159     static bool skin_loaded;
   159     static CL_Surface skin_surface;
   160     static CL_Surface skin_surface;
   160 
   161 
   161     /**
   162     /**
   162      * Draw this player
   163      * Draw this player
   163      */
   164      */
   164     virtual void draw (graphics::Display &display, PixelCoordinate camera);
   165     virtual void draw (graphics::Display &display, PixelCoordinate camera);
   165     
   166 #endif
       
   167 
   166     /**
   168     /**
   167      * Returns statistics on the number of kills for this player
   169      * Returns statistics on the number of kills for this player
   168      */
   170      */
   169     uint16_t getKills() { return kills; }
   171     uint16_t getKills() { return kills; }
   170 
   172 
   198      *
   200      *
   199      * NetworkClientLocalPlayer overrides this to send the input to the server, which then handles it
   201      * NetworkClientLocalPlayer overrides this to send the input to the server, which then handles it
   200      */
   202      */
   201     virtual void handleInput (PlayerInput input, TimeMS dt);
   203     virtual void handleInput (PlayerInput input, TimeMS dt);
   202         
   204         
       
   205 #if GRAPHICS_ENABLED    
   203     /**
   206     /**
   204      * As Player, but also draws the current weapon name if displayWeapon
   207      * As Player, but also draws the current weapon name if displayWeapon
   205      */
   208      */
   206     virtual void draw (graphics::Display &display, bool displayWeapon, PixelCoordinate camera);
   209     virtual void draw (graphics::Display &display, bool displayWeapon, PixelCoordinate camera);
       
   210 #endif    
   207 };
   211 };
   208 
   212 
   209 /**
   213 /**
   210  * A RemotePlayer is a Player that we don't handle input for - they are a remote client connected to a remote server.
   214  * A RemotePlayer is a Player that we don't handle input for - they are a remote client connected to a remote server.
   211  *
   215  *