This commit is contained in:
Asecave
2021-06-23 23:11:29 +02:00
5 changed files with 9 additions and 1 deletions

View File

@@ -18,6 +18,7 @@ public class Tile extends Knoten {
public static final int WALL_TOP = 1; public static final int WALL_TOP = 1;
public static final int WALL_BOTTOM = 2; public static final int WALL_BOTTOM = 2;
public static final int STONE_WALL = 3; public static final int STONE_WALL = 3;
public static final int STONE_WALL_BOTTOM = 4;
private Bild img; // Bild, das gerendert wird private Bild img; // Bild, das gerendert wird
private int id; // Die id dises Tiles private int id; // Die id dises Tiles
@@ -63,6 +64,8 @@ public class Tile extends Knoten {
return "/res/images/tiles/wall_bottom.png"; return "/res/images/tiles/wall_bottom.png";
case STONE_WALL: case STONE_WALL:
return "/res/images/tiles/stone_wall.png"; return "/res/images/tiles/stone_wall.png";
case STONE_WALL_BOTTOM:
return "/res/images/tiles/stone_wall_bottom.png";
} }
return null; return null;
} }

View File

@@ -5,6 +5,7 @@ import main.entities.Entity;
import main.entities.Player; import main.entities.Player;
import main.entities.Snake; import main.entities.Snake;
import main.entities.Spider; import main.entities.Spider;
import main.maps.Corridor;
import main.maps.Map; import main.maps.Map;
import main.maps.TestMap; import main.maps.TestMap;

View File

@@ -12,7 +12,11 @@ public class Corridor extends Map {
if((y == 0 || x == 0 || y == 9 || x == 4) && x != 2 ) { if((y == 0 || x == 0 || y == 9 || x == 4) && x != 2 ) {
map[x][y] = new Tile(3, x, y); map[x][y] = new Tile(3, x, y);
add(map[x][y]); add(map[x][y]);
} else { } else if(y == 1 && (x != 0 || x != 4)&& x != 2 ) {
map[x][y] = new Tile(4, x, y);
add(map[x][y]);
}
else {
map[x][y] = new Tile(0, x, y); map[x][y] = new Tile(0, x, y);
add(map[x][y]); add(map[x][y]);
} }

Binary file not shown.

Before

Width:  |  Height:  |  Size: 381 B

After

Width:  |  Height:  |  Size: 481 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 342 B