Allow the creation of recursive HTNs (#30138)

Allow recursive HTNs
This commit is contained in:
osjarw
2024-07-30 05:18:53 +03:00
committed by GitHub
parent cc3d6441be
commit 669cc55ba4
4 changed files with 21 additions and 0 deletions

View File

@@ -3,4 +3,10 @@ namespace Content.Server.NPC.HTN;
[ImplicitDataDefinitionForInheritors]
public abstract partial class HTNTask
{
/// <summary>
/// Limit the amount of tasks the planner considers. Exceeding this value sleeps the NPC and throws an exception.
/// The expected way to hit this limit is with badly written recursive tasks.
/// </summary>
[DataField]
public int MaximumTasks = 1000;
}