public void moveEntity(Entity entity, int xEnd, int yEnd) throws Exception{
		if(!containedEntities.contains(entity)){
			throw new Exception("The entity: "+entity.toString()+" is not located on this map.");
		}

		if(gameMap[entity.getXTileCoordinate()][entity.getYTileCoordinate()] != entity){
			throw new Exception("According to this map, a different entity at the given entities location ("+entity.getXTileCoordinate()+","+entity.getYTileCoordinate()+") already exists.");
		}
		
		if(this.validPlacement(xEnd, yEnd, entity)){
			//clean up the current occupied tiles.
			int width = entity.getWidthInTiles();
			int height = entity.getHeightInTiles();
			int x = entity.getXTileCoordinate();
			int y = entity.getYTileCoordinate();
			for(int i = 0; i < height; i++){
				for(int c = 0; c < width; c++){
					gameMap[c+x][y-i] = null;
				}
			}
			this.placeEntity(xEnd, yEnd, entity);
		}
	}