本文整理汇总了C++中FlightPathMovementGenerator::LoadPath方法的典型用法代码示例。如果您正苦于以下问题:C++ FlightPathMovementGenerator::LoadPath方法的具体用法?C++ FlightPathMovementGenerator::LoadPath怎么用?C++ FlightPathMovementGenerator::LoadPath使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类FlightPathMovementGenerator
的用法示例。
在下文中一共展示了FlightPathMovementGenerator::LoadPath方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: HandleTaxiRequestEarlyLanding
void WorldSession::HandleTaxiRequestEarlyLanding(WorldPackets::Taxi::TaxiRequestEarlyLanding& /*taxiRequestEarlyLanding*/)
{
if (GetPlayer()->GetMotionMaster()->GetCurrentMovementGeneratorType() == FLIGHT_MOTION_TYPE)
{
if (GetPlayer()->m_taxi.RequestEarlyLanding())
{
FlightPathMovementGenerator* flight = static_cast<FlightPathMovementGenerator*>(GetPlayer()->GetMotionMaster()->top());
flight->LoadPath(GetPlayer(), flight->GetPath()[flight->GetCurrentNode()]->NodeIndex);
flight->Reset(GetPlayer());
}
}
}
示例2: MoveTaxiFlight
void MotionMaster::MoveTaxiFlight(uint32 path, uint32 pathnode)
{
if (_owner->GetTypeId() == TYPEID_PLAYER)
{
if (path < sTaxiPathNodesByPath.size())
{
TC_LOG_DEBUG("movement.motionmaster", "MotionMaster::MoveTaxiFlight: '%s', taxi to path Id: %u (node %u)", _owner->GetGUID().ToString().c_str(), path, pathnode);
FlightPathMovementGenerator* movement = new FlightPathMovementGenerator(pathnode);
movement->LoadPath(_owner->ToPlayer());
Mutate(movement, MOTION_SLOT_CONTROLLED);
}
else
TC_LOG_ERROR("movement.motionmaster", "MotionMaster::MoveTaxiFlight: '%s', attempted taxi to non-existing path Id: %u (node: %u)", _owner->GetGUID().ToString().c_str(), path, pathnode);
}
else
TC_LOG_ERROR("movement.motionmaster", "MotionMaster::MoveTaxiFlight: '%s', attempted taxi to path Id: %u (node: %u)", _owner->GetGUID().ToString().c_str(), path, pathnode);
}
示例3: MoveTaxiFlight
void MotionMaster::MoveTaxiFlight(uint32 path, uint32 pathnode)
{
if (_owner->GetTypeId() == TYPEID_PLAYER)
{
if (path < sTaxiPathNodesByPath.size())
{
TC_LOG_DEBUG("misc", "%s taxi to (Path %u node %u)", _owner->GetName().c_str(), path, pathnode);
FlightPathMovementGenerator* mgen = new FlightPathMovementGenerator();
mgen->LoadPath(_owner->ToPlayer());
Mutate(mgen, MOTION_SLOT_CONTROLLED);
}
else
{
TC_LOG_ERROR("misc", "%s attempt taxi to (not existed Path %u node %u)",
_owner->GetName().c_str(), path, pathnode);
}
}
else
{
TC_LOG_ERROR("misc", "Creature (Entry: %u %s) attempt taxi to (Path %u node %u)",
_owner->GetEntry(), _owner->GetGUID().ToString().c_str(), path, pathnode);
}
}
示例4: MoveTaxiFlight
void MotionMaster::MoveTaxiFlight(uint32 path, uint32 pathnode)
{
if (m_owner->GetTypeId() == TYPEID_PLAYER)
{
if (path < sTaxiPathNodesByPath.size())
{
DEBUG_FILTER_LOG(LOG_FILTER_AI_AND_MOVEGENSS, "%s taxi to (Path %u node %u)", m_owner->GetGuidStr().c_str(), path, pathnode);
FlightPathMovementGenerator* mgen = new FlightPathMovementGenerator(pathnode);
mgen->LoadPath(*(Player*)m_owner);
Mutate(mgen);
}
else
{
sLog.outError("%s attempt taxi to (nonexistent Path %u node %u)",
m_owner->GetGuidStr().c_str(), path, pathnode);
}
}
else
{
sLog.outError("%s attempt taxi to (Path %u node %u)",
m_owner->GetGuidStr().c_str(), path, pathnode);
}
}