A repository that sets up a C++ Project with the olcPixelGameEngine already loaded.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

37 lines
565 B

#define OLC_PGE_APPLICATION
#include "pixelGameEngine.h"
#include <unordered_map>
#include "Block.h"
class Example : public olc::PixelGameEngine
{
public:
Example()
{
sAppName = "Example";
}
public:
std::unordered_map<int,Block> Blocks;
bool OnUserCreate() override
{
// Called once at the start, so create things here
Blocks[126]=Block(25,10,255,255,255);
return true;
}
bool OnUserUpdate(float fElapsedTime) override
{
return true;
}
};
int main()
{
Example demo;
if (demo.Construct(256, 240, 4, 4))
demo.Start();
return 0;
}