Class WallFactory

java.lang.Object
com.csse3200.game.entities.factories.WallFactory

public class WallFactory extends Object
Factory for creating static vertical wall entities. Walls: - Are static (do not move) - Block movement - Are not considered "ground" (player shouldn't stand on them) - Use distinct textures from platforms
  • Method Details

    • createWall

      public static Entity createWall(float x, float y, float width, float height, String texture)
      Create a vertical wall at world position (x, y) with given size (width, height). Texture is scaled to fit the specified size.
      Parameters:
      x - World X (bottom-left)
      y - World Y (bottom-left)
      width - Wall width in world units
      height - Wall height in world units
      texture - Wall texture
      Returns:
      Configured wall entity
    • createTiledWall

      public static Entity createTiledWall()
      Create a vertical wall at world position (x, y) with given size (width, height). Texture is scaled to fit the specified size.
      Returns:
      Configured wall entity