private bool MaxReached(ManaIngredients ingredientType) { if (m_ManaDictionary[ingredientType] == 0) { return(true); } else { return(false); } }
public bool AddIngredient(ManaIngredients ingredientType) { if (MaxReached(ingredientType)) { return(false); } else { m_ManaDictionary[ingredientType]--; return(true); } }
private bool HandleIngredientAddition(ManaIngredients addedIngredient) { if (m_currentMana.AddIngredient(addedIngredient)) { m_signsText[addedIngredient].text = m_currentMana.GetCountByIngredient(addedIngredient).ToString(); m_scoreController.GoodIngredientAdded(); //maybe do ssomething with the 3d object return(true); } else { m_scoreController.BadIngredientAdded(); return(false); } }
public int GetCountByIngredient(ManaIngredients ingredient) { return(m_ManaDictionary[ingredient]); }
public bool AddIngredient(ManaIngredients addedIngredient) { return(HandleIngredientAddition(addedIngredient)); }