五张牌!

This commit is contained in:
SoulliesOfficial
2025-10-30 04:21:28 -04:00
parent 2906206f0c
commit 4c7e5c397b
171 changed files with 2168 additions and 41 deletions

View File

@@ -72,10 +72,24 @@ namespace Continentis.MainGame
current[attributeName] = originalAttribute;
}
}
public void ModifyAttribute(string attributeName,
public void ModifyAttribute(string attributeName,
float numericChange, float percentageChangeOfAccumulation, float percentChangeOfMultiplication)
{
if (!current.ContainsKey(attributeName))
{
if (attributeName.Contains("Multiplier"))
{
current[attributeName] = 1f;
}
else
{
current[attributeName] = 0f;
}
Debug.Log($"{attributeName} is not found in current attributes, use default value");
}
current[attributeName] += numericChange;
current[attributeName] = (1 + percentageChangeOfAccumulation) * current[attributeName];
current[attributeName] = percentChangeOfMultiplication * current[attributeName];