protected File createFile(String username) {
return new File(mudSpacePlayerLocation + username + ".xml");
}
public void movePlayerToLocation(Player player) throws InstantiationException, FileNotFoundException, CompilationFailedException {
Container room;
logger.info("moving player to location.");
ObjectLocation location = player.getContainerLocation();
room = (Container) getObjectRegistry().getMudObject(location.getBeanId());
if (room == null) {
logger.info("loading container");
room = (Container) load(location);
}
if (room == null) {
throw new InstantiationException("container was null!");
}
logger.info("adding player to container");
room.addMudObject(player);
}