关于行为树插件Behavior Designer的学习(一)_Action动作任务<20/10/2017>
动作任务(action task)可以改变游戏对象的状态,例如,运行动画的动作任务或者射击动作任务。
行为树设计师有许多默认的动作任务:
动作任务名称 | 图标 | 描述 | 参数 |
1,Behavior Tree Reference | 引用外部行为树任务:你可以保存行为树为外部行为树,然后使用该任务引用他 | ||
2,Idle | 永久等待任务:返回一个永远运行的等待状态,需要interrputed任务或者条件终止去打断他 | ||
3,Log | 日志任务:输出日志,用于调试。 | text:输出文本 logError:错误文本 | |
4,Perform Interruption | 打断任务:立刻终止一个任务,返回成功或者失败,取决与interrput任务的值(他们两个要联用) | interruptTasks interruptSuccess
| |
5,Restart Behavior Tree | 重启任务:重新启动一个新任务,同时返回成功 | behavior:将要启用的行为树,如果为空启用现在的行为树 | |
6,Send Event | 发送事件任务:发送一个事件给行为树,返回成功 | targetGameObject:目标对象 eventName:要发送的事件 | |
7,Start Behavior | 开始行为树任务:重新启动一个新任务,同时返回成功 | behavior:将要启用的行为树,如果为空启用现在的行为树 | |
8,Stop Behavior | 暂停或者终止行为树任务:暂停或者终止一个行为树 | behavior:目标行为树,如果空使用目前的行为树 pauseBehavior:是暂停还是终止 | |
9,Wait | 等待任务:等待一段时间,等待结束返回成功 | waitTime:等待时间 | |
10,Invoke Method | 方法调用任务:调用指定的方法,能够存储返回值 | targetGameObject componentName methodName parameter1 parameter2 parameter3 parameter4 storeResult | |
11,Get Field Value | 获取字段值任务:获取指定的字段值 | targetGameObject componentName fieldName fieldValue | |
12,Get Property Value | 获取属性值任务:获取指定的属性 | targetGameObject componentName propertyName propertyValue | |
13,Set Field Value | 设置字段值任务:设置指定的字段值 | targetGameObject componentName fieldName fieldValue | |
14,Set Property Value | 设置属性值任务:设置指定的属性值 | targetGameObject componentName propertyName propertyValue |