Pol  Rev 533
Realm Class Reference

#include <realm.h>

+ Collaboration diagram for Realm:

List of all members.

Public Member Functions

 Realm (const std::string &realm_name, const std::string &realm_path="")
 Realm (const std::string &realm_name, Realm *realm)
 ~Realm ()
RealmDescriptor _Descriptor () const
bool dropheight (unsigned short dropx, unsigned short dropy, short dropz, short chrz, short *newz, UMulti **pmulti)
unsigned int encode_global_hull (unsigned short ax, unsigned short ay)
UMultifind_supporting_multi (unsigned short x, unsigned short y, short z)
bool findstatic (unsigned short x, unsigned short y, unsigned short objtype) const
void getmapshapes (MapShapeList &shapes, unsigned short x, unsigned short y, unsigned int anyflags) const
MAPTILE_CELL getmaptile (unsigned short x, unsigned short y) const
unsigned getNumMapPatches ()
unsigned getNumStaticPatches ()
void getstatics (StaticEntryList &statics, unsigned short x, unsigned short y) const
unsigned getUOMapID ()
bool groundheight (unsigned short x, unsigned short y, short *z) const
bool has_los (const LosObj &att, const LosObj &tgt) const
bool has_los (const UObject &iatt, const UObject &itgt) const
bool has_los (const Character &iatt, const UObject &itgt) const
unsigned short height () const
bool lowest_standheight (unsigned short x, unsigned short y, short *z) const
bool lowest_walkheight (unsigned short x, unsigned short y, short oldz, short *newz, UMulti **pmulti, Item **pwalkon, bool doors_block, MOVEMODE movemode, short *gradual_boost=NULL)
const std::string name () const
bool navigable (unsigned short x, unsigned short y, short z, short height) const
void readmultis (MapShapeList &vec, unsigned short x, unsigned short y, unsigned int flags) const
void readmultis (MapShapeList &vec, unsigned short x, unsigned short y, unsigned int flags, MultiList &mvec)
void readmultis (StaticList &vec, unsigned short x, unsigned short y) const
unsigned season () const
bool valid (unsigned short x, unsigned short y, short z) const
bool walkheight (unsigned short x, unsigned short y, short oldz, short *newz, UMulti **pmulti, Item **pwalkon, bool doors_block, MOVEMODE movemode, short *gradual_boost=NULL)
bool walkheight (const Character *chr, unsigned short x, unsigned short y, short oldz, short *newz, UMulti **pmulti, Item **pwalkon, short *gradual_boost=NULL)
unsigned short width () const

Public Attributes

auto_ptr< MapServer_mapserver
auto_ptr< MapTileServer_maptileserver
auto_ptr< StaticServer_staticserver
Realmbaserealm
set< unsigned int > global_hulls
bool is_shadowrealm
unsigned int mobile_count
unsigned int shadowid
const std::string shadowname
unsigned int toplevel_item_count
Zone ** zone

Protected Member Functions

bool dropheight (MapShapeList &shapes, short dropz, short chrz, short *newz) const
bool dynamic_item_blocks_los (const LosObj &att, const LosObj &target, unsigned short x, unsigned short y, short z) const
UMultifind_supporting_multi (MultiList &mvec, short z)
bool los_blocked (const LosObj &att, const LosObj &target, unsigned short x, unsigned short y, short z) const
void lowest_standheight (MOVEMODE movemode, MapShapeList &shapes, short oldz, bool *result, short *newz, short *gradual_boost=NULL) const
void readdynamics (MapShapeList &vec, unsigned short x, unsigned short y, Items &walkon_items, bool doors_block)
void standheight (MOVEMODE movemode, MapShapeList &shapes, short oldz, bool *result, short *newz, short *gradual_boost=NULL) const
bool static_item_blocks_los (unsigned short x, unsigned short y, short z) const

Private Member Functions

 Realm (const Realm &)
Realmoperator= (const Realm &)

Private Attributes

RealmDescriptor _descriptor

Detailed Description

Definition at line 37 of file realm.h.


Constructor & Destructor Documentation

Realm::Realm ( const std::string &  realm_name,
const std::string &  realm_path = "" 
) [explicit]

Definition at line 22 of file realm.cpp.

References height(), WGRID_SIZE, width(), and zone.

+ Here is the call graph for this function:

Realm::Realm ( const std::string &  realm_name,
Realm realm 
) [explicit]

Definition at line 47 of file realm.cpp.

References height(), WGRID_SIZE, width(), and zone.

+ Here is the call graph for this function:

Definition at line 70 of file realm.cpp.

References WGRID_SIZE, width(), and zone.

+ Here is the call graph for this function:

Realm::Realm ( const Realm ) [private]

Member Function Documentation

RealmDescriptor Realm::_Descriptor ( ) const [inline]

Definition at line 155 of file realm.h.

References _descriptor, _Descriptor(), baserealm, and is_shadowrealm.

Referenced by _Descriptor(), dropheight(), getNumMapPatches(), getNumStaticPatches(), getUOMapID(), height(), lowest_walkheight(), season(), valid(), walkheight(), and width().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

bool Realm::dropheight ( unsigned short  dropx,
unsigned short  dropy,
short  dropz,
short  chrz,
short *  newz,
UMulti **  pmulti 
)

Definition at line 509 of file realmfunc.cpp.

References _Descriptor(), FLAG::DROP_FLAGS, find_supporting_multi(), getmapshapes(), height(), readdynamics(), readmultis(), and width().

Referenced by drop_item_on_ground(), and test_drop().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

bool Realm::dropheight ( MapShapeList shapes,
short  dropz,
short  chrz,
short *  newz 
) const [protected]

Definition at line 549 of file realmfunc.cpp.

References FLAG::ALLOWDROPON, FLAG::BLOCKING, MapShape::flags, MapShape::height, PLAYER_CHARACTER_HEIGHT, static_debug_on, tileheight(), and MapShape::z.

+ Here is the call graph for this function:

bool Realm::dynamic_item_blocks_los ( const LosObj att,
const LosObj target,
unsigned short  x,
unsigned short  y,
short  z 
) const [protected]

Definition at line 58 of file realmlos.cpp.

References FLAG::BLOCKSIGHT, Item::description(), getzone(), UObject::graphic, UObject::height, Zone::items, LosObj::serial, UObject::serial, tile_flags(), UObject::x, UObject::y, and UObject::z.

Referenced by los_blocked().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

unsigned int Realm::encode_global_hull ( unsigned short  ax,
unsigned short  ay 
) [inline]

Definition at line 106 of file realm.h.

Referenced by UBoat::navigable(), UBoat::regself(), and UBoat::unregself().

+ Here is the caller graph for this function:

UMulti * Realm::find_supporting_multi ( unsigned short  x,
unsigned short  y,
short  z 
)

Definition at line 755 of file realmfunc.cpp.

References FLAG::MOVE_FLAGS, readmultis(), and valid().

Referenced by decay_worldzone(), dropheight(), UObject::get_script_member_id(), handle_coord_cursor(), lowest_walkheight(), UOExecutorModule::mf_SendHousingTool(), register_with_supporting_multi(), and walkheight().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

UMulti * Realm::find_supporting_multi ( MultiList mvec,
short  z 
) [protected]

Definition at line 774 of file realmfunc.cpp.

References UObject::z.

bool Realm::findstatic ( unsigned short  x,
unsigned short  y,
unsigned short  objtype 
) const

Definition at line 792 of file realmfunc.cpp.

References _staticserver, baserealm, and is_shadowrealm.

Referenced by ResourceDef::findmarker().

+ Here is the caller graph for this function:

void Realm::getmapshapes ( MapShapeList shapes,
unsigned short  x,
unsigned short  y,
unsigned int  anyflags 
) const

Definition at line 828 of file realmfunc.cpp.

References _mapserver, baserealm, and is_shadowrealm.

Referenced by dropheight(), lowest_standheight(), lowest_walkheight(), UOExecutorModule::mf_GetStandingLayers(), navigable(), static_item_blocks_los(), and walkheight().

+ Here is the caller graph for this function:

MAPTILE_CELL Realm::getmaptile ( unsigned short  x,
unsigned short  y 
) const

Definition at line 820 of file realmfunc.cpp.

References _maptileserver, baserealm, and is_shadowrealm.

Referenced by ResourceDef::findmarker(), map_test(), and UOExecutorModule::mf_GetMapInfo().

+ Here is the caller graph for this function:

unsigned Realm::getNumMapPatches ( ) [inline]

Definition at line 105 of file realm.h.

References _Descriptor(), and RealmDescriptor::num_map_patches.

+ Here is the call graph for this function:

unsigned Realm::getNumStaticPatches ( ) [inline]

Definition at line 104 of file realm.h.

References _Descriptor(), and RealmDescriptor::num_static_patches.

+ Here is the call graph for this function:

void Realm::getstatics ( StaticEntryList statics,
unsigned short  x,
unsigned short  y 
) const
unsigned Realm::getUOMapID ( ) [inline]

Definition at line 103 of file realm.h.

References _Descriptor(), and RealmDescriptor::uomapid.

Referenced by send_realm_change(), and SetupRealmDetails().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

bool Realm::groundheight ( unsigned short  x,
unsigned short  y,
short *  z 
) const

Definition at line 808 of file realmfunc.cpp.

References _maptileserver, FLAG::BLOCKING, GRAPHIC_NODRAW, MAPTILE_CELL::landtile, landtile_flags(), and MAPTILE_CELL::z.

Referenced by move_to_ground().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

bool Realm::has_los ( const UObject iatt,
const UObject itgt 
) const

Definition at line 15 of file realmlos2.cpp.

References UObject::CLASS_CHARACTER, has_los(), Character::ignores_line_of_sight(), UObject::isa(), and UObject::realm.

+ Here is the call graph for this function:

bool Realm::has_los ( const Character iatt,
const UObject itgt 
) const

Definition at line 32 of file realmlos2.cpp.

References has_los(), Character::ignores_line_of_sight(), UObject::realm, Character::search_remote_containers(), and UObject::serial.

+ Here is the call graph for this function:

bool Realm::los_blocked ( const LosObj att,
const LosObj target,
unsigned short  x,
unsigned short  y,
short  z 
) const [protected]

Definition at line 129 of file realmlos.cpp.

References dynamic_item_blocks_los(), LosObj::obj_height, static_item_blocks_los(), LosObj::x, LosObj::y, and LosObj::z.

Referenced by has_los().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

bool Realm::lowest_standheight ( unsigned short  x,
unsigned short  y,
short *  z 
) const

Definition at line 45 of file realmfunc.cpp.

References FLAG::BLOCKING, getmapshapes(), FLAG::GRADUAL, FLAG::MOVELAND, MOVEMODE_LAND, and FLAG::MOVESEA.

Referenced by lowest_walkheight(), and UOExecutorModule::mf_GetWorldHeight().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void Realm::lowest_standheight ( MOVEMODE  movemode,
MapShapeList shapes,
short  oldz,
bool *  result,
short *  newz,
short *  gradual_boost = NULL 
) const [protected]
bool Realm::lowest_walkheight ( unsigned short  x,
unsigned short  y,
short  oldz,
short *  newz,
UMulti **  pmulti,
Item **  pwalkon,
bool  doors_block,
MOVEMODE  movemode,
short *  gradual_boost = NULL 
)

Definition at line 452 of file realmfunc.cpp.

References _Descriptor(), find_supporting_multi(), find_walkon_item(), getmapshapes(), height(), lowest_standheight(), FLAG::MOVE_FLAGS, MOVEMODE_FLY, FLAG::OVERFLIGHT, readdynamics(), readmultis(), and width().

Referenced by UOExecutorModule::mf_GetStandingHeight().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

bool Realm::navigable ( unsigned short  x,
unsigned short  y,
short  z,
short  height = 0 
) const

Definition at line 720 of file realmfunc.cpp.

References FLAG::ALL, MapShape::flags, getmapshapes(), MapShape::height, height(), HULL_HEIGHT_BUFFER, FLAG::MOVESEA, valid(), and MapShape::z.

Referenced by UBoat::navigable().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Realm& Realm::operator= ( const Realm ) [private]
void Realm::readdynamics ( MapShapeList vec,
unsigned short  x,
unsigned short  y,
Items walkon_items,
bool  doors_block 
) [protected]
void Realm::readmultis ( MapShapeList vec,
unsigned short  x,
unsigned short  y,
unsigned int  flags,
MultiList mvec 
)
void Realm::readmultis ( StaticList vec,
unsigned short  x,
unsigned short  y 
) const
unsigned Realm::season ( ) const

Definition at line 93 of file realm.cpp.

References _Descriptor(), and RealmDescriptor::season.

Referenced by send_season_info(), and SetupRealmDetails().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void Realm::standheight ( MOVEMODE  movemode,
MapShapeList shapes,
short  oldz,
bool *  result,
short *  newz,
short *  gradual_boost = NULL 
) const [protected]
bool Realm::static_item_blocks_los ( unsigned short  x,
unsigned short  y,
short  z 
) const [protected]

Definition at line 90 of file realmlos.cpp.

References FLAG::BLOCKSIGHT, getmapshapes(), MapShape::height, hexint(), readmultis(), tile_flags(), and MapShape::z.

Referenced by los_blocked().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

bool Realm::valid ( unsigned short  x,
unsigned short  y,
short  z 
) const

Definition at line 98 of file realm.cpp.

References _Descriptor(), height(), and width().

Referenced by BPacket::call_method_id(), find_supporting_multi(), UOExecutorModule::internal_MoveItem(), lowest_standheight(), UOExecutorModule::mf_AssignRectToWeatherRegion(), UOExecutorModule::mf_CheckLosAt(), UOExecutorModule::mf_CheckLosBetween(), UOExecutorModule::mf_CreateItemAtLocation(), UOExecutorModule::mf_CreateItemCopyAtLocation(), UOExecutorModule::mf_CreateMultiAtLocation(), UOExecutorModule::mf_CreateNpcFromTemplate(), UOExecutorModule::mf_FindPath(), UOExecutorModule::mf_GetHarvestDifficulty(), UOExecutorModule::mf_GetMapInfo(), UOExecutorModule::mf_GetRegionLightLevelAtLocation(), UOExecutorModule::mf_GetRegionNameAtLocation(), UOExecutorModule::mf_GetRegionString(), UOExecutorModule::mf_GetStandingHeight(), UOExecutorModule::mf_GetStandingLayers(), UOExecutorModule::mf_GetWorldHeight(), UOExecutorModule::mf_HarvestResource(), UOExecutorModule::mf_ListItemsAtLocation(), UOExecutorModule::mf_ListItemsNearLocation(), UOExecutorModule::mf_ListItemsNearLocationOfType(), UOExecutorModule::mf_ListItemsNearLocationWithFlag(), UOExecutorModule::mf_ListMobilesNearLocation(), UOExecutorModule::mf_ListMobilesNearLocationEx(), UOExecutorModule::mf_ListStaticsAtLocation(), UOExecutorModule::mf_ListStaticsNearLocation(), UOExecutorModule::mf_MoveObjectToLocation(), UOExecutorModule::mf_PlayMovingEffectXyz(), UOExecutorModule::mf_PlayMovingEffectXyz_Ex(), UOExecutorModule::mf_PlaySoundEffectXYZ(), UOExecutorModule::mf_PlayStationaryEffect(), UOExecutorModule::mf_PlayStationaryEffect_Ex(), NPCExecutorModule::mf_RunAwayFromLocation(), NPCExecutorModule::mf_RunTowardLocation(), UOExecutorModule::mf_SendQuestArrow(), NPCExecutorModule::mf_SetAnchor(), NPCExecutorModule::mf_TurnAwayFromLocation(), NPCExecutorModule::mf_TurnTowardLocation(), NPCExecutorModule::mf_WalkAwayFromLocation(), NPCExecutorModule::mf_WalkTowardLocation(), navigable(), UObject::readProperties(), Map::script_method_id(), UBoat::script_method_id(), Item::script_method_id(), UHouse::scripted_create(), and VALID_WORLD_LOC().

+ Here is the call graph for this function:

bool Realm::walkheight ( unsigned short  x,
unsigned short  y,
short  oldz,
short *  newz,
UMulti **  pmulti,
Item **  pwalkon,
bool  doors_block,
MOVEMODE  movemode,
short *  gradual_boost = NULL 
)

Member Data Documentation

Definition at line 144 of file realm.h.

Referenced by _Descriptor(), and name().

Definition at line 146 of file realm.h.

Referenced by getmapshapes().

Definition at line 148 of file realm.h.

Referenced by getmaptile(), and groundheight().

Definition at line 147 of file realm.h.

Referenced by findstatic(), and getstatics().

set<unsigned int> Realm::global_hulls

Definition at line 100 of file realm.h.

Referenced by UBoat::navigable(), UBoat::regself(), and UBoat::unregself().

unsigned int Realm::shadowid

Definition at line 44 of file realm.h.

Referenced by add_realm().

const std::string Realm::shadowname

Definition at line 46 of file realm.h.

Referenced by name().


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