mirror of
https://github.com/hrydgard/ppsspp.git
synced 2024-11-26 23:10:38 +00:00
Check if multiplayer if connected, enforce run-behind if so
This commit is contained in:
parent
acd719448e
commit
8228e59423
@ -41,6 +41,7 @@
|
||||
#include "Core/Debugger/Breakpoints.h"
|
||||
#include "Core/HW/Display.h"
|
||||
#include "Core/MIPS/MIPS.h"
|
||||
#include "Core/HLE/sceNetAdhoc.h"
|
||||
#include "GPU/Debugger/Stepping.h"
|
||||
|
||||
#ifdef _WIN32
|
||||
@ -103,7 +104,8 @@ void Core_Stop() {
|
||||
}
|
||||
|
||||
bool Core_ShouldRunBehind() {
|
||||
return g_Config.bRunBehindPauseMenu;
|
||||
// Enforce run-behind if ad-hoc connected
|
||||
return g_Config.bRunBehindPauseMenu || __NetAdhocConnected();
|
||||
}
|
||||
|
||||
bool Core_IsStepping() {
|
||||
|
@ -126,6 +126,9 @@ static int sceNetAdhocPdpCreate(const char* mac, int port, int bufferSize, u32 f
|
||||
static int sceNetAdhocPdpSend(int id, const char* mac, u32 port, void* data, int len, int timeout, int flag);
|
||||
static int sceNetAdhocPdpRecv(int id, void* addr, void* port, void* buf, void* dataLength, u32 timeout, int flag);
|
||||
|
||||
bool __NetAdhocConnected() {
|
||||
return netAdhocInited && netAdhocctlInited && adhocctlState == ADHOCCTL_STATE_CONNECTED;
|
||||
}
|
||||
|
||||
void __NetAdhocShutdown() {
|
||||
// Kill AdhocServer Thread
|
||||
|
@ -104,6 +104,8 @@ void __NetAdhocDoState(PointerWrap &p);
|
||||
void __UpdateAdhocctlHandlers(u32 flags, u32 error);
|
||||
void __UpdateMatchingHandler(const MatchingArgs ¶ms);
|
||||
|
||||
bool __NetAdhocConnected();
|
||||
|
||||
// I have to call this from netdialog
|
||||
int sceNetAdhocctlGetState(u32 ptrToStatus);
|
||||
int sceNetAdhocctlCreate(const char * groupName);
|
||||
|
Loading…
Reference in New Issue
Block a user