mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-01-07 15:46:01 +00:00
fix for detecting more that 2 players and play both with player 1 keys (#1750)
This commit is contained in:
parent
39eab0d0a9
commit
35dae6abb4
|
@ -155,6 +155,9 @@ int PS4_SYSV_ABI scePadGetFeatureReport() {
|
||||||
}
|
}
|
||||||
|
|
||||||
int PS4_SYSV_ABI scePadGetHandle(s32 userId, s32 type, s32 index) {
|
int PS4_SYSV_ABI scePadGetHandle(s32 userId, s32 type, s32 index) {
|
||||||
|
if (userId == -1) {
|
||||||
|
return ORBIS_PAD_ERROR_DEVICE_NO_HANDLE;
|
||||||
|
}
|
||||||
LOG_DEBUG(Lib_Pad, "(DUMMY) called");
|
LOG_DEBUG(Lib_Pad, "(DUMMY) called");
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
@ -246,6 +249,9 @@ int PS4_SYSV_ABI scePadMbusTerm() {
|
||||||
|
|
||||||
int PS4_SYSV_ABI scePadOpen(s32 userId, s32 type, s32 index, const OrbisPadOpenParam* pParam) {
|
int PS4_SYSV_ABI scePadOpen(s32 userId, s32 type, s32 index, const OrbisPadOpenParam* pParam) {
|
||||||
LOG_INFO(Lib_Pad, "(DUMMY) called user_id = {} type = {} index = {}", userId, type, index);
|
LOG_INFO(Lib_Pad, "(DUMMY) called user_id = {} type = {} index = {}", userId, type, index);
|
||||||
|
if (userId == -1) {
|
||||||
|
return ORBIS_PAD_ERROR_DEVICE_NO_HANDLE;
|
||||||
|
}
|
||||||
if (Config::getUseSpecialPad()) {
|
if (Config::getUseSpecialPad()) {
|
||||||
if (type != ORBIS_PAD_PORT_TYPE_SPECIAL)
|
if (type != ORBIS_PAD_PORT_TYPE_SPECIAL)
|
||||||
return ORBIS_PAD_ERROR_DEVICE_NOT_CONNECTED;
|
return ORBIS_PAD_ERROR_DEVICE_NOT_CONNECTED;
|
||||||
|
@ -346,6 +352,9 @@ int PS4_SYSV_ABI scePadReadHistory() {
|
||||||
}
|
}
|
||||||
|
|
||||||
int PS4_SYSV_ABI scePadReadState(s32 handle, OrbisPadData* pData) {
|
int PS4_SYSV_ABI scePadReadState(s32 handle, OrbisPadData* pData) {
|
||||||
|
if (handle == ORBIS_PAD_ERROR_DEVICE_NO_HANDLE) {
|
||||||
|
return ORBIS_PAD_ERROR_INVALID_HANDLE;
|
||||||
|
}
|
||||||
auto* controller = Common::Singleton<Input::GameController>::Instance();
|
auto* controller = Common::Singleton<Input::GameController>::Instance();
|
||||||
int connectedCount = 0;
|
int connectedCount = 0;
|
||||||
bool isConnected = false;
|
bool isConnected = false;
|
||||||
|
|
Loading…
Reference in a new issue