//////////////// public override void Load(TagCompound tags) { this.Initialize(); var mymod = (StaminaMod)this.mod; int max = mymod.Config.InitialStamina; bool has = true; if (tags.ContainsKey("max_stamina") && tags.ContainsKey("has_stamina")) { max = tags.GetInt("max_stamina"); has = tags.GetBool("has_stamina"); } this.Logic = new StaminaLogic(max, has); }
//////////////// public override void Initialize() { this.Logic = new StaminaLogic(-1, false); }