/**
 * \file client.cpp
 * \brief Univerxel client
 * \author Maelys Bois
 * \version 0.0.1
 *
 * Univerxel standalone client program.
 */

#define STANDALONE 1
#include "client/Client.hpp"
#include "core/standalone_config.hpp"
#include "core/utils/tracy.hpp"
#include "version.h"

/// Entry point
int main(int argc, char *argv[]){
    LOG("Univerxel client " << UNIVERXEL_VERSION);

#if TRACY_ENABLE
    LOG("Profiling !");
#endif

    auto options = config::standalone_options<config::client::options>(argc > 1 ? argv[1] : config::DEFAULT_FILE);
    options.save();

#if TRACY_ENABLE
    tracy::SetThreadName("Main");
#endif

    auto client = Client(options.get());
    client.run(nullptr);

    options.save();

    return 0;
}