2021-01-02 13:51:50 -08:00
|
|
|
#pragma once
|
|
|
|
#include <blah.h>
|
|
|
|
#include "world.h"
|
|
|
|
|
|
|
|
using namespace Blah;
|
|
|
|
|
|
|
|
namespace TL
|
|
|
|
{
|
|
|
|
class Game
|
|
|
|
{
|
|
|
|
public:
|
2021-01-03 13:04:11 -08:00
|
|
|
static constexpr int width = 240;
|
|
|
|
static constexpr int height = 135;
|
2021-01-02 17:50:25 -08:00
|
|
|
static constexpr int tile_width = 8;
|
|
|
|
static constexpr int tile_height = 8;
|
2021-01-03 13:04:11 -08:00
|
|
|
static constexpr int columns = width / tile_width;
|
|
|
|
static constexpr int rows = height / tile_height + 1;
|
2021-01-02 17:50:25 -08:00
|
|
|
|
2021-01-02 13:51:50 -08:00
|
|
|
World world;
|
|
|
|
FrameBufferRef buffer;
|
|
|
|
Batch batch;
|
2021-01-03 13:04:11 -08:00
|
|
|
Point room;
|
2021-01-02 13:51:50 -08:00
|
|
|
|
2021-01-03 13:04:11 -08:00
|
|
|
void load_room(Point cell);
|
2021-01-02 13:51:50 -08:00
|
|
|
void startup();
|
|
|
|
void shutdown();
|
|
|
|
void update();
|
|
|
|
void render();
|
2021-01-02 16:20:01 -08:00
|
|
|
|
|
|
|
private:
|
|
|
|
bool m_draw_colliders;
|
2021-01-02 13:51:50 -08:00
|
|
|
};
|
|
|
|
}
|