Owner-thread authority for hurtboxes, hitbox catalogs and sweep hits. 更多...
#include <MeleeHit.h>
Public 成员函数 | |
| void | setPoseSource (IMeleePoseSource &source) noexcept |
| Install a borrowed pose source that must outlive this runtime or be cleared. | |
| void | clearPoseSource () noexcept |
| Remove the borrowed pose source. | |
| Result< void > | registerHitbox (MeleeHitboxDefinition definition) |
| Register or replace one hitbox catalog entry after full validation. | |
| Result< void > | registerHurtbox (MeleeHurtboxDefinition definition) |
| Register or replace one hurtbox after full validation. | |
| Result< void > | clearHurtboxes (SubjectRef subject) |
| Remove every hurtbox owned by a subject. | |
| Result< void > | setHurtboxPose (SubjectRef subject, std::string_view hurtboxId, MeleePose pose) |
| Update the current world pose of one registered hurtbox. | |
| Result< void > | armHitbox (SubjectRef subject, std::string_view hitboxId, action::ActionExecutionId execution) |
| Arm one hitbox while a Montage window owns it. | |
| Result< void > | disarmHitbox (SubjectRef subject, std::string_view hitboxId, action::ActionExecutionId execution) |
| Disarm one hitbox window and forget its per-target hit memory. | |
| Result< MeleeHitFrame > | advance (SimulationTick tick) |
| Sample poses for armed hitboxes, sweep against hurtboxes and emit unique hits. | |
| Result< std::vector< DamageOutcome > > | applyHits (DamageRuntime &damage, std::map< std::string, CombatState, std::less<> > &states, const std::vector< MeleeHitEvent > &hits, const std::map< std::string, double, std::less<> > &bodyPartMultipliers={}) const |
| Apply owning hit events through DamageRuntime using a mutable state map. | |
| std::size_t | armedCount () const noexcept |
| Number of armed hitbox windows. | |
| std::size_t | hurtboxCount () const noexcept |
| Number of registered hurtboxes. | |
详细描述
Owner-thread authority for hurtboxes, hitbox catalogs and sweep hits.
Active hitboxes are armed by string id while a Montage hitbox window is open. Geometry poses come from an optional pose source; missing poses fail the arm or advance observably. Hits are de-duplicated per (execution, hitbox, target, hurtbox) until the window exits.
在文件 MeleeHit.h 第 132 行定义.
成员函数说明
◆ advance()
| Result< MeleeHitFrame > eve::combat::MeleeHitRuntime::advance | ( | SimulationTick | tick | ) |
Sample poses for armed hitboxes, sweep against hurtboxes and emit unique hits.
- 参数
-
tick Deterministic simulation tick; must be non-decreasing.
在文件 MeleeHit.cpp 第 257 行定义.
引用了 eve::Applied, eve::Diagnostic::error(), eve::Result< T >::failure(), eve::combat::MeleeHitFrame::hits, eve::InvalidArgument, key, memory, normal, eve::NotFound, pose, eve::combat::IMeleePoseSource::pose(), eve::combat::MeleeHitEvent::source, eve::Status::success(), eve::Result< T >::success(), eve::combat::MeleeHitFrame::tick, tick, valid , 以及 eve::detail::StrongUint64< Tag >::value().
◆ applyHits()
| Result< std::vector< DamageOutcome > > eve::combat::MeleeHitRuntime::applyHits | ( | DamageRuntime & | damage, |
| std::map< std::string, CombatState, std::less<> > & | states, | ||
| const std::vector< MeleeHitEvent > & | hits, | ||
| const std::map< std::string, double, std::less<> > & | bodyPartMultipliers = {} |
||
| ) | const |
Apply owning hit events through DamageRuntime using a mutable state map.
在文件 MeleeHit.cpp 第 316 行定义.
引用了 eve::Applied, eve::combat::DamageRuntime::apply(), eve::Diagnostic::error(), found, hit, eve::NotFound, request, eve::combat::DamageRequest::source , 以及 eve::Status::success().
◆ armedCount()
|
inlinenoexcept |
Number of armed hitbox windows.
在文件 MeleeHit.h 第 171 行定义.
◆ armHitbox()
| Result< void > eve::combat::MeleeHitRuntime::armHitbox | ( | SubjectRef | subject, |
| std::string_view | hitboxId, | ||
| action::ActionExecutionId | execution | ||
| ) |
Arm one hitbox while a Montage window owns it.
- 备注
- Requires a pose source. The first pose becomes both previous and current.
在文件 MeleeHit.cpp 第 214 行定义.
引用了 eve::Applied, eve::Diagnostic::error(), eve::Result< T >::failure(), eve::InvalidArgument, key, eve::NotFound, pose, eve::combat::IMeleePoseSource::pose(), subject, eve::Status::success(), eve::Result< T >::success(), valid , 以及 eve::detail::StrongUint64< Tag >::value().
◆ clearHurtboxes()
| Result< void > eve::combat::MeleeHitRuntime::clearHurtboxes | ( | SubjectRef | subject | ) |
Remove every hurtbox owned by a subject.
在文件 MeleeHit.cpp 第 190 行定义.
引用了 eve::Applied, eve::Diagnostic::error(), eve::Result< T >::failure(), eve::InvalidArgument, subject, eve::Status::success() , 以及 eve::Result< T >::success().
◆ clearPoseSource()
|
inlinenoexcept |
Remove the borrowed pose source.
在文件 MeleeHit.h 第 137 行定义.
◆ disarmHitbox()
| Result< void > eve::combat::MeleeHitRuntime::disarmHitbox | ( | SubjectRef | subject, |
| std::string_view | hitboxId, | ||
| action::ActionExecutionId | execution | ||
| ) |
Disarm one hitbox window and forget its per-target hit memory.
在文件 MeleeHit.cpp 第 242 行定义.
引用了 eve::Applied, found, key, eve::NoOp, subject, eve::Status::success(), eve::Result< T >::success() , 以及 eve::detail::StrongUint64< Tag >::value().
◆ hurtboxCount()
|
inlinenoexcept |
Number of registered hurtboxes.
在文件 MeleeHit.h 第 173 行定义.
◆ registerHitbox()
| Result< void > eve::combat::MeleeHitRuntime::registerHitbox | ( | MeleeHitboxDefinition | definition | ) |
Register or replace one hitbox catalog entry after full validation.
在文件 MeleeHit.cpp 第 173 行定义.
引用了 eve::Applied, eve::Status::success(), eve::Result< T >::success() , 以及 valid.
◆ registerHurtbox()
| Result< void > eve::combat::MeleeHitRuntime::registerHurtbox | ( | MeleeHurtboxDefinition | definition | ) |
Register or replace one hurtbox after full validation.
在文件 MeleeHit.cpp 第 180 行定义.
引用了 eve::Applied, key, state, eve::Status::success(), eve::Result< T >::success() , 以及 valid.
◆ setHurtboxPose()
| Result< void > eve::combat::MeleeHitRuntime::setHurtboxPose | ( | SubjectRef | subject, |
| std::string_view | hurtboxId, | ||
| MeleePose | pose | ||
| ) |
Update the current world pose of one registered hurtbox.
在文件 MeleeHit.cpp 第 203 行定义.
引用了 eve::Applied, eve::Diagnostic::error(), eve::Result< T >::failure(), found, eve::NotFound, pose, subject, eve::Status::success(), eve::Result< T >::success() , 以及 valid.
◆ setPoseSource()
|
inlinenoexcept |
Install a borrowed pose source that must outlive this runtime or be cleared.
在文件 MeleeHit.h 第 135 行定义.
引用了 source.
该类的文档由以下文件生成:
- src/modules/combat/MeleeHit.h
- src/modules/combat/MeleeHit.cpp