using Newtonsoft.Json; using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace NewHorizons.External.Modules.Conditionals { [JsonObject] public class ConditionalCheckInfo { /// /// The conditions that must be met for the check to pass /// public ConditionalCheckConditionsInfo check; /// /// The effects of the check if it passes /// public ConditionalCheckEffectsInfo then; } [JsonObject] public class ConditionalCheckConditionsInfo { /// /// The check will only pass if all of these dialogue conditions are set /// public string[] allConditionsSet; /// /// The check will only pass if any of these dialogue conditions are set /// public string[] anyConditionsSet; /// /// The check will only pass if all of these persistent conditions are set /// public string[] allPersistentConditionsSet; /// /// The check will only pass if any of these persistent conditions are set /// public string[] anyPersistentConditionsSet; /// /// The check will only pass if all of these ship log facts are revealed /// public string[] allFactsRevealed; /// /// The check will only pass if any of these ship log facts are revealed /// public string[] anyFactsRevealed; /// /// If the check should pass only if the conditions are not met /// public bool invert; } [JsonObject] public class ConditionalCheckEffectsInfo { /// /// The check will set these dialogue conditions if it passes /// public string[] setConditions; /// /// The check will unset these dialogue conditions if it passes /// public string[] unsetConditions; /// /// The check will set these persistent conditions if it passes /// public string[] setPersistentConditions; /// /// The check will unset these persistent conditions if it passes /// public string[] unsetPersistentConditions; /// /// The check will reveal these ship log facts if it passes /// public string[] revealFacts; /// /// If the check should undo its effects if the conditions are not met anymore (unset the set conditions, etc.). Note: ship log facts cannot currently be unrevealed. /// public bool reversible; } }