public Transition transitionCreate(State from, State to) {
		if (currentStep == TRANSITIONS_TO_SINGLE_FINAL) {
			if (automaton.getFinalStates()[0] != to) {
				JOptionPane.showMessageDialog(frame,
						"Transitions must go to the new final state!",
						"Bad Destination", JOptionPane.ERROR_MESSAGE);
				return null;
			}
			if (!drawer.isSelected(from)) {
				JOptionPane.showMessageDialog(frame,
						"Transitions must come from an old final state!",
						"Bad Source", JOptionPane.ERROR_MESSAGE);
				return null;
			}
			Transition t = new FSATransition(from, to, "");
			drawer.removeSelected(from);
			automaton.addTransition(t);
			frame.repaint();
			if (drawer.numberSelected() == 0) {
				nextStep();
			}
			return t;
		}
		if (currentStep == CREATE_EMPTY_TRANSITIONS) {
			if (automaton.getTransitionsFromStateToState(from, to).length != 0) {
				JOptionPane.showMessageDialog(frame,
						"Transitions must go between"
								+ "states with no transitions!",
						"Transition Already Exists", JOptionPane.ERROR_MESSAGE);
				return null;
			}
			Transition t = FSAToRegularExpressionConverter.addTransitionOnEmptySet(from, to, automaton);
			remaining--;
			nextStep();
			frame.repaint();
			return t;
		}
		outOfOrder();
		return null;
	}