X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;f=src%2Fapp%2FRuntime.cpp;h=6a4c783ef50222b0664fe61489e3b7443674ff70;hb=745729c1935276e6f49d108a0a465214aa93c3cb;hp=8ddab262e483e34b5f24f01fab08d13b5f9702dd;hpb=b7d09e1e35ef90282c97509e0020b20db3c7ea9f;p=blank.git diff --git a/src/app/Runtime.cpp b/src/app/Runtime.cpp index 8ddab26..6a4c783 100644 --- a/src/app/Runtime.cpp +++ b/src/app/Runtime.cpp @@ -1,5 +1,7 @@ #include "Runtime.hpp" +#include "init.hpp" + #include #include #include @@ -49,6 +51,8 @@ void Runtime::ReadArgs(int argc, const char *const *argv) { config.interface.mouse_disabled = true; } else if (strcmp(arg + 2, "no-hud") == 0) { config.interface.visual_disabled = true; + } else if (strcmp(arg + 2, "no-audio") == 0) { + config.interface.audio_disabled = true; } else { cerr << "unknown option " << arg << endl; error = true; @@ -109,9 +113,6 @@ void Runtime::ReadArgs(int argc, const char *const *argv) { } } } - } else if (isdigit(arg[0])) { - // positional number interpreted as -n - n = strtoul(arg, nullptr, 10); } else { cerr << "unable to interpret argument " << i << " (" << arg << ")" << endl; @@ -142,7 +143,8 @@ int Runtime::Execute() { return 1; } - Application app(config); + Init init(config.doublebuf, config.multisampling); + Application app(init.window, config); switch (mode) { default: case NORMAL: