namespace DaggerFramework
{
public abstract class Game
{
public abstract string ResourceRoot { get; }
///
/// Starts the game application.
/// This involves initializing the required subsystems, loading resources from the disk, and then preparing the subsystems for running in the main loop.
///
public void Start()
{
Initialize();
LoadResources();
Ready();
Run();
}
///
/// Called when it's time to initialize the subsystems.
///
public abstract void Initialize();
///
/// Called when it's time to load the application's resources, such as images or sounds.
///
protected abstract void LoadResources();
///
/// Called when it's safe to manipulate with the resources or/and systems.
///
protected abstract void Ready();
///
/// Called when everything has been readied to start the main loop.
///
protected abstract void Run();
///
/// Called when the application quits and it's safe to clean up.
///
public abstract void Shutdown();
}
}