Tested state changing
This commit is contained in:
1 parent
e8bc0903e6
commit
ea9c4054bd
7 files changed
+23
-9
No files matched your search
@@ -1,13 +1,17 @@
|
||||
#pragma once
|
||||
|
||||
namespace nf {
|
||||
class Application;
|
||||
|
||||
class IGamestate {
|
||||
public:
|
||||
virtual void onEnter() = 0;
|
||||
virtual void onEnter(Application* app) = 0;
|
||||
virtual void onExit() = 0;
|
||||
|
||||
virtual void update() = 0;
|
||||
virtual void render() = 0;
|
||||
|
||||
Application* m_app;
|
||||
private:
|
||||
//Resource identifier?
|
||||
};
|
||||
|
||||
@@ -1,15 +1,16 @@
|
||||
#pragma once
|
||||
#include "IGamestate.h"
|
||||
#include "Utility.h"
|
||||
|
||||
namespace nf {
|
||||
class IntroGamestate : public IGamestate {
|
||||
public:
|
||||
void onEnter() override;
|
||||
void onEnter(Application* app) override;
|
||||
void onExit() override;
|
||||
|
||||
void update() override;
|
||||
void render() override;
|
||||
private:
|
||||
|
||||
int counter;
|
||||
};
|
||||
}
|
||||
@@ -1,3 +1,5 @@
|
||||
//Master engine include (Is this even useful?)
|
||||
|
||||
#include "Application.h"
|
||||
#include "Application.h"
|
||||
|
||||
using namespace nf;
|
||||
Reference in new issue
Block a user