You've already forked taptap2024_GJ_chidouren
init
This commit is contained in:
@@ -0,0 +1,29 @@
|
||||
# FSMController.onStateChange
|
||||
|
||||
|
||||
### 事件:
|
||||
|
||||
public Action onStateChange;
|
||||
|
||||
### 说明:
|
||||
|
||||
状态改变的回调 参数1:状态机名称 参数2:当前状态
|
||||
|
||||
### 代码示例:
|
||||
|
||||
> ```none
|
||||
>
|
||||
>public class TestFSMController : MonoBehaviour
|
||||
>{
|
||||
> private FSMController controller;
|
||||
>
|
||||
> private void Start()
|
||||
> {
|
||||
> controller.onStateChange += (stateMachineName,currentStateName) =>
|
||||
> {
|
||||
> Debug.LogFormat("状态改变 状态配置名称:{0} 当前状态名称:{1}",stateMachineName,currentStateName);
|
||||
> };
|
||||
> }
|
||||
>}
|
||||
>
|
||||
> ```
|
||||
Reference in New Issue
Block a user