Validates a typed selection and fans one command out in formation order. 更多...
#include <RTSSystems.h>
静态 Public 成员函数 | |
| static Result< FanOutReceipt > | fanOut (std::span< const ecs::EntityHandle > unitHandles, const CommandSpec &command, const FormationSpec &formation) |
| Submit one command to every selected live Unit. | |
详细描述
Validates a typed selection and fans one command out in formation order.
This is a command boundary, not a new order implementation. It writes only the selected units' generic OrderComponent and performs no structural ECS mutation while its validation View is alive.
在文件 RTSSystems.h 第 216 行定义.
成员函数说明
◆ fanOut()
|
static |
Submit one command to every selected live Unit.
- 参数
-
unitHandles Generation-checked handles in player selection order. command Common Move/Attack/Build/Gather command. formation Deterministic target offset policy.
- 返回
- Accepted order ids in selection order, or a failure with no partially accepted command exposed to the caller.
在文件 RTSFormation.cpp 第 124 行定义.
引用了 a, b, best, entity, eve::Diagnostic::error(), eve::Result< T >::failure(), handle, identity, index, eve::InvalidArgument, eve::InvariantViolation, inView, left, local, p, point, position, radius, resolved, right, selected, eve::rts::FormationSpec::spacing, eve::StaleHandle, eve::rts::CommandSpec::target, targets, unit, eve::rts::FormationSpec::validate(), eve::rts::CommandSpec::validate(), view , 以及 x.
被这些函数引用 eve::rts::RTSCommandLog::apply(), eve::rts::RTS::fanOut(), eve::rts::AISystem::step() , 以及 eve::rts::RTS::submitMovementGroup().
该类的文档由以下文件生成:
- src/modules/rts/RTSSystems.h
- src/modules/rts/RTSFormation.cpp