+add Test Trail Effect to Main Character #18
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
测试代码在 ActorFactory 的 93行;
新增了 Resource/Effect/ 目录,用来做 Effect 相关的 Prefab;
Resources/Effect/Trail.prefab 用来做 拖尾表现;
将来拖尾类型多了可以考虑这里多创建 prefab ,或者代码里动态创建。比如trail 的宽度可以再prefab 里调整会比较方便;
Resources/Effect 目录下的 prefab 用 Effect/Common/CommonEffectFactory.cs 收口加载 ;
核心的代码是 在 Effect/Common/TrailController.cs。
这里有几个核心参数: