#include <player.h>
Public Member Functions | |
Player () | |
~Player () | |
void | set_screen (Screen &s) |
void | set_paul_info (paul_info *p) |
void | move (int dir) |
void | unmove (int dir) |
void | redraw () |
void | static_redraw (int dir) |
void | static_redraw_cycle (int dir) |
void | overlay () |
void | update () |
Private Attributes | |
Screen | screen |
paul_info * | pinfo |
int | num_frames_phase |
int | num_frames_action |
int | frame_dir |
int | phase |
int | undo_move_x |
int | undo_move_y |
Definition at line 45 of file player.h.
Player::Player | ( | ) |
Definition at line 31 of file player.cpp.
References frame_dir, num_frames_action, num_frames_phase, and phase.
Player::~Player | ( | ) |
Definition at line 38 of file player.cpp.
void Player::set_screen | ( | Screen & | s | ) |
void Player::set_paul_info | ( | paul_info * | p | ) |
Reimplemented from FGEntity.
Definition at line 45 of file player.cpp.
References pinfo.
Referenced by main().
void Player::move | ( | int | dir | ) |
Definition at line 56 of file player.cpp.
References FGEntity::current_frame, paul_info::direction, paul_info::map_ax, paul_info::map_ay, paul_info::map_height, paul_info::map_width, MOVE_PER_FRAME, paul_info::paul_ax, paul_info::paul_ay, pinfo, redraw(), paul_info::tilesize, undo_move_x, undo_move_y, paul_info::win_height, and paul_info::win_width.
Referenced by FGEntityList::test().
void Player::unmove | ( | int | dir | ) |
Definition at line 99 of file player.cpp.
References paul_info::map_ax, paul_info::map_ay, paul_info::paul_ax, paul_info::paul_ay, pinfo, redraw(), paul_info::tilesize, undo_move_x, undo_move_y, paul_info::win_height, and paul_info::win_width.
void Player::redraw | ( | ) |
Definition at line 107 of file player.cpp.
References Screen::blit(), FGEntity::current_frame, paul_info::direction, frame_dir, makerect(), num_frames_action, paul_info::paul_x, paul_info::paul_y, pinfo, screen, Tiledata::tile, FGEntity::tiledata, and paul_info::tilesize.
void Player::static_redraw | ( | int | dir | ) |
Definition at line 115 of file player.cpp.
References Screen::blit(), FGEntity::current_frame, paul_info::direction, makerect(), num_frames_action, paul_info::paul_x, paul_info::paul_y, pinfo, screen, Tiledata::tile, FGEntity::tiledata, and paul_info::tilesize.
Referenced by FGEntityList::test().
void Player::static_redraw_cycle | ( | int | dir | ) |
Definition at line 123 of file player.cpp.
References Screen::blit(), FGEntity::current_frame, paul_info::direction, frame_dir, makerect(), num_frames_action, paul_info::paul_x, paul_info::paul_y, pinfo, screen, Tiledata::tile, FGEntity::tiledata, and paul_info::tilesize.
Referenced by FGEntityList::test().
void Player::overlay | ( | ) |
Definition at line 134 of file player.cpp.
References Screen::blit(), FGEntity::current_frame, paul_info::direction, makerect(), num_frames_action, paul_info::paul_x, paul_info::paul_y, pinfo, screen, Tiledata::tile, FGEntity::tiledata, and paul_info::tilesize.
Referenced by FGEntityList::test().
void Player::update | ( | ) | [virtual] |
Implements FGEntity.
Definition at line 49 of file player.cpp.
References FGEntity::box, FGEntity::current_box, FGEntity::onscreen, paul_info::paul_ax, paul_info::paul_ay, pinfo, and PLAYER_DEBUG.
Referenced by FGEntityList::test().
Screen Player::screen [private] |
Definition at line 47 of file player.h.
Referenced by overlay(), redraw(), set_screen(), static_redraw(), and static_redraw_cycle().
paul_info* Player::pinfo [private] |
Reimplemented from FGEntity.
Definition at line 48 of file player.h.
Referenced by move(), overlay(), redraw(), set_paul_info(), static_redraw(), static_redraw_cycle(), unmove(), and update().
int Player::num_frames_phase [private] |
int Player::num_frames_action [private] |
Definition at line 51 of file player.h.
Referenced by overlay(), Player(), redraw(), static_redraw(), and static_redraw_cycle().
int Player::frame_dir [private] |
Definition at line 52 of file player.h.
Referenced by Player(), redraw(), and static_redraw_cycle().
int Player::phase [private] |
int Player::undo_move_x [private] |
int Player::undo_move_y [private] |