Skip to content

constructigogo/M2ENGINE

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

66 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Installation


M2Engine can be used as a library or as an app (the latter is not recommanded but possible)

To install it as a library, simply clone the repo to your library folder in your project, or add it as a git submodule like the following :

cd [your library folder]
git submodule add https://github.com/constructigogo/M2ENGINE.git
git submodule update --init --recursive -f

M2Engine is made to be used as a CMake subdirectory. to add it, simply put the following inside your own CMakeList.txt

add_subdirectory([your library folder]/M2Engine/)

Usage


M2Engine will look for the shaders folder at your project root

To create an App, use the following include, and create a child class inheriting from App

#include "[your library folder]/M2ENGINE/Engine/App.h"

to simply test that everything is working, you can use the following main :

#include "[your library folder]/M2ENGINE/Core.h"

class TestApp : public App {
public:
    TestApp(int x, int y, const char string[8]) : App(x, y, string) {
    }

    void init() override {
        App::init();
        currentCamera = new OCamera();
    }
};


int _main_(int, char**) { return 0;}

int main(int _argc, const char* const* _argv)
{
    TestApp application(1024, 768, "useless");

    application.init();
    application.run();
    application.cleanup();
    return 0;
}

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published