CvTeam::isHuman() const
- Defined in
- CvTeam.cpp, line 2442
- Class
- CvTeam
- Hook name
CivHooks::CvTeam_isHuman
Hooks
static bool BeforeCvTeam_isHuman(const CvTeam* self, bool& result);static void AfterCvTeam_isHuman(const CvTeam* self, bool& result);static bool ReplaceCvTeam_isHuman(bool (*original)(const CvTeam*), const CvTeam* self);CivRegisterBefore<CivHooks::CvTeam_isHuman>(host, &BeforeCvTeam_isHuman);CivRegisterAfter<CivHooks::CvTeam_isHuman>(host, &AfterCvTeam_isHuman);CivRegisterReplace<CivHooks::CvTeam_isHuman>(host, &ReplaceCvTeam_isHuman);
Code
2442bool CvTeam::isHuman() const2443{2444 int iI;24452446 for(iI = 0; iI < MAX_PLAYERS; iI++)2447 {2448 if(GET_PLAYER((PlayerTypes)iI).isAlive() && GET_PLAYER((PlayerTypes)iI).getTeam() == GetID())2449 {2450 if(GET_PLAYER((PlayerTypes)iI).isHuman())2451 {2452 return true;2453 }2454 }2455 }24562457 return false;2458}
Calls
Called by
- CvDeal::IsPossibleToTradeItem(PlayerTypes, PlayerTypes, TradeableItems, int, int, int, bool, bool, bool)
- CvGame::doTurn()
- CvGame::initFreeState(CvGameInitialItemsOverrides &)
- CvGame::updateWar()
- CvPlayerAI::AI_launch(VictoryTypes)
- CvPlot::changeVisibilityCount(TeamTypes, int, InvisibleTypes, bool, bool, CvUnit *)
- CvTeam::SetCurrentEra(EraTypes)
- CvTeam::hasMetHuman() const
- CvTeam::isAtWarWithHumans() const
- CvTeam::makeHasMet(TeamTypes, bool)
- CvTeam::setHasTech(TechTypes, bool, PlayerTypes, bool, bool)
- CvUnit::setXY(int, int, bool, bool, bool, bool, bool)
- CvLuaTeam::lIsHuman(lua_State *)