-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathStateNode.cs
More file actions
58 lines (43 loc) · 1.27 KB
/
Copy pathStateNode.cs
File metadata and controls
58 lines (43 loc) · 1.27 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
using System;
using System.Collections.Generic;
using System.Text;
namespace GameCore {
public abstract class StateNode {
//节点类型
public virtual NodeTypeEnum NodeType => NodeTypeEnum.BasicNode;
///<summary>
///激活节点时调用,仅仅调用一次
///</summary>
public virtual void OnEnter() {
}
///<summary>
///准备节点所需信息,每次加载都会调用
///</summary>
public virtual void OnPrepare() {
}
///<summary>
///准备开始,每次加载都会调用,且一定在所有激活节点的prepare完成后才调用
///</summary>
public virtual void OnBegin() {
}
///<summary>
///退出节点时调用,仅仅调用一次
///</summary>
public virtual void OnFinish() {
}
}
public class OneOutNode : StateNode {
}
public class MultOutNode : StateNode {
}
public class StartNode : StateNode{
public override NodeTypeEnum NodeType => NodeTypeEnum.StartNode;
}
public class EndNode : StateNode {
public override NodeTypeEnum NodeType => NodeTypeEnum.EndNode;
}
class InPort {
}
class OutPort {
}
}