private void spellButtonMouseClicked(MouseEvent evt) {
		if (spellButton.isSelected()) {
			HashSet<String> possibilities = new HashSet<String>();
			for (Spell spell : ((CanMagicAttack)onTurn).getAvailableSpells()) {
				if (CombatHandler.canCastSpell((CanMagicAttack)onTurn, spell)) {
					possibilities.add(spell.getName());
				}
			}
			String s = (String)JOptionPane.showInputDialog(
			                    this,
			                    "Select a spell.",
			                    "Select a spell",
			                    JOptionPane.PLAIN_MESSAGE,
			                    null,
			                    possibilities.toArray(),
			                    "ham");

			//If a string was returned, say so.
			if ((s != null) && (s.length() > 0)) {
				for (Spell spell : ((CanMagicAttack)onTurn).getAvailableSpells()) {
					if (spell.getName() == s) {
						currentSpell = spell;
						setNewActionState(ActionState.OnSpellCasting, spell.getTargetRange(), spell.getDistanceRange());
					}
				}
			}
		} else {
			setNewActionState(ActionState.OnNavigate, 0, 0);
		}
	}