final fix.

This commit is contained in:
Keleborn 2026-04-16 23:03:08 -07:00
parent f02b6c83f8
commit 233790a430
4 changed files with 6 additions and 5 deletions

View File

@ -24,8 +24,8 @@ class Position;
#define ANGLE_120_DEG (2.f * static_cast<float>(M_PI) / 3.f)
// Default acceptable path types for GeneratePath
constexpr uint32 DEFAULT_PATH_ACCEPT_MASK = 0x01 /*PATHFIND_NORMAL*/ | 0x04 /*PATHFIND_INCOMPLETE*/;
uint32 typeOk = PATHFIND_NORMAL | PATHFIND_INCOMPLETE | PATHFIND_FARFROMPOLY;
constexpr uint32 DEFAULT_PATH_ACCEPT_MASK = PATHFIND_NORMAL | PATHFIND_INCOMPLETE;
constexpr uint32 RELAXED_PATH_ACCEPT_MASK = PATHFIND_NORMAL | PATHFIND_INCOMPLETE | PATHFIND_FARFROMPOLY;
struct PathResult
{

View File

@ -472,7 +472,7 @@ bool NewRpgTravelFlightAction::Execute(Event /*event*/)
if (bot->GetDistance(data.fromPos) > INTERACTION_DISTANCE)
return MoveFarTo(data.fromPos);
Creature* flightMaster = ObjectAccessor::GetCreature(*bot, data.fromFlightMasterGuid);
Creature* flightMaster = ObjectAccessor::GetCreature(*bot, data.fromFlightMaster );
if (!flightMaster || !flightMaster->IsAlive())
{
botAI->rpgInfo.ChangeToIdle();

View File

@ -76,7 +76,7 @@ void NewRpgInfo::Reset()
{
data = Idle{};
startT = getMSTime();
travelPlan.Reset();
ClearTravel();
}
void NewRpgInfo::SetMoveFarTo(WorldPosition pos)

View File

@ -76,9 +76,10 @@ struct NewRpgInfo
uint32 stuckTs{0};
uint32 stuckAttempts{0};
WorldPosition moveFarPos;
// Travel Node System
TravelPlan travelPlan;
bool HasActiveTravelPlan() const { return travelPlan.IsActive(); }
void ClearTravel();
void ClearTravel() { travelPlan.Reset(); }
using RpgData = std::variant<
Idle,