#include <room_object.h>
Public Types | |
enum | LayerType { BG1 = 0 , BG2 = 1 , BG3 = 2 } |
Public Member Functions | |
RoomObject (int16_t id, uint8_t x, uint8_t y, uint8_t size, uint8_t layer=0) | |
void | set_rom (Rom *rom) |
auto | rom () |
auto | mutable_rom () |
void | AddTiles (int nbr, int pos) |
void | DrawTile (gfx::Tile16 t, int xx, int yy, std::vector< uint8_t > ¤t_gfx16, std::vector< uint8_t > &tiles_bg1_buffer, std::vector< uint8_t > &tiles_bg2_buffer, uint16_t tile_under=0xFFFF) |
auto | options () const |
void | set_options (ObjectOption options) |
Public Attributes | |
bool | all_bgs_ = false |
bool | lit_ = false |
int16_t | id_ |
uint8_t | x_ |
uint8_t | y_ |
uint8_t | size_ |
uint8_t | nx_ |
uint8_t | ny_ |
uint8_t | ox_ |
uint8_t | oy_ |
uint8_t | z_ = 0 |
uint8_t | previous_size_ = 0 |
int | width_ |
int | height_ |
int | offset_x_ = 0 |
int | offset_y_ = 0 |
std::string | name_ |
std::vector< uint8_t > | preview_object_data_ |
std::vector< gfx::Tile16 > | tiles_ |
LayerType | layer_ |
ObjectOption | options_ = ObjectOption::Nothing |
Rom * | rom_ |
Definition at line 57 of file room_object.h.
Enumerator | |
---|---|
BG1 | |
BG2 | |
BG3 |
Definition at line 59 of file room_object.h.
|
inline |
Definition at line 61 of file room_object.h.
References height_, id_, layer_, nx_, ny_, ox_, oy_, size_, width_, x_, and y_.
Referenced by yaze::zelda3::Subtype1::Subtype1(), yaze::zelda3::Subtype2::Subtype2(), and yaze::zelda3::Subtype3::Subtype3().
|
inline |
|
inline |
Definition at line 75 of file room_object.h.
References rom_.
Referenced by AddTiles(), set_rom(), yaze::zelda3::Subtype1::Subtype1(), yaze::zelda3::Subtype2::Subtype2(), and yaze::zelda3::Subtype3::Subtype3().
|
inline |
Definition at line 76 of file room_object.h.
References rom_.
|
inline |
Definition at line 78 of file room_object.h.
References ASSIGN_OR_LOG_ERROR, rom(), and tiles_.
Referenced by yaze::zelda3::Subtype1::Subtype1(), yaze::zelda3::Subtype2::Subtype2(), and yaze::zelda3::Subtype3::Subtype3().
void yaze::zelda3::RoomObject::DrawTile | ( | gfx::Tile16 | t, |
int | xx, | ||
int | yy, | ||
std::vector< uint8_t > & | current_gfx16, | ||
std::vector< uint8_t > & | tiles_bg1_buffer, | ||
std::vector< uint8_t > & | tiles_bg2_buffer, | ||
uint16_t | tile_under = 0xFFFF ) |
Definition at line 51 of file room_object.cc.
References all_bgs_, height_, yaze::gfx::TileInfo::horizontal_mirror_, yaze::gfx::TileInfo::id_, layer_, nx_, ny_, offset_x_, offset_y_, yaze::gfx::TileInfo::palette_, preview_object_data_, yaze::gfx::TileInfo::vertical_mirror_, and width_.
Referenced by yaze::zelda3::Subtype1::Draw(), yaze::zelda3::Subtype2::Draw(), and yaze::zelda3::Subtype3::Draw().
|
inline |
|
inline |
Definition at line 92 of file room_object.h.
References options(), and options_.
bool yaze::zelda3::RoomObject::all_bgs_ = false |
Definition at line 94 of file room_object.h.
Referenced by DrawTile().
bool yaze::zelda3::RoomObject::lit_ = false |
Definition at line 95 of file room_object.h.
int16_t yaze::zelda3::RoomObject::id_ |
Definition at line 97 of file room_object.h.
Referenced by RoomObject().
uint8_t yaze::zelda3::RoomObject::x_ |
Definition at line 98 of file room_object.h.
Referenced by yaze::zelda3::Subtype2::Draw(), yaze::zelda3::Subtype3::Draw(), and RoomObject().
uint8_t yaze::zelda3::RoomObject::y_ |
Definition at line 99 of file room_object.h.
Referenced by yaze::zelda3::Subtype2::Draw(), yaze::zelda3::Subtype3::Draw(), and RoomObject().
uint8_t yaze::zelda3::RoomObject::size_ |
Definition at line 100 of file room_object.h.
Referenced by yaze::zelda3::Subtype1::Draw(), and RoomObject().
uint8_t yaze::zelda3::RoomObject::nx_ |
Definition at line 101 of file room_object.h.
Referenced by DrawTile(), and RoomObject().
uint8_t yaze::zelda3::RoomObject::ny_ |
Definition at line 102 of file room_object.h.
Referenced by DrawTile(), and RoomObject().
uint8_t yaze::zelda3::RoomObject::ox_ |
Definition at line 103 of file room_object.h.
Referenced by RoomObject().
uint8_t yaze::zelda3::RoomObject::oy_ |
Definition at line 104 of file room_object.h.
Referenced by RoomObject().
uint8_t yaze::zelda3::RoomObject::z_ = 0 |
Definition at line 105 of file room_object.h.
uint8_t yaze::zelda3::RoomObject::previous_size_ = 0 |
Definition at line 106 of file room_object.h.
int yaze::zelda3::RoomObject::width_ |
Definition at line 108 of file room_object.h.
Referenced by DrawTile(), and RoomObject().
int yaze::zelda3::RoomObject::height_ |
Definition at line 109 of file room_object.h.
Referenced by DrawTile(), and RoomObject().
int yaze::zelda3::RoomObject::offset_x_ = 0 |
Definition at line 110 of file room_object.h.
Referenced by DrawTile().
int yaze::zelda3::RoomObject::offset_y_ = 0 |
Definition at line 111 of file room_object.h.
Referenced by DrawTile().
std::string yaze::zelda3::RoomObject::name_ |
Definition at line 113 of file room_object.h.
std::vector<uint8_t> yaze::zelda3::RoomObject::preview_object_data_ |
Definition at line 115 of file room_object.h.
Referenced by DrawTile().
std::vector<gfx::Tile16> yaze::zelda3::RoomObject::tiles_ |
Definition at line 116 of file room_object.h.
Referenced by AddTiles(), yaze::zelda3::Subtype1::Draw(), yaze::zelda3::Subtype2::Draw(), and yaze::zelda3::Subtype3::Draw().
LayerType yaze::zelda3::RoomObject::layer_ |
Definition at line 118 of file room_object.h.
Referenced by DrawTile(), and RoomObject().
ObjectOption yaze::zelda3::RoomObject::options_ = ObjectOption::Nothing |
Definition at line 119 of file room_object.h.
Referenced by options(), and set_options().
Rom* yaze::zelda3::RoomObject::rom_ |
Definition at line 121 of file room_object.h.
Referenced by mutable_rom(), rom(), and set_rom().