File size: 1,084 Bytes
ce81a16
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
using Photon.Deterministic;
using System.Collections.Generic;

namespace Quantum
{
	public abstract unsafe partial class GOAPAction
	{
		public enum EResult
		{
			Continue,
			IsDone,
			IsFailed,
		}

		// PUBLIC MEMBERS

		public string    Label;

		[BotSDKHidden]
		public GOAPState Conditions;
		[BotSDKHidden]
		public GOAPState Effects;

		public bool      Interruptible;

		public abstract bool UsePlanStateValidation { get; }

		// PUBLIC METHODS

		public virtual bool ValidateAction(Frame frame, GOAPEntityContext context, GOAPState startState, out FP cost)
		{
			cost = 1;
			return true;
		}

		public virtual void ValidatePlanState(Frame frame, GOAPEntityContext context, GOAPState stateToValidate, GOAPState nextState, FP costToNextState, List<StateBackValidation> validatedStates)
		{
		}

		public virtual void Activate(Frame frame, GOAPEntityContext context)
		{
		}

		public virtual EResult Update(Frame frame, GOAPEntityContext context)
		{
			return EResult.Continue;
		}

		public virtual void Deactivate(Frame frame, GOAPEntityContext context)
		{
		}
	}
}