mirror of
https://github.com/HowestDAE/dae16-VerhulstBram.git
synced 2025-12-18 07:29:21 +01:00
Fix precompiled headers
Added edge detection (if it works :/)
This commit is contained in:
27
Game/Levels/MainMenu/MainMenuLevel.cpp
Normal file
27
Game/Levels/MainMenu/MainMenuLevel.cpp
Normal file
@@ -0,0 +1,27 @@
|
||||
#include "pch.h"
|
||||
#include "MainMenuLevel.h"
|
||||
|
||||
#include "colors.h"
|
||||
#include "utils.h"
|
||||
MainMenuLevel::MainMenuLevel(Camera* camera): Level(camera) {
|
||||
m_TextMotherload = new Text("Motherload", "fonts/verdana.ttf", 20, Colors::WHITE);
|
||||
m_TextNewGame = new Text("New Game", "fonts/verdana.ttf", 20, Colors::WHITE);
|
||||
m_TextExit = new Text("Exit", "fonts/verdana.ttf", 20, Colors::WHITE);
|
||||
}
|
||||
MainMenuLevel::~MainMenuLevel() {
|
||||
delete m_TextMotherload;
|
||||
delete m_TextNewGame;
|
||||
delete m_TextExit;
|
||||
}
|
||||
void MainMenuLevel::Update(float elapsedSec) {
|
||||
}
|
||||
void MainMenuLevel::Draw() const {
|
||||
m_TextMotherload->Draw(Point2f(200, 100));
|
||||
m_TextNewGame->Draw(Point2f(200, 200));
|
||||
m_TextExit->Draw(Point2f(200, 300));
|
||||
|
||||
}
|
||||
void MainMenuLevel::MouseMove(const Point2f& mousePos) {
|
||||
}
|
||||
void MainMenuLevel::ProcessImGui() {
|
||||
}
|
||||
21
Game/Levels/MainMenu/MainMenuLevel.h
Normal file
21
Game/Levels/MainMenu/MainMenuLevel.h
Normal file
@@ -0,0 +1,21 @@
|
||||
#pragma once
|
||||
#include "Text.h"
|
||||
#include "Levels/Level.h"
|
||||
|
||||
class MainMenuLevel : public Level
|
||||
{
|
||||
public:
|
||||
|
||||
MainMenuLevel(Camera* camera);
|
||||
virtual ~MainMenuLevel();
|
||||
|
||||
void Update(float elapsedSec) override;
|
||||
void Draw() const override;
|
||||
void MouseMove(const Point2f& mousePos) override;
|
||||
void ProcessImGui() override;
|
||||
|
||||
private:
|
||||
Text* m_TextMotherload;
|
||||
Text* m_TextNewGame;
|
||||
Text* m_TextExit;
|
||||
};
|
||||
Reference in New Issue
Block a user