public boolean line(int x0, int y0, int x1, int y1){
		int w = x1 - x0;
		int h = y1 - y0;
		int dx1 = 0, dy1 = 0, dx2 = 0, dy2 = 0;
		if(w < 0) dx1 = -1;
		else if(w > 0) dx1 = 1;
		if(h < 0) dy1 = -1;
		else if(h > 0) dy1 = 1;
		if(w < 0) dx2 = -1;
		else if(w > 0) dx2 = 1;
		
		int longest = Math.abs(w);
		int shortest = Math.abs(h);
		
		if(!(longest > shortest)){
			longest =Math.abs(h);
			shortest = Math.abs(w);
			if(h < 0) dy2 = -1;
			else if(h > 0) dy2 = 1;
			dx2 = 0;
		}
		
		int numerator = longest >> 1;
		for(int i = 0; i <= longest; i++){
			if(dungeon.getTile(x0 / 32, y0 / 32).solid) return true;	
			numerator += shortest;
			if(!(numerator < longest)){
				numerator -= longest;
				x0 += dx1;
				y0 += dy1;
			}else{
				x0 += dx2;
				y0 += dy2;
			}
		}
		return false;
	}