String mode = args[0].toLowerCase();
if (mode.equals("global")) {
player.setChat(new GlobalChat(player));
} else if (mode.equals("dimension")) {
Dimension dim = player.getDimension();
if (args.length > 1 && Dimension.get(args[1]) != Dimension.LIMBO) {
dim = Dimension.get(args[1]);
}
player.setChat(new DimensionChat(player, dim));