public void DecrementInt(string intName) { if (ReflectionHelper.GetFieldInfo(typeof(PlayerData), intName) != null) { ModHooks.SetPlayerInt(intName, this.GetIntInternal(intName) - 1); } }
public void IntAdd(string intName, int amount) { if (ReflectionHelper.GetFieldInfo(typeof(PlayerData), intName) != null) { ModHooks.SetPlayerInt(intName, this.GetIntInternal(intName) + amount); return; } Debug.Log("PlayerData: Could not find field named " + intName + ", check variable name exists and FSM variable string is correct."); }
public void SetInt(string intName, int value) { ModHooks.SetPlayerInt(intName, value); }