mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-08 11:38:21 +02:00
26 lines
485 B
C++
26 lines
485 B
C++
#include "HeadlessApp.h"
|
|
#include "platform/PlatformHelper.h"
|
|
|
|
USING_NS_BF;
|
|
|
|
void HeadlessApp::Init()
|
|
{
|
|
mRunning = true;
|
|
|
|
Beefy::String exePath;
|
|
BfpGetStrHelper(exePath, [](char* outStr, int* inOutStrSize, BfpResult* result)
|
|
{
|
|
BfpSystem_GetExecutablePath(outStr, inOutStrSize, (BfpSystemResult*)result);
|
|
});
|
|
|
|
mInstallDir = GetFileDir(exePath) + "/";
|
|
}
|
|
|
|
void HeadlessApp::Run()
|
|
{
|
|
while (mRunning)
|
|
{
|
|
BfpThread_Sleep((uint32)(1000 / mRefreshRate));
|
|
Process();
|
|
}
|
|
}
|