#include "IWindow.hpp"
#include "Debug.hpp"
#include "LuaStateHandler.hpp"
#include "utils/Time.hpp"
#include "version.h"
#include "IInputManager.hpp"

TSE::IWindow* TSE::IWindow::lastWindow = nullptr;

bool TSE::IWindow::BaseInit() const
{
    LuaStateHandler::InitLuaState();
    Debug::Init();
    Debug::Log("TSE:" + TSE_VERSION_STRING);
    return true;
}

void TSE::IWindow::BaseUpdate() const
{
    Time::Update();
}

TSE::IWindow::~IWindow()
{
    IInputManager::instance()->Delete();
    Time::Destroy();
    Debug::Close();
}
