Class CutsceneScreen

java.lang.Object
com.badlogic.gdx.ScreenAdapter
com.csse3200.game.screens.CutsceneScreen
All Implemented Interfaces:
com.badlogic.gdx.Screen

public class CutsceneScreen extends com.badlogic.gdx.ScreenAdapter
The CutsceneScreen class represents the screen used during cutscenes in the game. It handles loading and displaying the cutscene, rendering the UI, and managing assets and services.
  • Constructor Details

    • CutsceneScreen

      public CutsceneScreen(GdxGame game, GdxGame.CutsceneType cutsceneVal)
      Constructor for the CutsceneScreen.
      Parameters:
      game - The main game instance.
      cutsceneVal - The cutscene value to determine which cutscene to load.
  • Method Details

    • render

      public void render(float delta)
      Renders the cutscene screen, updating the rendering system each frame.
      Specified by:
      render in interface com.badlogic.gdx.Screen
      Overrides:
      render in class com.badlogic.gdx.ScreenAdapter
      Parameters:
      delta - Time in seconds since the last frame.
    • resize

      public void resize(int width, int height)
      Handles resizing the cutscene screen and adjusting the renderer.
      Specified by:
      resize in interface com.badlogic.gdx.Screen
      Overrides:
      resize in class com.badlogic.gdx.ScreenAdapter
      Parameters:
      width - New width of the screen.
      height - New height of the screen.
    • dispose

      public void dispose()
      Disposes of the cutscene screen and all associated resources.
      Specified by:
      dispose in interface com.badlogic.gdx.Screen
      Overrides:
      dispose in class com.badlogic.gdx.ScreenAdapter
    • getCutsceneScreenDisplay

      public CutsceneScreenDisplay getCutsceneScreenDisplay()
      Gets the CutsceneScreenDisplay component for this screen.
      Returns:
      The cutscene screen display.
    • getGame

      public GdxGame getGame()
      Gets the GdxGame instance associated with this screen.
      Returns:
      The main game instance.
    • getVal

      public GdxGame.CutsceneType getVal()
      Gets the cutsceneVal value associated with this screen.
      Returns:
      The cutsceneVal value