mirror of
https://github.com/Detanup01/gbe_fork.git
synced 2024-12-25 09:54:15 +08:00
run the background thread for callbacks earlier inside Steam_Client::ConnectToGlobalUser()
since some games don't call `SteamAPI_RunCallbacks()` or `SteamAPI_ManualDispatch_RunFrame()` or `Steam_BGetCallback()` hence all run_callbacks() will never run, also networking callbacks won't run
This commit is contained in:
parent
0b5d38ae7e
commit
392305c1e3
@ -140,7 +140,8 @@ public:
|
|||||||
bool server_init = false;
|
bool server_init = false;
|
||||||
std::thread background_keepalive;
|
std::thread background_keepalive;
|
||||||
bool steamclient_server_inited = false;
|
bool steamclient_server_inited = false;
|
||||||
std::atomic<unsigned long long> last_cb_run;
|
std::atomic<unsigned long long> last_cb_run{};
|
||||||
|
std::atomic_bool cb_run_active = false;
|
||||||
|
|
||||||
unsigned steam_pipe_counter = 1;
|
unsigned steam_pipe_counter = 1;
|
||||||
std::map<HSteamPipe, enum Steam_Pipe> steam_pipes;
|
std::map<HSteamPipe, enum Steam_Pipe> steam_pipes;
|
||||||
@ -299,7 +300,7 @@ public:
|
|||||||
void RegisterCallResult( class CCallbackBase *pCallback, SteamAPICall_t hAPICall);
|
void RegisterCallResult( class CCallbackBase *pCallback, SteamAPICall_t hAPICall);
|
||||||
void UnregisterCallResult( class CCallbackBase *pCallback, SteamAPICall_t hAPICall);
|
void UnregisterCallResult( class CCallbackBase *pCallback, SteamAPICall_t hAPICall);
|
||||||
|
|
||||||
void RunCallbacks(bool runClientCB, bool runGameserverCB, bool runBackgroundThread=true);
|
void RunCallbacks(bool runClientCB, bool runGameserverCB);
|
||||||
void setAppID(uint32 appid);
|
void setAppID(uint32 appid);
|
||||||
void userLogIn();
|
void userLogIn();
|
||||||
void serverInit();
|
void serverInit();
|
||||||
|
File diff suppressed because it is too large
Load Diff
Loading…
x
Reference in New Issue
Block a user