public bool IsGood(int type) { int stepTapped = bc.getStepClosest(); if (level.getActionFromBeat(stepTapped) == type) { this.successStep.Add(stepTapped); notifySucces(); return(true); } else if (level.getActionFromBeat(stepTapped - 1) == type) { this.successStep.Add(stepTapped - 1); notifySucces(); return(true); } else { if (level.getActionFromBeat(stepTapped + 1) == type) { this.successStep.Add(stepTapped + 1); notifySucces(); return(true); } } addFail(); return(false); }
public bool isGood(int type) { int stepTapped = level.beatCounter.getStepClosest(); if (stepTapped >= 0 && level.getActionFromBeat(stepTapped) == type) { this.successStep.Add(stepTapped); return(true); } failuresCount++; return(false); }