public void OnClick() { PlayerScript.AddCustomerToPlayerQueue(m_number); //to get every time since the customers can move, but this still might need to be //fixed later Vector3 loc = gameObject.transform.position; PlayerScript.AddLocation(new Vector3(loc.x - 5, loc.y + 1, loc.z)); }
public void OnClick() { if (RestaurantMain.restMain.currentState == State.upgrades) { if (utensil.upgradeNum >= Variables.MAX_UTENSIL_UPGRADE) { Debug.Log("It is the max upgrade already!"); } else { RestaurantMain.restMain.UtensilUpgradeClicked(this); } } else if (RestaurantMain.restMain.currentState == State.gameplay) { PlayerScript.AddCookingToolToPlayerQueue(this); Vector3 loc = gameObject.transform.position; PlayerScript.AddLocation(new Vector3(loc.x - 0.5f, loc.y - 1, loc.z)); } }