ManaPlus
|
#include <actormanager.h>
Public Member Functions | |
ActorManager () | |
~ActorManager () | |
void | setMap (Map *const map) |
void | setPlayer (LocalPlayer *const player) |
Being * | createBeing (const BeingId id, const ActorTypeT type, const BeingTypeId subtype) |
FloorItem * | createItem (const BeingId id, const int itemId, const int x, const int y, const ItemTypeT itemType, const int amount, const int refine, const ItemColor color, const Identified identified, const Damaged damaged, const int subX, const int subY, const int *const cards) |
void | destroy (ActorSprite *const actor) |
void | erase (ActorSprite *const actor) |
void | undelete (const ActorSprite *const actor) |
Being * | findBeing (const BeingId id) const |
ActorSprite * | findActor (const BeingId id) const |
Being * | findBeing (const int x, const int y, const ActorTypeT type) const |
Being * | findBeingByPixel (const int x, const int y, const AllPlayers allPlayers) const |
void | findBeingsByPixel (std::vector< ActorSprite * > &beings, const int x, const int y, const AllPlayers allPlayers) const |
Being * | findPortalByTile (const int x, const int y) const |
FloorItem * | findItem (const BeingId id) const |
FloorItem * | findItem (const int x, const int y) const |
Being * | findNearestLivingBeing (const int x, const int y, int maxTileDist, const ActorTypeT type, const Being *const excluded) const |
Being * | findNearestLivingBeing (const Being *const aroundBeing, const int maxTileDist, const ActorTypeT type, const AllowSort allowSort) const |
Being * | findBeingByName (const std::string &name, const ActorTypeT type) const |
Being * | findNearestByName (const std::string &name, const ActorTypeT &type) const |
Being * | findMostDamagedPlayer (const int maxTileDist) const |
Being * | findNearestPvpPlayer () const |
void | healTarget () const |
void | heal (const Being *const target) const |
void | itenplz () const |
const ActorSprites & | getAll () const A_CONST |
bool | hasActorSprite (const ActorSprite *const actor) const |
void | logic () |
void | clear () |
void | addBlock (const BeingId id) |
void | deleteBlock (const BeingId id) |
bool | isBlocked (const BeingId id) const |
void | printAllToChat () |
void | printBeingsToChat (const std::string &header) const |
void | getPlayerNames (StringVect &names, const NpcNames npcNames) const |
void | getMobNames (StringVect &names) const |
void | updatePlayerNames () const |
void | updatePlayerColors () const |
void | updatePlayerGuild () const |
void | parseLevels (std::string levels) const |
bool | pickUpAll (const int x1, const int y1, const int x2, const int y2, const bool serverBuggy) const |
bool | pickUpNearest (const int x, const int y, int maxdist) const |
void | optionChanged (const std::string &name) |
void | removeAttackMob (const std::string &name) |
void | removePickupItem (const std::string &name) |
void | addPriorityAttackMob (const std::string &name) |
void | addAttackMob (const std::string &name) |
void | addIgnoreAttackMob (const std::string &name) |
void | addPickupItem (const std::string &name) |
void | addIgnorePickupItem (const std::string &name) |
void | setPriorityAttackMobs (const std::list< std::string > &mobs) |
void | setAttackMobs (const std::list< std::string > &mobs) |
int | getPriorityAttackMobsSize () const |
int | getAttackMobsSize () const |
int | getPickupItemsSize () const |
bool | isInAttackList (const std::string &name) const |
void | rebuildAttackMobs () |
std::set< std::string > | getAttackMobsSet () const |
std::list< std::string > | getAttackMobs () const |
bool | isInPriorityAttackList (const std::string &name) const |
void | rebuildPriorityAttackMobs () |
std::set< std::string > | getPriorityAttackMobsSet () const |
std::list< std::string > | getPriorityAttackMobs () const |
bool | isInIgnoreAttackList (const std::string &name) const |
void | rebuildIgnoreAttackMobs () |
std::set< std::string > | getIgnoreAttackMobsSet () const |
std::list< std::string > | getIgnoreAttackMobs () const |
bool | isInPickupList (const std::string &name) const |
void | rebuildPickupItems () |
std::set< std::string > | getPickupItemsSet () const |
std::list< std::string > | getPickupItems () const |
bool | isInIgnorePickupList (const std::string &name) const |
void | rebuildIgnorePickupItems () |
std::set< std::string > | getIgnorePickupItemsSet () const |
std::list< std::string > | getIgnorePickupItems () const |
const StringIntMap & | getAttackMobsMap () const |
const StringIntMap & | getPriorityAttackMobsMap () const |
int | getAttackMobIndex (const std::string &name) const |
int | getPriorityAttackMobIndex (const std::string &name) const |
int | getPickupItemIndex (const std::string &name) const |
bool | checkForPickup (const FloorItem *const item) const |
bool | checkDefaultPickup () const |
void | updateEffects (const std::map< BeingTypeId, int > &addEffects, const std::set< BeingTypeId > &removeEffects) const |
void | updateBadges () const |
void | updateNameId (const std::string &name, const BeingId beingId) |
void | updateSeenPlayers (const std::set< std::string > &onlinePlayers) |
std::string | getSeenPlayerById (const BeingId id) const |
size_t | size () const |
void | removeRoom (const int chatId) |
void | updateRoom (const ChatObject *const newChat) |
std::string | findCharById (const int32_t id) |
void | addChar (const int32_t id, const std::string &name) |
Public Member Functions inherited from ConfigListener | |
ConfigListener () | |
virtual | ~ConfigListener () |
Static Public Member Functions | |
static Being * | cloneBeing (const Being *const srcBeing, const int dx, const int dy, const int id) |
static void | printBeingsToChat (const std::vector< Being * > &beings, const std::string &header) |
static int | getIndexByName (const std::string &name, const StringIntMap &map) |
Protected Member Functions | |
bool | validateBeing (const Being *const aroundBeing, Being *const being, const ActorTypeT &type, const Being *const excluded, const int maxCost) const |
Being * | findNearestLivingBeing (const Being *const aroundBeing, const int maxdist, const ActorTypeT &type, const int x, const int y, const Being *const excluded, const AllowSort allowSort) const |
void | loadAttackList () |
void | storeAttackList () const |
Protected Attributes | |
ActorSprites | mActors |
ActorSprites | mDeleteActors |
ActorSpritesMap | mActorsIdMap |
IdNameMapping | mIdName |
std::set< BeingId > | mBlockedBeings |
std::map< int32_t, std::string > | mChars |
Map * | mMap |
std::string | mSpellHeal1 |
std::string | mSpellHeal2 |
std::string | mSpellItenplz |
bool | mTargetDeadPlayers |
bool | mTargetOnlyReachable |
bool | mCyclePlayers |
bool | mCycleMonsters |
bool | mCycleNPC |
bool | mExtMouseTargeting |
bool | mEnableIdCollecting |
std::list< std::string > | mPriorityAttackMobs |
std::set< std::string > | mPriorityAttackMobsSet |
StringIntMap | mPriorityAttackMobsMap |
std::list< std::string > | mAttackMobs |
std::set< std::string > | mAttackMobsSet |
StringIntMap | mAttackMobsMap |
std::list< std::string > | mIgnoreAttackMobs |
std::set< std::string > | mIgnoreAttackMobsSet |
std::list< std::string > | mPickupItems |
std::set< std::string > | mPickupItemsSet |
StringIntMap | mPickupItemsMap |
std::list< std::string > | mIgnorePickupItems |
std::set< std::string > | mIgnorePickupItemsSet |
Definition at line 69 of file actormanager.h.
ActorManager::ActorManager | ( | ) |
Definition at line 209 of file actormanager.cpp.
References Configuration::addListener(), config, and loadAttackList().
ActorManager::~ActorManager | ( | ) |
Definition at line 256 of file actormanager.cpp.
References CHECKLISTENERS, clear(), config, Configuration::removeListeners(), and storeAttackList().
void ActorManager::addAttackMob | ( | const std::string & | name | ) |
Definition at line 1921 of file actormanager.cpp.
References addMobToList, rebuildPriorityAttackMobs(), and storeAttackList().
void ActorManager::addBlock | ( | const BeingId | id | ) |
Definition at line 1572 of file actormanager.cpp.
References mBlockedBeings.
void ActorManager::addChar | ( | const int32_t | id, |
const std::string & | name | ||
) |
Definition at line 2274 of file actormanager.cpp.
References Being::getGuild(), guiInput, guild, localPlayer, mChars, Avatar::setName(), and SDLInput::simulateMouseMove().
Referenced by EAthena::BeingRecv::processSolveCharName().
void ActorManager::addIgnoreAttackMob | ( | const std::string & | name | ) |
Definition at line 1934 of file actormanager.cpp.
References mIgnoreAttackMobs, mIgnoreAttackMobsSet, rebuildAttackMobs(), rebuildPriorityAttackMobs(), and storeAttackList().
void ActorManager::addIgnorePickupItem | ( | const std::string & | name | ) |
Definition at line 1950 of file actormanager.cpp.
References mIgnorePickupItems, mIgnorePickupItemsSet, rebuildPickupItems(), and storeAttackList().
void ActorManager::addPickupItem | ( | const std::string & | name | ) |
Definition at line 1943 of file actormanager.cpp.
References addMobToList, rebuildPickupItems(), and storeAttackList().
void ActorManager::addPriorityAttackMob | ( | const std::string & | name | ) |
Definition at line 1928 of file actormanager.cpp.
References addMobToList, and storeAttackList().
bool ActorManager::checkDefaultPickup | ( | ) | const |
Definition at line 2071 of file actormanager.cpp.
References mPickupItemsSet.
bool ActorManager::checkForPickup | ( | const FloorItem *const | item | ) | const |
Definition at line 2053 of file actormanager.cpp.
References FloorItem::getName(), mIgnorePickupItemsSet, and mPickupItemsSet.
Referenced by createItem(), and LocalPlayer::pickUp().
void ActorManager::clear | ( | ) |
Destroys all ActorSprites except the local player
Definition at line 1006 of file actormanager.cpp.
References beingEquipmentWindow, for_actors, ActorSprite::getId(), localPlayer, mActors, mActorsIdMap, mChars, mDeleteActors, EquipmentWindow::setBeing(), LocalPlayer::setTarget(), and LocalPlayer::unSetPickUpTarget().
Referenced by Game::changeMap(), and ~ActorManager().
|
static |
Definition at line 2098 of file actormanager.cpp.
References actorManager, CAST_S32, charServerHandler, createBeing(), fromInt, ItemDB::get(), Being::getCurrentAction(), Being::getDirection(), Being::getGender(), Being::getHairColor(), ActorSprite::getId(), Being::getName(), Being::getSpriteColor(), Being::getSpriteID(), Being::getSubType(), Being::getTileX(), Being::getTileY(), Net::CharServerHandler::hairSprite(), CompoundSprite::mSprites, ActorType::Player, returnNullptr, Being::setAction(), Being::setDirection(), Being::setGender(), Being::setHairColor(), Being::setName(), Being::setSpriteColor(), Being::setSpriteColorId(), Being::setTileCoords(), toInt, and Being::unSetSprite().
Being * ActorManager::createBeing | ( | const BeingId | id, |
const ActorTypeT | type, | ||
const BeingTypeId | subtype | ||
) |
Create a Being and add it to the list of ActorSprites.
Definition at line 283 of file actormanager.cpp.
References QuestsWindow::addEffect(), ActorType::Avatar, beingHandler, CAST_S32, LocalPlayer::checkNewName(), Being::createBeing(), ActorType::Elemental, ActorType::FloorItem, ActorSprite::getId(), Net::getNetworkType(), Net::ServerFeatures::haveServerWarpNames(), ActorType::Homunculus, localPlayer, mActors, mActorsIdMap, ActorType::Mercenary, mMap, ActorType::Monster, ActorType::Npc, ActorType::Pet, ActorType::Player, ActorType::Portal, questsWindow, reportAlways, Net::BeingHandler::requestNameById(), serverFeatures, ActorType::SkillUnit, socialWindow, ServerType::TMWATHENA, ActorType::Unknown, SocialWindow::updateActiveList(), and Being::updateFromCache().
Referenced by cloneBeing(), Ea::BeingRecv::createBeing(), and EAthena::BeingRecv::createBeing2().
FloorItem * ActorManager::createItem | ( | const BeingId | id, |
const int | itemId, | ||
const int | x, | ||
const int | y, | ||
const ItemTypeT | itemType, | ||
const int | amount, | ||
const int | refine, | ||
const ItemColor | color, | ||
const Identified | identified, | ||
const Damaged | damaged, | ||
const int | subX, | ||
const int | subY, | ||
const int *const | cards | ||
) |
Create a FloorItem and add it to the list of ActorSprites.
Definition at line 352 of file actormanager.cpp.
References checkForPickup(), FloorItem::disableHightlight(), ActorType::FloorItem, ActorSprite::getId(), mActors, mActorsIdMap, mMap, FloorItem::postInit(), x, and y.
Referenced by EAthena::ItemRecv::processItemDropped(), TmwAthena::ItemRecv::processItemDropped(), EAthena::ItemRecv::processItemDropped2(), EAthena::ItemRecv::processItemVisible(), TmwAthena::ItemRecv::processItemVisible(), and EAthena::ItemRecv::processItemVisible2().
void ActorManager::deleteBlock | ( | const BeingId | id | ) |
Definition at line 1577 of file actormanager.cpp.
References mBlockedBeings.
void ActorManager::destroy | ( | ActorSprite *const | actor | ) |
Destroys the given ActorSprite at the end of ActorManager::logic.
Definition at line 383 of file actormanager.cpp.
References localPlayer, mDeleteActors, and returnNullptrV.
Referenced by Being::logic(), EAthena::BeingRecv::processBeingMove(), TmwAthena::BeingRecv::processBeingMove(), Ea::BeingRecv::processBeingRemove(), EAthena::BeingRecv::processBeingRemoveSkill(), EAthena::BeingRecv::processBeingSpawn(), EAthena::BeingRecv::processBeingVisible(), TmwAthena::BeingRecv::processBeingVisible(), and Ea::ItemRecv::processItemRemove().
void ActorManager::erase | ( | ActorSprite *const | actor | ) |
Definition at line 393 of file actormanager.cpp.
References ActorSprite::getId(), localPlayer, mActors, mActorsIdMap, and returnNullptrV.
Referenced by EAthena::BeingRecv::processBeingMove(), TmwAthena::BeingRecv::processBeingMove(), EAthena::BeingRecv::processBeingSpawn(), EAthena::BeingRecv::processBeingVisible(), and TmwAthena::BeingRecv::processBeingVisible().
ActorSprite * ActorManager::findActor | ( | const BeingId | id | ) | const |
Definition at line 439 of file actormanager.cpp.
References ActorSprite::getId(), and mActorsIdMap.
Referenced by Particle::~Particle().
Returns a specific Being, by id;
Definition at line 423 of file actormanager.cpp.
References ActorType::FloorItem, ActorSprite::getId(), ActorSprite::getType(), and mActorsIdMap.
Referenced by BuySellDialog::action(), PopupMenu::addBeingMenu(), Actions::getPet(), PopupMenu::handleLink(), Viewport::moveCameraToActor(), NpcDialog::postInit(), EAthena::NpcRecv::processArea(), EAthena::BattleGroundRecv::processBattleEmblem2(), Ea::BeingRecv::processBeingAction(), EAthena::BeingRecv::processBeingAction2(), EAthena::BeingRecv::processBeingAttrs(), EAthena::BeingRecv::processBeingChangeDirection(), TmwAthena::BeingRecv::processBeingChangeDirection(), TmwAthena::BeingRecv::processBeingChangeLook(), EAthena::BeingRecv::processBeingChangeLook2(), TmwAthena::BeingRecv::processBeingChangeLook2(), EAthena::BeingRecv::processBeingChangeLookCards(), EAthena::ChatRecv::processBeingChat(), TmwAthena::ChatRecv::processBeingChat(), Ea::BeingRecv::processBeingEmotion(), EAthena::BeingRecv::processBeingHp(), EAthena::BeingRecv::processBeingMove(), TmwAthena::BeingRecv::processBeingMove(), EAthena::BeingRecv::processBeingMove2(), TmwAthena::BeingRecv::processBeingMove2(), Ea::BeingRecv::processBeingMove3(), Ea::BeingRecv::processBeingRemove(), EAthena::BeingRecv::processBeingRemoveSkill(), EAthena::BeingRecv::processBeingResurrect(), TmwAthena::BeingRecv::processBeingResurrect(), EAthena::BeingRecv::processBeingSelfEffect(), TmwAthena::BeingRecv::processBeingSelfEffect(), EAthena::BeingRecv::processBeingSlide(), EAthena::BeingRecv::processBeingSpawn(), EAthena::BeingRecv::processBeingSpecialEffect(), EAthena::BeingRecv::processBeingStatUpdate1(), EAthena::BeingRecv::processBeingStatusChange(), TmwAthena::BeingRecv::processBeingStatusChange(), EAthena::BeingRecv::processBeingVisible(), TmwAthena::BeingRecv::processBeingVisible(), EAthena::BuyingStoreRecv::processBuyingStoreHideBoard(), EAthena::BuyingStoreRecv::processBuyingStoreItemsList(), EAthena::BuyingStoreRecv::processBuyingStoreShowBoard(), EAthena::ChatRecv::processChatDisplay(), EAthena::GuildRecv::processGuildSetPosition(), EAthena::VendingRecv::processHideBoard(), EAthena::HomunculusRecv::processHomunculusData(), EAthena::HomunculusRecv::processHomunculusInfo1(), EAthena::HomunculusRecv::processHomunculusInfo2(), EAthena::HomunculusRecv::processHomunculusInfo3(), TmwAthena::BeingRecv::processIpResponse(), EAthena::VendingRecv::processItemsList(), EAthena::PlayerRecv::processKilledBy(), EAthena::MercenaryRecv::processMercenaryInfo(), EAthena::BeingRecv::processMobInfo(), EAthena::BeingRecv::processMonsterHp(), Ea::ChatRecv::processMVPEffect(), Ea::BeingRecv::processNameResponse(), EAthena::BeingRecv::processNameResponse2(), EAthena::BeingRecv::processNameResponseTitle(), TmwAthena::PartyRecv::processPartyInvited(), Ea::PartyRecv::processPartyLeave(), TmwAthena::PartyRecv::processPartyUpdateHp(), EAthena::PetRecv::processPetData(), EAthena::BeingRecv::processPlayerGuilPartyInfo(), TmwAthena::BeingRecv::processPlayerGuilPartyInfo(), EAthena::BeingRecv::processPlayerGuilPartyInfo2(), EAthena::InventoryRecv::processPlayerInventoryUse(), TmwAthena::BeingRecv::processPlayerMove(), EAthena::BeingRecv::processPlayerStatusChange(), TmwAthena::BeingRecv::processPlayerStatusChange(), EAthena::BeingRecv::processPlayerStatusChange2(), Ea::BeingRecv::processPlayerStop(), TmwAthena::BeingRecv::processPlayerUpdate1(), TmwAthena::BeingRecv::processPlayerUpdate2(), EAthena::BeingRecv::processPvpSet(), TmwAthena::BeingRecv::processPvpSet(), EAthena::VendingRecv::processShowBoard(), EAthena::BeingRecv::processSkillCastingContinue(), EAthena::BeingRecv::processSkillDamage(), TmwAthena::BeingRecv::processSkillDamage(), Ea::BeingRecv::processSkillNoDamage(), EAthena::BeingRecv::processSpiritBalls(), Guild::removeFromMembers(), Party::removeFromMembers(), BuyingStoreSellDialog::sellAction(), PopupMenu::showPopup(), and LocalPlayer::updateCoords().
Being * ActorManager::findBeing | ( | const int | x, |
const int | y, | ||
const ActorTypeT | type | ||
) | const |
Returns a being at specific coordinates.
Definition at line 454 of file actormanager.cpp.
References beingActorFinder, CAST_U16, mActors, nullptr, FindBeingFunctor::type, FindBeingFunctor::x, x, FindBeingFunctor::y, and y.
Being * ActorManager::findBeingByName | ( | const std::string & | name, |
const ActorTypeT | type | ||
) | const |
Finds a being by name and (optionally) by type.
Definition at line 870 of file actormanager.cpp.
References ActorType::FloorItem, for_actorsm, Being::getName(), Being::getType(), ActorType::Portal, and ActorType::Unknown.
Referenced by BuyDialog::action(), PlayerListener::action(), EAthena::PartyHandler::changeLeader(), Actions::findBeing(), LocalPlayer::followMoveTo(), SocialFriendsTab::getPlayersAvatars(), PopupMenu::handleLink(), WhoIsOnline::handleLink(), PlayerRelationsManager::hasPermission(), EAthena::GuildHandler::invite(), EAthena::PartyHandler::invite(), TmwAthena::PartyHandler::invite(), WhoIsOnline::loadWebList(), AvatarListBox::mousePressed(), parseLevels(), GuildManager::process(), EAthena::ChatRecv::processChatRoomLeave(), EAthena::GuildRecv::processGuildExpulsionContinue(), EAthena::GuildRecv::processGuildLeave(), EAthena::GuildRecv::processGuildLeave2(), EAthena::GuildRecv::processGuildMemberList(), ShopWindow::processRequest(), SocialPlayersTab::resetDamage(), WhoIsOnline::setNeutralColor(), OnlinePlayer::setText(), PopupMenu::showChatPopup(), PopupMenu::showPlayerGMCommands(), PlayerRelationsManager::signalUpdate(), ShopWindow::startTrade(), SocialPlayersTab::updateAvatar(), ChatWindow::updateOnline(), and updateSeenPlayers().
Being * ActorManager::findBeingByPixel | ( | const int | x, |
const int | y, | ||
const AllPlayers | allPlayers | ||
) | const |
Returns a being at the specific pixel.
Definition at line 467 of file actormanager.cpp.
References AllPlayers_true, BeingAction::DEAD, ActorType::FloorItem, for_actorsm, Being::getInfo(), Actor::getPixelX(), Actor::getPixelY(), Being::getType(), inputManager, InputManager::isActionActive(), BeingInfo::isTargetSelection(), localPlayer, Being::mAction, mapTileSize, mExtMouseTargeting, mMap, mTargetDeadPlayers, ActorType::Player, ActorType::Portal, InputAction::STOP_ATTACK, x, and y.
void ActorManager::findBeingsByPixel | ( | std::vector< ActorSprite * > & | beings, |
const int | x, | ||
const int | y, | ||
const AllPlayers | allPlayers | ||
) | const |
Returns a beings at the specific pixel.
Definition at line 582 of file actormanager.cpp.
References AllPlayers_true, ActorType::Avatar, ActorType::Elemental, ActorType::FloorItem, for_actors, Being::getInfo(), Actor::getPixelX(), Actor::getPixelY(), ActorSprite::getType(), ActorType::Homunculus, inputManager, InputManager::isActionActive(), Being::isAlive(), BeingInfo::isTargetSelection(), localPlayer, mapTileSize, ActorType::Mercenary, mMap, ActorType::Monster, mTargetDeadPlayers, ActorType::Npc, ActorType::Pet, ActorType::Player, ActorType::Portal, ActorType::SkillUnit, InputAction::STOP_ATTACK, ActorType::Unknown, x, and y.
std::string ActorManager::findCharById | ( | const int32_t | id | ) |
Definition at line 2266 of file actormanager.cpp.
References mChars.
Referenced by ItemPopup::getCardsString(), and EAthena::GuildRecv::processGuildMemberList().
Returns a specific FloorItem, by id.
Definition at line 679 of file actormanager.cpp.
References ActorType::FloorItem, ActorSprite::getId(), ActorSprite::getType(), mActorsIdMap, and returnNullptr.
Referenced by PopupMenu::handleLink(), LocalPlayer::pickedUp(), and LocalPlayer::pickUpItems().
FloorItem * ActorManager::findItem | ( | const int | x, |
const int | y | ||
) | const |
Returns a FloorItem at specific coordinates.
Definition at line 695 of file actormanager.cpp.
References ActorType::FloorItem, for_actorsm, x, and y.
Being * ActorManager::findMostDamagedPlayer | ( | const int | maxTileDist | ) | const |
Finds most damaged player, non-enemy and alive
maxTileDist | maximal distance. |
Definition at line 1501 of file actormanager.cpp.
References Relation::ENEMY2, fastSqrtInt(), for_actors, Being::getDamageTaken(), Being::getName(), PlayerRelationsManager::getRelation(), Being::getTileX(), Being::getTileY(), Being::isAlive(), localPlayer, ActorType::Player, and playerRelations.
Being * ActorManager::findNearestByName | ( | const std::string & | name, |
const ActorTypeT & | type | ||
) | const |
Finds a nearest being by name and (optionally) by type.
Definition at line 895 of file actormanager.cpp.
References ActorType::FloorItem, for_actorsm, Being::getName(), Being::getTileX(), Being::getTileY(), Being::getType(), localPlayer, ActorType::Player, ActorType::Portal, ActorType::Unknown, validateBeing(), x, and y.
|
protected |
Definition at line 1121 of file actormanager.cpp.
References AllowSort_true, SortBeingFunctor::attackBeings, SortBeingFunctor::attackRange, beingActorSorter, beingEqualActorFinder, config, SortBeingFunctor::defaultAttackIndex, SortBeingFunctor::defaultPriorityIndex, FindBeingEqualFunctor::findBeing, ActorType::FloorItem, FOR_EACH, LocalPlayer::getAttackRange(), Configuration::getBoolValue(), Being::getDistance(), Being::getInfo(), Being::getName(), LocalPlayer::getTarget(), Being::getTileX(), Being::getTileY(), Being::getType(), if(), inputManager, InputManager::isActionActive(), BeingInfo::isTargetSelection(), localPlayer, mActors, mAttackMobsMap, mAttackMobsSet, mCycleMonsters, mCycleNPC, mCyclePlayers, mIgnoreAttackMobsSet, ActorType::Monster, Settings::moveToTargetType, mPriorityAttackMobsMap, mPriorityAttackMobsSet, mTargetOnlyReachable, ActorType::Npc, ActorType::Player, ActorType::Portal, SortBeingFunctor::priorityBeings, settings, SortBeingFunctor::specialDistance, InputAction::STOP_ATTACK, anonymous_namespace{libxml.cpp}::valid, validateBeing(), SortBeingFunctor::x, x, SortBeingFunctor::y, and y.
Being * ActorManager::findNearestLivingBeing | ( | const Being *const | aroundBeing, |
const int | maxTileDist, | ||
const ActorTypeT | type, | ||
const AllowSort | allowSort | ||
) | const |
Returns a being nearest to another being.
aroundBeing | The being to search around. |
maxTileDist | Maximal distance in tiles. If minimal distance is larger, no being is returned. |
type | The type of being to look for. |
Definition at line 1104 of file actormanager.cpp.
References findNearestLivingBeing(), Being::getTileX(), and Being::getTileY().
Being * ActorManager::findNearestLivingBeing | ( | const int | x, |
const int | y, | ||
int | maxTileDist, | ||
const ActorTypeT | type, | ||
const Being *const | excluded | ||
) | const |
Returns a being nearest to specific coordinates.
x | X coordinate in pixels. |
y | Y coordinate in pixels. |
maxTileDist | Maximal distance in tiles. If minimal distance is larger, no being is returned. |
type | The type of being to look for. |
Definition at line 1090 of file actormanager.cpp.
References AllowSort_true, mapTileSize, x, and y.
Referenced by Actions::findBeing(), findNearestLivingBeing(), replaceVars(), and LocalPlayer::setNewTarget().
Being * ActorManager::findNearestPvpPlayer | ( | ) | const |
Finds the nearest player who has PVP on, or just the nearest player if map pvp is on
Definition at line 1033 of file actormanager.cpp.
References LocalPlayer::checAttackPermissions(), for_actors, Game::getCurrentMap(), Map::getPvpMode(), Being::getTeamId(), Being::getTileX(), Being::getTileY(), Game::instance(), Being::isAlive(), localPlayer, ActorType::Player, Settings::pvpAttackType, reportTrue, and settings.
Being * ActorManager::findPortalByTile | ( | const int | x, |
const int | y | ||
) | const |
Returns a portal at the specific tile.
Definition at line 656 of file actormanager.cpp.
References for_actorsm, Being::getTileX(), Being::getTileY(), mMap, ActorType::Portal, x, and y.
Referenced by SocialNavigationTab::updateList().
const ActorSprites & ActorManager::getAll | ( | ) | const |
Returns the whole list of beings.
Definition at line 941 of file actormanager.cpp.
References mActors.
Referenced by ChatWindow::doPresent(), and Minimap::draw2().
int ActorManager::getAttackMobIndex | ( | const std::string & | name | ) | const |
Definition at line 1988 of file actormanager.cpp.
References getIndexByName(), and mAttackMobsMap.
Referenced by PopupMenu::showAttackMonsterPopup().
|
inline |
Definition at line 341 of file actormanager.h.
|
inline |
|
inline |
Definition at line 341 of file actormanager.h.
|
inline |
Definition at line 325 of file actormanager.h.
References CAST_S32, and mAttackMobs.
Referenced by PopupMenu::showAttackMonsterPopup().
|
inline |
Definition at line 343 of file actormanager.h.
|
inline |
Definition at line 343 of file actormanager.h.
|
inline |
Definition at line 345 of file actormanager.h.
|
inline |
Definition at line 345 of file actormanager.h.
|
static |
Definition at line 1973 of file actormanager.cpp.
Referenced by getAttackMobIndex(), getPickupItemIndex(), and getPriorityAttackMobIndex().
void ActorManager::getMobNames | ( | StringVect & | names | ) | const |
Definition at line 1723 of file actormanager.cpp.
References ActorType::FloorItem, for_actors, Being::getName(), Being::getType(), ActorType::Monster, and ActorType::Portal.
Referenced by ChatWindow::autoComplete().
int ActorManager::getPickupItemIndex | ( | const std::string & | name | ) | const |
Definition at line 1993 of file actormanager.cpp.
References getIndexByName(), and mPickupItemsMap.
|
inline |
Definition at line 344 of file actormanager.h.
|
inline |
Definition at line 344 of file actormanager.h.
|
inline |
void ActorManager::getPlayerNames | ( | StringVect & | names, |
const NpcNames | npcNames | ||
) | const |
Definition at line 1695 of file actormanager.cpp.
References ActorType::FloorItem, for_actors, Being::getName(), Being::getType(), ActorType::Npc, NpcNames_true, ActorType::Player, and ActorType::Portal.
Referenced by ChatWindow::autoComplete(), SocialPlayersTab::getPlayersAvatars(), and replaceVars().
int ActorManager::getPriorityAttackMobIndex | ( | const std::string & | name | ) | const |
Definition at line 1983 of file actormanager.cpp.
References getIndexByName(), and mPriorityAttackMobsMap.
|
inline |
Definition at line 342 of file actormanager.h.
|
inline |
|
inline |
Definition at line 342 of file actormanager.h.
|
inline |
Definition at line 322 of file actormanager.h.
References CAST_S32, and mPriorityAttackMobs.
Referenced by PopupMenu::showAttackMonsterPopup().
std::string ActorManager::getSeenPlayerById | ( | const BeingId | id | ) | const |
Definition at line 2212 of file actormanager.cpp.
References mEnableIdCollecting, and mIdName.
Referenced by TmwAthena::ChatRecv::processBeingChat(), and PopupMenu::showPopup().
bool ActorManager::hasActorSprite | ( | const ActorSprite *const | actor | ) | const |
Returns true if the given ActorSprite is in the manager's list, false otherwise.
actor | the ActorSprite to search for |
Definition at line 1561 of file actormanager.cpp.
References for_actors.
void ActorManager::heal | ( | const Being *const | target | ) | const |
Definition at line 1413 of file actormanager.cpp.
References Net::PlayerHandler::canUseMagic(), chatWindow, Relation::ENEMY2, PlayerInfo::getAttribute(), Being::getName(), Net::getNetworkType(), PlayerRelationsManager::getRelation(), PlayerInfo::getSkillLevel(), Being::getType(), Being::isAlive(), PacketLimiter::limitPackets(), ChatWindow::localChatInput(), localPlayer, ActorType::Monster, mSpellHeal1, mSpellHeal2, PacketType::PACKET_CHAT, Attributes::PLAYER_HP, Attributes::PLAYER_MAX_HP, Attributes::PLAYER_MP, playerHandler, playerRelations, and ServerType::TMWATHENA.
Referenced by healTarget(), and AvatarListBox::mousePressed().
void ActorManager::healTarget | ( | ) | const |
Heal all players in distance.
maxdist | maximal distance. If minimal distance is larger, no being is returned |
Definition at line 1405 of file actormanager.cpp.
References LocalPlayer::getTarget(), heal(), and localPlayer.
bool ActorManager::isBlocked | ( | const BeingId | id | ) | const |
Definition at line 1582 of file actormanager.cpp.
References mBlockedBeings.
Referenced by EAthena::BeingRecv::processBeingMove(), TmwAthena::BeingRecv::processBeingMove(), EAthena::BeingRecv::processBeingSpawn(), EAthena::BeingRecv::processBeingVisible(), TmwAthena::BeingRecv::processBeingVisible(), TmwAthena::BeingRecv::processPlayerMove(), TmwAthena::BeingRecv::processPlayerUpdate1(), and TmwAthena::BeingRecv::processPlayerUpdate2().
|
inline |
|
inline |
|
inline |
Definition at line 345 of file actormanager.h.
Referenced by PopupMenu::addPickupFilter(), and PopupMenu::showPopup().
|
inline |
Definition at line 344 of file actormanager.h.
Referenced by PopupMenu::addPickupFilter(), and PopupMenu::showPopup().
|
inline |
void ActorManager::itenplz | ( | ) | const |
Definition at line 1542 of file actormanager.cpp.
References Net::PlayerHandler::canUseMagic(), chatWindow, Net::getNetworkType(), Being::isAlive(), PacketLimiter::limitPackets(), ChatWindow::localChatInput(), localPlayer, mSpellItenplz, PacketType::PACKET_CHAT, playerHandler, and ServerType::TMWATHENA.
|
protected |
Definition at line 2013 of file actormanager.cpp.
References empty, loadList, mAttackMobs, mAttackMobsSet, mPickupItems, mPickupItemsSet, rebuildAttackMobs(), rebuildPickupItems(), and rebuildPriorityAttackMobs().
Referenced by ActorManager().
void ActorManager::logic | ( | ) |
Performs ActorSprite logic and deletes ActorSprite scheduled to be deleted.
Definition at line 946 of file actormanager.cpp.
References Being::addToCache(), beingEquipmentWindow, BLOCK_END, BLOCK_START, Viewport::clearHover(), for_actors, FOR_EACH, ActorSprite::getId(), LocalPlayer::getPickUpTarget(), LocalPlayer::getTarget(), ActorSprite::getType(), localPlayer, mActors, mActorsIdMap, mDeleteActors, ActorType::Player, EquipmentWindow::resetBeing(), LocalPlayer::setTarget(), LocalPlayer::unSetPickUpTarget(), and viewport.
Referenced by Game::logic().
|
virtual |
Called when an option changed. The config listener will have to be registered to the option name first.
Implements ConfigListener.
Definition at line 1840 of file actormanager.cpp.
References config, Configuration::getBoolValue(), mCycleMonsters, mCycleNPC, mCyclePlayers, mEnableIdCollecting, mExtMouseTargeting, mTargetDeadPlayers, mTargetOnlyReachable, and updateBadges().
void ActorManager::parseLevels | ( | std::string | levels | ) | const |
Definition at line 1810 of file actormanager.cpp.
References Being::addToCache(), CAST_SIZE, findBeingByName(), ActorType::Player, Being::setLevel(), and updatePlayerNames().
Referenced by TmwAthena::ChatRecv::processChatContinue().
bool ActorManager::pickUpAll | ( | const int | x1, |
const int | y1, | ||
const int | x2, | ||
const int | y2, | ||
const bool | serverBuggy | ||
) | const |
Definition at line 713 of file actormanager.cpp.
References PacketLimiter::checkPackets(), ActorType::FloorItem, for_actorsm, FloorItem::getName(), FloorItem::getPickupCount(), FloorItem::incrementPickup(), localPlayer, mIgnorePickupItemsSet, mPickupItemsSet, PacketType::PACKET_PICKUP, and LocalPlayer::pickUp().
Referenced by LocalPlayer::pickUpItems().
bool ActorManager::pickUpNearest | ( | const int | x, |
const int | y, | ||
int | maxdist | ||
) | const |
Definition at line 813 of file actormanager.cpp.
References ActorType::FloorItem, for_actorsm, FloorItem::getName(), FloorItem::getTileX(), FloorItem::getTileY(), LocalPlayer::isReachable(), localPlayer, mIgnorePickupItemsSet, mPickupItemsSet, mTargetOnlyReachable, LocalPlayer::pickUp(), x, and y.
Referenced by LocalPlayer::pickUpItems().
void ActorManager::printAllToChat | ( | ) |
Definition at line 1587 of file actormanager.cpp.
References _, and printBeingsToChat().
void ActorManager::printBeingsToChat | ( | const std::string & | header | ) | const |
Definition at line 1593 of file actormanager.cpp.
References ChatMsgType::BY_SERVER, ChatTab::chatLog(), debugChatTab, ActorType::FloorItem, for_actors, FOR_EACH, ActorSprite::getId(), Being::getName(), Being::getSubType(), Being::getTileX(), Being::getTileY(), IgnoreRecord_false, mActorsIdMap, strprintf(), toInt, and TryRemoveColors_true.
Referenced by printAllToChat().
|
static |
Definition at line 1660 of file actormanager.cpp.
References ChatMsgType::BY_SERVER, ChatTab::chatLog(), debugChatTab, FOR_EACH, Being::getName(), Being::getSubType(), Being::getTileX(), Being::getTileY(), IgnoreRecord_false, strprintf(), toInt, and TryRemoveColors_true.
void ActorManager::rebuildAttackMobs | ( | ) |
Definition at line 1963 of file actormanager.cpp.
References rebuildMobsList.
Referenced by addIgnoreAttackMob(), loadAttackList(), and removeAttackMob().
void ActorManager::rebuildIgnoreAttackMobs | ( | ) |
void ActorManager::rebuildIgnorePickupItems | ( | ) |
void ActorManager::rebuildPickupItems | ( | ) |
Definition at line 1968 of file actormanager.cpp.
References rebuildMobsList.
Referenced by addIgnorePickupItem(), addPickupItem(), loadAttackList(), and removePickupItem().
void ActorManager::rebuildPriorityAttackMobs | ( | ) |
Definition at line 1958 of file actormanager.cpp.
References rebuildMobsList.
Referenced by addAttackMob(), addIgnoreAttackMob(), loadAttackList(), and removeAttackMob().
void ActorManager::removeAttackMob | ( | const std::string & | name | ) |
Definition at line 1860 of file actormanager.cpp.
References mAttackMobs, mAttackMobsSet, mIgnoreAttackMobs, mIgnoreAttackMobsSet, mPriorityAttackMobs, mPriorityAttackMobsSet, rebuildAttackMobs(), rebuildPriorityAttackMobs(), and storeAttackList().
void ActorManager::removePickupItem | ( | const std::string & | name | ) |
Definition at line 1873 of file actormanager.cpp.
References mIgnorePickupItems, mIgnorePickupItemsSet, mPickupItems, mPickupItemsSet, rebuildPickupItems(), and storeAttackList().
void ActorManager::removeRoom | ( | const int | chatId | ) |
Definition at line 2226 of file actormanager.cpp.
References ChatObject::chatId, for_actors, Being::getChat(), ActorSprite::getType(), ActorType::Npc, and Being::setChat().
Referenced by EAthena::ChatRecv::processChatRoomDestroy().
|
inline |
void ActorManager::setMap | ( | Map *const | map | ) |
Sets the map on which ActorSprites are created.
Definition at line 264 of file actormanager.cpp.
References localPlayer, mMap, and LocalPlayer::setMap().
Referenced by Game::changeMap().
void ActorManager::setPlayer | ( | LocalPlayer *const | player | ) |
Sets the current player.
Definition at line 272 of file actormanager.cpp.
References ActorSprite::getId(), localPlayer, mActors, mActorsIdMap, socialWindow, SocialWindow::updateAttackFilter(), and SocialWindow::updatePickupFilter().
Referenced by Game::Game().
|
inline |
|
inline |
|
protected |
Definition at line 2043 of file actormanager.cpp.
References mAttackMobs, mIgnoreAttackMobs, mIgnorePickupItems, mPickupItems, mPriorityAttackMobs, packList(), serverConfig, and Configuration::setValue().
Referenced by addAttackMob(), addIgnoreAttackMob(), addIgnorePickupItem(), addPickupItem(), addPriorityAttackMob(), removeAttackMob(), removePickupItem(), and ~ActorManager().
void ActorManager::undelete | ( | const ActorSprite *const | actor | ) |
Definition at line 406 of file actormanager.cpp.
References FOR_EACH, localPlayer, mDeleteActors, and returnNullptrV.
Referenced by EAthena::BeingRecv::processBeingMove(), TmwAthena::BeingRecv::processBeingMove(), EAthena::BeingRecv::processBeingSpawn(), EAthena::BeingRecv::processBeingVisible(), TmwAthena::BeingRecv::processBeingVisible(), TmwAthena::BeingRecv::processPlayerMove(), TmwAthena::BeingRecv::processPlayerUpdate1(), and TmwAthena::BeingRecv::processPlayerUpdate2().
void ActorManager::updateBadges | ( | ) | const |
Definition at line 2141 of file actormanager.cpp.
References config, for_actors, Configuration::getIntValue(), ActorSprite::getType(), BadgeDrawType::Hide, Being::mShowBadges, Being::mVisibleNamePos, ActorType::Player, and Being::showBadges().
Referenced by optionChanged().
void ActorManager::updateEffects | ( | const std::map< BeingTypeId, int > & | addEffects, |
const std::set< BeingTypeId > & | removeEffects | ||
) | const |
Definition at line 2076 of file actormanager.cpp.
References Being::addSpecialEffect(), for_actorsm, Being::getSubType(), ActorType::Npc, and Being::removeSpecialEffect().
Referenced by QuestsWindow::updateEffects().
void ActorManager::updateNameId | ( | const std::string & | name, |
const BeingId | beingId | ||
) |
Definition at line 2160 of file actormanager.cpp.
References BeingId_zero, CAST_S32, getDateTimeString(), mEnableIdCollecting, mIdName, pathJoin(), Files::saveTextFile(), settings, stringToHexPath(), Catch::toString(), Settings::usersDir, and Settings::usersIdDir.
Referenced by Ea::BeingRecv::processNameResponse(), EAthena::BeingRecv::processNameResponse2(), EAthena::BeingRecv::processNameResponseTitle(), TmwAthena::PlayerRecv::processOnlineList(), EAthena::BeingRecv::processPlayerGuilPartyInfo(), EAthena::BeingRecv::processPlayerGuilPartyInfo2(), and updateSeenPlayers().
void ActorManager::updatePlayerColors | ( | ) | const |
Definition at line 1769 of file actormanager.cpp.
References ActorType::FloorItem, for_actorsm, Being::getName(), Being::getType(), ActorType::Player, ActorType::Portal, and Being::updateColors().
Referenced by GuildManager::afterRemove(), EAthena::GuildRecv::processGuildExpulsionContinue(), EAthena::GuildRecv::processGuildLeave(), EAthena::GuildRecv::processGuildLeave2(), EAthena::GuildRecv::processGuildMemberList(), and GuildManager::updateList().
void ActorManager::updatePlayerGuild | ( | ) | const |
Definition at line 1789 of file actormanager.cpp.
References ActorType::FloorItem, for_actorsm, Being::getName(), Being::getType(), ActorType::Player, ActorType::Portal, and Being::updateGuild().
Referenced by GuildManager::afterRemove(), EAthena::GuildRecv::processGuildMemberList(), and GuildManager::updateList().
void ActorManager::updatePlayerNames | ( | ) | const |
Definition at line 1748 of file actormanager.cpp.
References ActorType::FloorItem, for_actorsm, Being::getName(), Being::getType(), ActorType::Player, ActorType::Portal, Being::setGoodStatus(), and Being::updateName().
Referenced by Setup_Relations::apply(), and parseLevels().
void ActorManager::updateRoom | ( | const ChatObject *const | newChat | ) |
Definition at line 2243 of file actormanager.cpp.
References ChatObject::chatId, for_actors, Being::getChat(), ActorSprite::getType(), ChatObject::maxUsers, ActorType::Npc, ChatObject::ownerId, ChatObject::title, and ChatObject::type.
Referenced by EAthena::ChatRecv::processChatRoomSettings().
void ActorManager::updateSeenPlayers | ( | const std::set< std::string > & | onlinePlayers | ) |
Definition at line 2198 of file actormanager.cpp.
References BeingId_zero, findBeingByName(), FOR_EACH, mEnableIdCollecting, ActorType::Player, and updateNameId().
Referenced by WhoIsOnline::loadList(), and WhoIsOnline::slowLogic().
|
protected |
Definition at line 1388 of file actormanager.cpp.
References Being::getType(), Being::isAlive(), LocalPlayer::isReachable(), localPlayer, ActorType::Monster, mTargetDeadPlayers, mTargetOnlyReachable, ActorType::Player, and ActorType::Unknown.
Referenced by findNearestByName(), and findNearestLivingBeing().
|
protected |
Definition at line 414 of file actormanager.h.
Referenced by clear(), createBeing(), createItem(), erase(), findBeing(), findNearestLivingBeing(), getAll(), logic(), setPlayer(), and size().
|
protected |
Definition at line 416 of file actormanager.h.
Referenced by clear(), createBeing(), createItem(), erase(), findActor(), findBeing(), findItem(), logic(), printBeingsToChat(), and setPlayer().
|
protected |
Definition at line 448 of file actormanager.h.
Referenced by getAttackMobsSize(), loadAttackList(), removeAttackMob(), setAttackMobs(), and storeAttackList().
|
protected |
Definition at line 448 of file actormanager.h.
Referenced by findNearestLivingBeing(), getAttackMobIndex(), and getAttackMobsMap().
|
protected |
Definition at line 448 of file actormanager.h.
Referenced by findNearestLivingBeing(), loadAttackList(), and removeAttackMob().
|
protected |
Definition at line 418 of file actormanager.h.
Referenced by addBlock(), deleteBlock(), and isBlocked().
|
protected |
Definition at line 419 of file actormanager.h.
Referenced by addChar(), clear(), and findCharById().
|
protected |
Definition at line 430 of file actormanager.h.
Referenced by findNearestLivingBeing(), and optionChanged().
|
protected |
Definition at line 431 of file actormanager.h.
Referenced by findNearestLivingBeing(), and optionChanged().
|
protected |
Definition at line 429 of file actormanager.h.
Referenced by findNearestLivingBeing(), and optionChanged().
|
protected |
Definition at line 415 of file actormanager.h.
Referenced by clear(), destroy(), logic(), and undelete().
|
protected |
Definition at line 433 of file actormanager.h.
Referenced by getSeenPlayerById(), optionChanged(), updateNameId(), and updateSeenPlayers().
|
protected |
Definition at line 432 of file actormanager.h.
Referenced by findBeingByPixel(), and optionChanged().
|
protected |
Definition at line 417 of file actormanager.h.
Referenced by getSeenPlayerById(), and updateNameId().
|
protected |
Definition at line 448 of file actormanager.h.
Referenced by addIgnoreAttackMob(), removeAttackMob(), and storeAttackList().
|
protected |
Definition at line 448 of file actormanager.h.
Referenced by addIgnoreAttackMob(), findNearestLivingBeing(), and removeAttackMob().
|
protected |
Definition at line 449 of file actormanager.h.
Referenced by addIgnorePickupItem(), removePickupItem(), and storeAttackList().
|
protected |
Definition at line 449 of file actormanager.h.
Referenced by addIgnorePickupItem(), checkForPickup(), pickUpAll(), pickUpNearest(), and removePickupItem().
|
protected |
Definition at line 420 of file actormanager.h.
Referenced by createBeing(), createItem(), findBeingByPixel(), findBeingsByPixel(), findPortalByTile(), and setMap().
|
protected |
Definition at line 449 of file actormanager.h.
Referenced by getPickupItemsSize(), loadAttackList(), removePickupItem(), and storeAttackList().
|
protected |
Definition at line 449 of file actormanager.h.
Referenced by getPickupItemIndex().
|
protected |
Definition at line 449 of file actormanager.h.
Referenced by checkDefaultPickup(), checkForPickup(), loadAttackList(), pickUpAll(), pickUpNearest(), and removePickupItem().
|
protected |
Definition at line 447 of file actormanager.h.
Referenced by getPriorityAttackMobsSize(), removeAttackMob(), setPriorityAttackMobs(), and storeAttackList().
|
protected |
Definition at line 447 of file actormanager.h.
Referenced by findNearestLivingBeing(), getPriorityAttackMobIndex(), and getPriorityAttackMobsMap().
|
protected |
Definition at line 447 of file actormanager.h.
Referenced by findNearestLivingBeing(), and removeAttackMob().
|
protected |
Definition at line 422 of file actormanager.h.
Referenced by heal().
|
protected |
Definition at line 423 of file actormanager.h.
Referenced by heal().
|
protected |
Definition at line 424 of file actormanager.h.
Referenced by itenplz().
|
protected |
Definition at line 427 of file actormanager.h.
Referenced by findBeingByPixel(), findBeingsByPixel(), optionChanged(), and validateBeing().
|
protected |
Definition at line 428 of file actormanager.h.
Referenced by findNearestLivingBeing(), optionChanged(), pickUpNearest(), and validateBeing().