ScummVM API documentation
Ultima::Nuvie::ObjManager Class Reference

Public Member Functions

 ObjManager (const Configuration *cfg, TileManager *tm, EggManager *em)
 
bool use_custom_actor_tiles ()
 
bool is_showing_eggs ()
 
void set_show_eggs (bool value)
 
bool loadObjs ()
 
bool load_super_chunk (NuvieIO *chunk_buf, uint8 level, uint8 chunk_offset)
 
void startObjs ()
 
void clean ()
 
void clean_actor_inventories ()
 
bool save_super_chunk (NuvieIO *save_buf, uint8 level, uint8 chunk_offset)
 
bool save_eggs (NuvieIO *save_buf)
 
bool save_inventories (NuvieIO *save_buf)
 
bool save_obj (NuvieIO *save_buf, Obj *obj, uint16 parent_objblk_n)
 
void set_usecode (UseCode *uc)
 
UseCodeget_usecode ()
 
EggManagerget_egg_manager ()
 
bool is_boundary (uint16 x, uint16 y, uint8 level, uint8 boundary_type=TILEFLAG_BOUNDARY, Obj *excluded_obj=nullptr)
 
bool is_damaging (uint16 x, uint16 y, uint8 level)
 
uint8 is_passable (uint16 x, uint16 y, uint8 level)
 
bool is_forced_passable (uint16 x, uint16 y, uint8 level)
 
bool is_stackable (const Obj *obj) const
 
bool is_breakable (const Obj *obj)
 
bool can_store_obj (const Obj *target, Obj *src) const
 
bool can_get_obj (Obj *obj) const
 
bool has_reduced_weight (uint16 obj_n) const
 
bool has_reduced_weight (const Obj *obj) const
 
bool has_toptile (const Obj *obj) const
 
bool obj_is_damaging (const Obj *obj, Actor *actor=nullptr)
 
bool is_door (uint16 x, uint16 y, uint8 level)
 
U6LListget_obj_list (uint16 x, uint16 y, uint8 level) const
 
Tileget_obj_tile (uint16 obj_n, uint8 frame_n)
 
const Tileget_obj_tile (uint16 x, uint16 y, uint8 level, bool top_obj=true)
 
const Tileget_obj_dmg_tile (uint16 x, uint16 y, uint8 level)
 
Objget_obj (uint16 x, uint16 y, uint8 level, bool top_obj=true, bool include_ignored_objects=false, Obj *excluded_obj=nullptr)
 
Objget_obj_of_type_from_location_inc_multi_tile (uint16 obj_n, uint16 x, uint16 y, uint8 z)
 
Objget_obj_of_type_from_location_inc_multi_tile (uint16 obj_n, sint16 quality, sint32 qty, uint16 x, uint16 y, uint8 z)
 
Objget_obj_of_type_from_location (uint16 obj_n, uint16 x, uint16 y, uint8 z)
 
Objget_obj_of_type_from_location (uint16 obj_n, sint16 quality, sint32 qty, uint16 x, uint16 y, uint8 z)
 
Objget_objBasedAt (uint16 x, uint16 y, uint8 level, bool top_obj, bool include_ignored_objects=true, Obj *excluded_obj=nullptr)
 
Objget_tile_obj (uint16 obj_n)
 
uint16 get_obj_tile_num (uint16 obj_num) const
 
bool is_corpse (const Obj *obj) const
 
uint16 get_obj_tile_num (const Obj *obj) const
 
void set_obj_tile_num (uint16 obj_num, uint16 tile_num)
 
U6LListget_actor_inventory (uint16 actor_num)
 
bool actor_has_inventory (uint16 actor_num)
 
Objfind_next_obj (uint8 level, Obj *prev_obj, bool match_frame_n=OBJ_NOMATCH_FRAME_N, bool match_quality=OBJ_MATCH_QUALITY)
 
Objfind_obj (uint8 level, uint16 obj_n, uint8 quality, bool match_quality=OBJ_MATCH_QUALITY, uint16 frame_n=0, bool match_frame_n=OBJ_NOMATCH_FRAME_N, Obj **prev_obj=nullptr)
 
bool move (Obj *obj, uint16 x, uint16 y, uint8 level)
 
bool add_obj (Obj *obj, bool addOnTop=false)
 
bool remove_obj_from_map (Obj *obj)
 
bool remove_obj_type_from_location (uint16 obj_n, uint16 x, uint16 y, uint8 z)
 
Objcopy_obj (const Obj *obj)
 
const char * look_obj (Obj *obj, bool show_prefix=false)
 
Objget_obj_from_stack (Obj *obj, uint32 count)
 
bool list_add_obj (U6LList *list, Obj *obj, bool stack_objects=true, uint32 pos=0)
 
const char * get_obj_name (Obj *obj)
 
const char * get_obj_name (uint16 obj_n)
 
const char * get_obj_name (uint16 obj_n, uint8 frame_n)
 
float get_obj_weight (const Obj *obj, bool include_container_items=true, bool scale=true, bool include_qty=true) const
 
uint8 get_obj_weight_unscaled (uint16 obj_n) const
 
float get_obj_weight (uint16 obj_n) const
 
void animate_forwards (Obj *obj, uint32 loop_count=1)
 
void animate_backwards (Obj *obj, uint32 loop_count=1)
 
void update (uint16 x, uint16 y, uint8 z, bool teleport=false)
 
bool unlink_from_engine (Obj *obj, bool run_usecode=true)
 
bool moveto_map (Obj *obj, MapCoord location)
 
bool moveto_inventory (Obj *obj, uint16 actor_num)
 
bool moveto_inventory (Obj *obj, Actor *actor)
 
bool moveto_container (Obj *obj, Obj *container_obj, bool stack=true)
 
void print_object_list ()
 
void print_egg_list ()
 
void print_obj (const Obj *obj, bool in_container, uint8 indent=0)
 

Protected Member Functions

void remove_obj (Obj *obj)
 
bool load_basetile ()
 
bool load_weight_table ()
 
bool addObjToContainer (U6LList *list, Obj *obj)
 
ObjloadObj (NuvieIO *buf)
 
iAVLTreeget_obj_tree (uint16 x, uint16 y, uint8 level) const
 
iAVLKey get_obj_tree_key (Obj *obj) const
 
iAVLKey get_obj_tree_key (uint16 x, uint16 y, uint8 level) const
 
bool temp_obj_list_add (Obj *obj)
 
bool temp_obj_list_remove (Obj *obj)
 
void temp_obj_list_clean_level (uint8 z)
 
void temp_obj_list_clean_area (uint16 x, uint16 y)
 
void remove_temp_obj (Obj *tmp_obj)
 
Objfind_obj_in_tree (uint16 obj_n, uint8 quality, bool match_quality, uint8 frame_n, bool match_frame_n, Obj **prev_obj, iAVLTree *obj_tree)
 
void start_obj_usecode (iAVLTree *obj_tree)
 
void print_egg_tree (iAVLTree *obj_tree)
 

The documentation for this class was generated from the following file: