public void Consume(int index) { if (index == 0) { if (powerUps[0].cantidad > 0) { powerUps[0].Consume(); powerUps[0].cantidad -= 1; ui.Consumido(); } else { ui.SinConsumible(); } } if (index == 1) { if (powerUps[1].cantidad > 0) { powerUps[1].Consume(); powerUps[1].cantidad -= 1; ui.Consumido(); } else { ui.SinConsumible(); } } if (index == 2) { if (powerUps[2].cantidad > 0) { powerUps[2].Consume(); powerUps[2].cantidad -= 1; ui.Consumido(); } else { ui.SinConsumible(); } } }
public void Consume() { ui.Consumido(); }