载入中...
搜索中...
未找到
SkillMeshEffect.h
浏览该文件的文档.
1#pragma once
2
5
6#include <glm/vec3.hpp>
7
8#include <memory>
9
10namespace eve::stylize {
11
14
24public:
27
30
32 [[nodiscard]] SkillMeshEffectKind kind() const noexcept { return kind_; }
34 [[nodiscard]] MeshEffectInstance& effect() noexcept { return *effect_; }
36 [[nodiscard]] const MeshEffectInstance& effect() const noexcept { return *effect_; }
38 [[nodiscard]] bool hasTrail() const noexcept { return trail_ != nullptr; }
40 [[nodiscard]] TrailEmitter& trail();
42 [[nodiscard]] const TrailEmitter& trail() const;
43
45 void bindTarget(MeshEffectTargetHandle target);
47 void play() noexcept;
49 void stop(float fadeOutSeconds = 0.f);
51 void update(float dtSeconds);
53 [[nodiscard]] bool isFinished() const noexcept;
55 [[nodiscard]] TrailAppendResult appendBlade(glm::vec3 root, glm::vec3 tip);
56
57private:
59 std::unique_ptr<MeshEffectInstance> effect_;
60 std::unique_ptr<TrailEmitter> trail_;
61};
62
63} // namespace eve::stylize
LogicalId target
int tip
Definition AnimSmr.cpp:121
int root
Definition AnimSmr.cpp:119
#define EVENGINE_API_WORLD
Definition Export.h:109
TokenKind kind
float f
Runtime state for a shader effect attached to a renderable mesh.
Definition MeshEffect.h:40
Owning runtime composition for one common gameplay mesh effect.
const MeshEffectInstance & effect() const noexcept
Return the owned primary mesh-effect runtime.
bool hasTrail() const noexcept
Return whether this recipe includes a weapon ribbon.
SkillMeshEffect(const SkillMeshEffect &)=delete
SkillMeshEffectKind kind() const noexcept
Return the immutable built-in recipe identity.
SkillMeshEffect & operator=(const SkillMeshEffect &)=delete
MeshEffectInstance & effect() noexcept
Return the owned primary mesh-effect runtime.
Deterministic CPU sampler and ribbon mesh generator for weapon trails.
Definition TrailEffect.h:55
SkillMeshEffectKind
Built-in gameplay-oriented mesh VFX compositions.
TrailAppendResult
Result of attempting to append one weapon-edge sample.
Definition TrailEffect.h:24