2
0
mirror of https://github.com/Laupetin/OpenAssetTools.git synced 2025-09-06 16:57:25 +00:00

ZoneCodeGenerator: Add possibility to define custom actions that should be performed after loading a certain Structure

This commit is contained in:
Jan
2020-01-03 17:25:10 +01:00
parent c995a12001
commit bdb0958c16
11 changed files with 251 additions and 30 deletions

View File

@@ -0,0 +1,17 @@
using System;
using System.Collections.Generic;
namespace ZoneCodeGenerator.Domain
{
class CustomAction
{
public string ActionName { get; }
public IList<DataType> ParameterTypes { get; }
public CustomAction(string actionName, IEnumerable<DataType> parameterTypes)
{
ActionName = actionName;
ParameterTypes = new List<DataType>(parameterTypes);
}
}
}

View File

@@ -1,9 +1,5 @@
using System;
using System.Collections.Generic;
using System.Linq;
using ZoneCodeGenerator.Domain.FastFileStructure;
using System.Collections.Generic;
using ZoneCodeGenerator.Generating.Computations;
using ZoneCodeGenerator.Persistence;
namespace ZoneCodeGenerator.Domain.Information
{
@@ -31,6 +27,8 @@ namespace ZoneCodeGenerator.Domain.Information
public bool ArrayReferenceExists { get; set; }
public bool ReferenceFromNonDefaultNormalBlockExists { get; set; }
public CustomAction PostLoadAction { get; set; }
public bool IsLeaf { get; set; }
public List<MemberInformation> NameChain { get; set; }
@@ -47,6 +45,7 @@ namespace ZoneCodeGenerator.Domain.Information
ReferenceFromNonDefaultNormalBlockExists = false;
Usages = new List<StructureInformation>();
OrderedMembers = new List<MemberInformation>();
PostLoadAction = null;
IsLeaf = true;
NameChain = null;
}