It will do things that an IDE should do!
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.
|
|
|
#include "pixelGameEngine.h"
|
|
|
|
|
|
|
|
using namespace olc;
|
|
|
|
|
|
|
|
class Example : public olc::PixelGameEngine
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
Example()
|
|
|
|
{
|
|
|
|
sAppName = "PGEIDE";
|
|
|
|
}
|
|
|
|
|
|
|
|
public:
|
|
|
|
bool OnUserCreate() override
|
|
|
|
{
|
|
|
|
std::cout<<"Created: "<<ScreenWidth()<<"x"<<ScreenHeight()<<std::endl;
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
|
|
|
|
bool OnUserUpdate(float fElapsedTime) override
|
|
|
|
{
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
|
|
|
|
bool OnUserDestroy()override{
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
|
|
|
|
void GetAnyKeyPress(olc::Key pressed)override{
|
|
|
|
}
|
|
|
|
};
|
|
|
|
|
|
|
|
int main(int argc, char** argv)
|
|
|
|
{
|
|
|
|
Example demo;
|
|
|
|
rcode code;
|
|
|
|
if (argc==3){
|
|
|
|
code=demo.Construct(std::stoi(argv[1]), std::stoi(argv[2]), 1, 1);
|
|
|
|
} else {
|
|
|
|
code=demo.Construct(1920, 1080, 1, 1);
|
|
|
|
}
|
|
|
|
if (code!=FAIL){
|
|
|
|
std::cout<<"Run"<<std::endl;
|
|
|
|
demo.Start();
|
|
|
|
}
|
|
|
|
return 0;
|
|
|
|
}
|