@SuppressWarnings("unchecked")
	public void op_skilledit(final String input, final Client client) {
		final Player player = getPlayer(client);
		final EditorData data = player.getEditorData(); 
		final Skill skill = (Skill) data.getObject("skill");

		String scmd = "";
		String sarg = "";

		if (input.indexOf(" ") != -1) {
			scmd = input.substring(0, input.indexOf(" ")).toLowerCase();
			sarg = input.substring(input.indexOf(" ") + 1, input.length());
		}
		else {
			scmd = input.substring(0, input.length()).toLowerCase();
		}

		debug("SKEDIT CMD");
		debug("srcmd: \"" + scmd + "\"");
		debug("sarg: \"" + sarg + "\"");

		if (scmd.equals("abort")) {
			// reset editor and player status
			player.setStatus((String) data.getObject("pstatus"));
			player.setEditor(Editors.NONE);

			// clear editor data
			player.setEditorData(null);

			// exit
			send("< Exiting... >", client);
		}
		else if (scmd.equals("abrv")) {
			data.setObject("abbrev", sarg);
			send("Ok.", client);
		}
		else if (scmd.equals("abbrevs")) {
		}
		else if (scmd.equals("class")) {
			if (sarg != null) {
				String[] args = sarg.split(" ");

				if (args.length > 0) {
					for (String s : args) {
						final String className = s.substring(1);
						final PClass newClass = Classes.getClass(className);

						if (data.getObject("classes") instanceof List<?>) {
							List<PClass> classes = (List<PClass>) data.getObject("classes");

							if (s.charAt(0) == '+') {
								classes.addAll(Utils.mkList(newClass));
								send("Added " + newClass + " to classes for " + (String) data.getObject("name"), client);
							}
							else if (s.charAt(0) == '-') {
								classes.remove(newClass);
								send("Removed " + newClass + " from classes for " + (String) data.getObject("name"), client);
							}
						}
					}
				}
			}
		}
		else if (scmd.equals("classes")) {
			// send list of valid class names
			send("NONE, BARBARIAN, BARD, CLERIC, DRUID, FIGHTER, MONK, PALADIN, RANGER, ROGUE, SORCERER, WIZARD, ADEPT, ARISTOCRAT, COMMONER, EXPERT, WARRIOR", client);
		}
		else if (scmd.equals("help")) {
			if (sarg.equals("")) {
				// output help information
				final List<String> output = (List<String>) Utils.mkList("Skill Editor -- Help",
						Utils.padRight("", '-', 74),
						"abort                          abort the editor (no changes will be kept)",
						"abrv                           designate abbreviated form of skill name",
						"abbrevs                        ?",
						"class                          add/remove classes that have/can use this skill",
						"classes                        list of valid class names",
						"desc <param> <new description> change/set the room description **",
						"done                           finish editing (save & exit) **",
						"help                           shows this help information",
						"name <new name>                change/set the skill name",
						"quit                           ",
						"save                           save changes to the skill (NOT IMPLEMENTED)",
						"show                           show basic information about the skill",
						"skills                         list all skills (NOT IMPLEMENTED)",
						"stat                           change the stat this skill is associated with",
						"stats                          list all stats",
						Utils.padRight("", '-', 74));
				
				client.write(output);
			}
			else {
				// output help information specific to the command name given
			}
		}
		else if (scmd.equals("name")) {
			data.setObject("name", sarg);
			send("Ok.", client);
		}
		else if (scmd.equals("quit")) {
		}
		else if (scmd.equals("save")) {
		}
		else if (scmd.equals("show")) {
			/*
			send(Utils.padRight("", '-', 80), client);
			send("   Name: " + (String) data.getObject("name"), client);
			send("     ID: " + skill.getId(), client);
			send("   Stat: " + (Ability) data.getObject("stat"), client);
			send("Classes: " + (List<PClass>) data.getObject("classes"), client);
			send(" Abbrev: " + (String) data.getObject("abbrev"), client);
			send(Utils.padRight("", '-', 80), client);
			*/
			
			final List<String> output = Utils.mkList(
					Utils.padRight("", '-', 80),
					"    Name: " + (String) data.getObject("name"),
					"      ID: " + skill.getId(),
					"    Stat: " + (Ability) data.getObject("stat"),
					" Classes: " + (List<PClass>) data.getObject("classes"),
					"  Abbrev: " + (String) data.getObject("abbrev"),
					Utils.padRight("", '-', 80)
					);
			
			send(output, client);
		}
		else if (scmd.equals("skills")) {
		}
		else if (scmd.equals("stat")) {
			// change the stat a skill is associated with
			/*
			 * TODO this command should take the short/long form of the stat
			 * name and set that stat as the primary stat for this skill
			 */
		}
		else if (scmd.equals("stats")) {
			final Ability[] abilities = rules.getAbilities();
			final StringBuilder sb = new StringBuilder();
			
			int count = 0;

			for (final Ability ab : abilities) {
				sb.append(ab.getName());

				count++;

				if (count < abilities.length) sb.append(", ");
			}

			send("Stats: " + sb.toString(), client);
			// send( "Abilities: " + sb.toString(), client );
		}
	}