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.
41 lines
819 B
41 lines
819 B
#define OLC_PGE_APPLICATION
|
|
#include "olcPixelGameEngine.h"
|
|
#include "PGEX_SMX.h"
|
|
using namespace olc;
|
|
|
|
class SMX_PGE : public olc::PixelGameEngine
|
|
{
|
|
PGEX_SMX smx;
|
|
public:
|
|
SMX_PGE()
|
|
{
|
|
sAppName = "SMX PGE";
|
|
}
|
|
|
|
public:
|
|
bool OnUserCreate() override
|
|
{
|
|
// Called once at the start, so create things here
|
|
return true;
|
|
}
|
|
|
|
bool OnUserUpdate(float fElapsedTime) override
|
|
{
|
|
smx.GetPanel(RIGHT,0).bHeld;
|
|
// called once per frame
|
|
for (int x = 0; x < ScreenWidth(); x++)
|
|
for (int y = 0; y < ScreenHeight(); y++)
|
|
Draw(x, y, olc::Pixel(rand() % 255, rand() % 255, rand()% 255));
|
|
return true;
|
|
}
|
|
};
|
|
|
|
|
|
int main()
|
|
{
|
|
SMX_PGE demo;
|
|
if (demo.Construct(12, 21, 50, 50))
|
|
demo.Start();
|
|
|
|
return 0;
|
|
}
|
|
|