mirror of
https://github.com/liyunfan1223/mod-playerbots.git
synced 2026-06-20 15:39:25 +02:00
Compare commits
3 Commits
9ca851f837
...
1e07ef3d02
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
1e07ef3d02 | ||
|
|
34600888a2 | ||
|
|
c7eb1f7238 |
@ -1772,6 +1772,13 @@ void TravelNodeMap::generateTaxiPaths()
|
|||||||
TravelNodePath travelPath(0.1f, totalTime, (uint8)TravelNodePathType::flightPath, i, true);
|
TravelNodePath travelPath(0.1f, totalTime, (uint8)TravelNodePathType::flightPath, i, true);
|
||||||
travelPath.setPath(ppath);
|
travelPath.setPath(ppath);
|
||||||
|
|
||||||
|
// Preserve existing walk paths — taxi-position lookup can resolve to
|
||||||
|
// a non-FM node (innkeeper, subzone), and overwriting its walk path
|
||||||
|
// with a flight path makes the walkable connection disappear.
|
||||||
|
if (startNode->hasPathTo(endNode) &&
|
||||||
|
startNode->getPathTo(endNode)->getPathType() == TravelNodePathType::walk)
|
||||||
|
continue;
|
||||||
|
|
||||||
startNode->setPathTo(endNode, travelPath);
|
startNode->setPathTo(endNode, travelPath);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -2193,6 +2200,9 @@ void TravelNodeMap::saveNodeStore()
|
|||||||
PlayerbotsDatabase.CommitTransaction(pathTrans);
|
PlayerbotsDatabase.CommitTransaction(pathTrans);
|
||||||
|
|
||||||
LOG_INFO("playerbots", ">> Saved {} travelNode Paths, {} points.", paths, points);
|
LOG_INFO("playerbots", ">> Saved {} travelNode Paths, {} points.", paths, points);
|
||||||
|
LOG_INFO("playerbots",
|
||||||
|
">> NOTE: writes are queued ASYNC. Run '.server shutdown 1' to flush "
|
||||||
|
"the queue; killing the process now will lose pending rows.");
|
||||||
}
|
}
|
||||||
|
|
||||||
void TravelNodeMap::LoadNodeStore()
|
void TravelNodeMap::LoadNodeStore()
|
||||||
@ -2211,7 +2221,7 @@ void TravelNodeMap::LoadNodeStore()
|
|||||||
|
|
||||||
TravelNode* node = addNode(WorldPosition(fields[2].Get<uint32>(), fields[3].Get<float>(),
|
TravelNode* node = addNode(WorldPosition(fields[2].Get<uint32>(), fields[3].Get<float>(),
|
||||||
fields[4].Get<float>(), fields[5].Get<float>()),
|
fields[4].Get<float>(), fields[5].Get<float>()),
|
||||||
fields[1].Get<std::string>(), true);
|
fields[1].Get<std::string>(), true, false);
|
||||||
|
|
||||||
if (fields[6].Get<bool>())
|
if (fields[6].Get<bool>())
|
||||||
node->setLinked(true);
|
node->setLinked(true);
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user