keyword + animation

This commit is contained in:
SoulliesOfficial
2025-10-27 07:04:34 -04:00
parent c3c4a17440
commit 2906206f0c
40 changed files with 512 additions and 384 deletions

View File

@@ -13,12 +13,7 @@ namespace Continentis.MainGame
static BuffTextInterpreter()
{
TextInterpreter = new Interpreter();
TextInterpreter.SetFunction("Value", new Func<float, string>((cv) => DynamicTextInterpreter.GetValue(cv, false)));
TextInterpreter.SetFunction("Value", new Func<float, float, string>((cv, bv) => DynamicTextInterpreter.GetValue(cv, bv, true, false)));
TextInterpreter.SetFunction("Value",
new Func<float, float, bool, string>((cv, bv, high) => DynamicTextInterpreter.GetValue(cv, bv, high, false)));
TextInterpreter.SetFunction("Value",
new Func<float, float, bool, bool, string>((cv, bv, high, percent) => DynamicTextInterpreter.GetValue(cv, bv, high, percent)));
DynamicTextInterpreter.InitializeInterpreter(ref TextInterpreter);
foreach (KeyValuePair<string, InterpretedKeyword> keyword in MainGameManager.Instance.keywordData.interpretedKeywords)
{
@@ -34,7 +29,7 @@ namespace Continentis.MainGame
TextInterpreter.SetFunction("ParameterFloat", new Func<string, string>((paramName) => GetParameterFloat(buff, paramName)));
TextInterpreter.SetFunction("ParameterString", new Func<string, string>((paramName) => GetParameterString(buff, paramName)));
string descriptionToParse = buff.contentSubmodule.originalFunctionText;
string result = DynamicTextInterpreter.Parse(TextInterpreter, descriptionToParse, new List<string>(), new List<string>());
string result = DynamicTextInterpreter.Parse(TextInterpreter, descriptionToParse);
buff.contentSubmodule.interpretedFunctionText = result;
}
}