1
Fork 0
mirror of https://github.com/SapphireServer/Sapphire.git synced 2025-05-09 20:27:45 +00:00
sapphire/src/world/mainGameServer.cpp

29 lines
553 B
C++

#include <iostream>
#include "ServerMgr.h"
#include <Framework.h>
#include <Config/ConfigMgr.h>
Sapphire::Framework g_fw;
using namespace Sapphire;
using namespace Sapphire::World;
bool setupFramework()
{
auto pFramework = Sapphire::make_Framework();
auto pServer = std::make_shared< ServerMgr >( "config.ini", pFramework );
g_fw.set< ServerMgr >( pServer );
return true;
}
int main( int32_t argc, char* argv[] )
{
if( !setupFramework() )
return 0; // too fucking bad...
g_fw.get< ServerMgr >()->run( argc, argv );
return 0;
}