载入中...
搜索中...
未找到
eve::combat::navigation::PathfinderCombatNavigationProvider类 参考final

Synchronous combat steering provider backed by the canonical map Pathfinder. 更多...

#include <PathfinderCombatNavigation.h>

类 eve::combat::navigation::PathfinderCombatNavigationProvider 继承关系图:
eve::combat::ICombatNavigationProvider

Public 成员函数

Result< CombatNavigationSteering > steer (const CombatLocomotionState &state, const CombatNavigationGoal &goal, SimulationTick tick) override
 Resolve steering for one subject without mutating locomotion state.
 
- Public 成员函数 继承自 eve::combat::ICombatNavigationProvider
virtual ~ICombatNavigationProvider ()=default
 Releases ICombatNavigationProvider resources.
 

静态 Public 成员函数

static Result< std::unique_ptr< PathfinderCombatNavigationProvider > > create (map::Pathfinder &pathfinder, PathfinderCombatNavigationConfig config)
 Validate configuration and create an owning adapter.
 

详细描述

Synchronous combat steering provider backed by the canonical map Pathfinder.

The provider borrows Pathfinder for its whole lifetime and retains no Path, locomotion state, or goal between calls. Its owner must destroy combat locomotion first (or clear the provider), then this adapter, then Pathfinder. Calls are simulation-thread-affine and must not race Pathfinder mutation.

在文件 PathfinderCombatNavigation.h 第 38 行定义.

成员函数说明

◆ create()

Result< std::unique_ptr< PathfinderCombatNavigationProvider > > eve::combat::navigation::PathfinderCombatNavigationProvider::create ( map::Pathfinder &  pathfinder,
PathfinderCombatNavigationConfig  config 
)
static

Validate configuration and create an owning adapter.

参数
pathfinderBorrowed Pathfinder that must outlive the returned provider.
configOwning world/grid projection copied into the provider.
返回
Owning provider or InvalidArgument for invalid projection data.

在文件 PathfinderCombatNavigation.cpp 第 44 行定义.

引用了 valid , 以及 eve::combat::navigation::PathfinderCombatNavigationConfig::validate().

◆ steer()

Result< CombatNavigationSteering > eve::combat::navigation::PathfinderCombatNavigationProvider::steer ( const CombatLocomotionState &  state,
const CombatNavigationGoal &  goal,
SimulationTick  tick 
)
overridevirtual

Resolve steering for one subject without mutating locomotion state.

参数
stateCurrent candidate state borrowed for this call.
goalOwning runtime goal borrowed for this call.
tickDeterministic tick being prepared.
返回
Valid steering or a structured failure that aborts the whole locomotion frame.

Steer.

实现了 eve::combat::ICombatNavigationProvider.

在文件 PathfinderCombatNavigation.cpp 第 54 行定义.

引用了 eve::combat::CombatNavigationGoal::acceptanceRadius, eve::combat::Arrived, eve::combat::navigation::PathfinderCombatNavigationConfig::cellSize, eve::Diagnostic::error(), eve::Result< T >::failure(), finite, eve::InvalidArgument, length, eve::combat::Moving, eve::NotFound, eve::combat::navigation::PathfinderCombatNavigationConfig::origin, path, eve::combat::CombatNavigationGoal::position, state, eve::Result< T >::success(), tick, eve::combat::CombatVector2::x , 以及 eve::combat::CombatVector2::z.


该类的文档由以下文件生成: