Anvil Engine
Loading...
Searching...
No Matches
IGame Class Referenceabstract

#include <IGame.h>

Inheritance diagram for IGame:
CGame

Public Member Functions

virtual ~IGame ()
virtual void OnInit (AEngine *engine)=0
virtual void OnUpdate (float dt)=0
virtual void OnShutdown ()=0
virtual glm::mat4 GetViewMatrix ()=0

Constructor & Destructor Documentation

◆ ~IGame()

virtual IGame::~IGame ( )
inlinevirtual

Virtual destructor for the IGame interface class. This ensures proper cleanup of derived class objects when deleted through a base class pointer. Virtual destructors are essential in polymorphic classes to prevent resource leaks.

Member Function Documentation

◆ GetViewMatrix()

virtual glm::mat4 IGame::GetViewMatrix ( )
pure virtual

Get the current view matrix for rendering.

Returns
glm::mat4 representing the current view transformation matrix

Implemented in CGame.

◆ OnInit()

virtual void IGame::OnInit ( AEngine * engine)
pure virtual

Initialize the game with the provided engine instance.

Parameters
enginePointer to the engine instance that the game will use for initialization

Implemented in CGame.

◆ OnShutdown()

virtual void IGame::OnShutdown ( )
pure virtual

Perform cleanup and shutdown operations for the game. This method is called when the game is being terminated.

Implemented in CGame.

◆ OnUpdate()

virtual void IGame::OnUpdate ( float dt)
pure virtual

Update the game state with the time elapsed since the last frame.

Parameters
dtTime delta in seconds since the last update

Implemented in CGame.


The documentation for this class was generated from the following file: