psvita networking (Experimental)
This commit is contained in:
@@ -13,7 +13,7 @@
|
||||
#include "..\..\..\Minecraft.World\LevelType.h"
|
||||
#include "..\..\DLCTexturePack.h"
|
||||
|
||||
#ifdef __PSVITA__
|
||||
#if !defined(DISABLE_PSN) && defined(__PSVITA__)
|
||||
#include "PSVita\Network\SQRNetworkManager_AdHoc_Vita.h"
|
||||
#endif
|
||||
|
||||
@@ -1044,7 +1044,7 @@ void UIScene_CreateWorldMenu::CreateGame(UIScene_CreateWorldMenu* pClass, DWORD
|
||||
#endif
|
||||
|
||||
bool isClientSide = ProfileManager.IsSignedInLive(ProfileManager.GetPrimaryPad()) && pClass->m_MoreOptionsParams.bOnlineGame;
|
||||
#ifdef __PSVITA__
|
||||
#if !defined DISABLE_PSN && defined __PSVITA__
|
||||
if(CGameNetworkManager::usingAdhocMode())
|
||||
{
|
||||
if(SQRNetworkManager_AdHoc_Vita::GetAdhocStatus())// && pClass->m_MoreOptionsParams.bOnlineGame)
|
||||
|
||||
@@ -201,7 +201,7 @@ void UIScene_DLCMainMenu::tick()
|
||||
{
|
||||
UIScene::tick();
|
||||
|
||||
#if defined(__PS3__) || defined(__ORBIS__) || defined (__PSVITA__)
|
||||
#if !defined(DISABLE_PSN) && (defined(__PS3__) || defined(__ORBIS__) || defined (__PSVITA__))
|
||||
if((m_bCategoriesShown==false) && (app.GetCommerceCategoriesRetrieved()))
|
||||
{
|
||||
// disable the timer display on this menu
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
#include "Common\Network\Sony\SonyHttp.h"
|
||||
#endif
|
||||
|
||||
#ifdef __PSVITA__
|
||||
#if !defined(DISABLE_PSN) && defined(__PSVITA__)
|
||||
#include "PSVita\Network\SonyCommerce_Vita.h"
|
||||
#endif
|
||||
|
||||
@@ -335,7 +335,7 @@ void UIScene_DLCOffersMenu::tick()
|
||||
{
|
||||
UIScene::tick();
|
||||
|
||||
#if defined(__PS3__) || defined(__ORBIS__) || defined (__PSVITA__)
|
||||
#if !defined(DISABLE_PSN) && (defined(__PS3__) || defined(__ORBIS__) || defined (__PSVITA__))
|
||||
|
||||
if(m_bAddAllDLCButtons)
|
||||
{
|
||||
@@ -506,7 +506,7 @@ void UIScene_DLCOffersMenu::tick()
|
||||
}
|
||||
else
|
||||
{
|
||||
#ifdef __PSVITA__
|
||||
#if !defined(DISABLE_PSN) && defined(__PSVITA__)
|
||||
// MGH - fixes bug 5768 on Vita - should be extended properly to work for other platforms
|
||||
if((SonyCommerce_Vita::getPurchasabilityUpdated()) && app.GetCommerceProductListRetrieved()&& app.GetCommerceProductListInfoRetrieved() && m_iTotalDLC > 0)
|
||||
{
|
||||
|
||||
@@ -532,7 +532,7 @@ int UIScene_InGameInfoMenu::ViewInvites_SignInReturned(void *pParam,bool bContin
|
||||
#elif defined(__PS3__)
|
||||
int ret = sceNpBasicRecvMessageCustom(SCE_NP_BASIC_MESSAGE_MAIN_TYPE_INVITE, SCE_NP_BASIC_RECV_MESSAGE_OPTIONS_INCLUDE_BOOTABLE, SYS_MEMORY_CONTAINER_ID_INVALID);
|
||||
app.DebugPrintf("sceNpBasicRecvMessageCustom return %d ( %08x )\n", ret, ret);
|
||||
#else // __PSVITA__
|
||||
#elif !defined(DISABLE_PSN) // __PSVITA__
|
||||
SQRNetworkManager_Vita::RecvInviteGUI();
|
||||
#endif
|
||||
}
|
||||
|
||||
@@ -458,7 +458,7 @@ void UIScene_JoinMenu::JoinGame(UIScene_JoinMenu* pClass)
|
||||
#ifndef DISABLE_PSN
|
||||
isSignedInLive = ProfileManager.IsSignedInLive(ProfileManager.GetPrimaryPad());
|
||||
#endif
|
||||
#ifdef __PSVITA__
|
||||
#if !defined DISABLE_PSN && defined __PSVITA__
|
||||
if(CGameNetworkManager::usingAdhocMode() && SQRNetworkManager_AdHoc_Vita::GetAdhocStatus())
|
||||
isSignedInLive = true;
|
||||
#endif
|
||||
|
||||
@@ -1550,7 +1550,7 @@ void UIScene_LoadMenu::StartGameFromSave(UIScene_LoadMenu* pClass, DWORD dwLocal
|
||||
}
|
||||
|
||||
bool isClientSide = ProfileManager.IsSignedInLive(ProfileManager.GetPrimaryPad()) && pClass->m_MoreOptionsParams.bOnlineGame;
|
||||
#ifdef __PSVITA__
|
||||
#if !defined DISABLE_PSN && defined __PSVITA__
|
||||
if(CGameNetworkManager::usingAdhocMode())
|
||||
{
|
||||
if(SQRNetworkManager_AdHoc_Vita::GetAdhocStatus())// && pClass->m_MoreOptionsParams.bOnlineGame)
|
||||
|
||||
@@ -181,7 +181,7 @@ UIScene_LoadOrJoinMenu::UIScene_LoadOrJoinMenu(int iPad, void *initData, UILayer
|
||||
|
||||
Initialise();
|
||||
|
||||
#ifdef __PSVITA__
|
||||
#if !defined DISABLE_PSN && defined __PSVITA__
|
||||
if(CGameNetworkManager::usingAdhocMode() && SQRNetworkManager_AdHoc_Vita::GetAdhocStatus())
|
||||
{
|
||||
g_NetworkManager.startAdhocMatching(); // create the client matching context and clear out the friends list
|
||||
@@ -1552,7 +1552,7 @@ void UIScene_LoadOrJoinMenu::CheckAndJoinGame(int gameIndex)
|
||||
return;
|
||||
}
|
||||
|
||||
#ifdef __PSVITA__
|
||||
#if !defined DISABLE_PSN && defined __PSVITA__
|
||||
if(CGameNetworkManager::usingAdhocMode() && !SQRNetworkManager_AdHoc_Vita::GetAdhocStatus())
|
||||
{
|
||||
// not connected to adhoc anymore, must have connected back to PSN to buy texture pack so sign in again
|
||||
@@ -2225,6 +2225,9 @@ int UIScene_LoadOrJoinMenu::MustSignInTexturePack(void *pParam,int iPad,C4JStora
|
||||
{
|
||||
UIScene_LoadOrJoinMenu* pClass = (UIScene_LoadOrJoinMenu*)pParam;
|
||||
|
||||
#ifdef DISABLE_PSN
|
||||
UIScene_LoadOrJoinMenu::MustSignInReturnedTexturePack(pClass, true, iPad);
|
||||
#else
|
||||
if(result==C4JStorage::EMessage_ResultAccept)
|
||||
{
|
||||
SQRNetworkManager_Vita::AttemptPSNSignIn(&UIScene_LoadOrJoinMenu::MustSignInReturnedTexturePack, pClass);
|
||||
@@ -2234,6 +2237,7 @@ int UIScene_LoadOrJoinMenu::MustSignInTexturePack(void *pParam,int iPad,C4JStora
|
||||
pClass->m_bIgnoreInput = false;
|
||||
}
|
||||
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
@@ -740,7 +740,7 @@ int UIScene_MainMenu::CreateLoad_SignInReturned(void *pParam, bool bContinue, in
|
||||
if(ProfileManager.IsFullVersion())
|
||||
{
|
||||
bool bSignedInLive = ProfileManager.IsSignedInLive(iPad);
|
||||
#ifdef __PSVITA__
|
||||
#if !defined DISABLE_PSN && defined __PSVITA__
|
||||
if(CGameNetworkManager::usingAdhocMode())
|
||||
{
|
||||
if(SQRNetworkManager_AdHoc_Vita::GetAdhocStatus())
|
||||
@@ -1327,7 +1327,7 @@ void UIScene_MainMenu::RunPlayGame(int iPad)
|
||||
{
|
||||
// are we offline?
|
||||
bool bSignedInLive = ProfileManager.IsSignedInLive(iPad);
|
||||
#ifdef __PSVITA__
|
||||
#if !defined DISABLE_PSN && defined __PSVITA__
|
||||
if(app.GetGameSettings(ProfileManager.GetPrimaryPad(),eGameSetting_PSVita_NetworkModeAdhoc) == true)
|
||||
{
|
||||
CGameNetworkManager::setAdhocMode(true);
|
||||
|
||||
@@ -1703,12 +1703,16 @@ int UIScene_SkinSelectMenu::MustSignInReturned(void *pParam,int iPad,C4JStorage:
|
||||
{
|
||||
if(result==C4JStorage::EMessage_ResultAccept)
|
||||
{
|
||||
#ifdef DISABLE_PSN
|
||||
UIScene_SkinSelectMenu::PSNSignInReturned(pParam, true, iPad);
|
||||
#else
|
||||
#ifdef __PS3__
|
||||
SQRNetworkManager_PS3::AttemptPSNSignIn(&UIScene_SkinSelectMenu::PSNSignInReturned, pParam,true);
|
||||
#elif defined __PSVITA__
|
||||
SQRNetworkManager_Vita::AttemptPSNSignIn(&UIScene_SkinSelectMenu::PSNSignInReturned, pParam,true);
|
||||
#elif defined __ORBIS__
|
||||
SQRNetworkManager_Orbis::AttemptPSNSignIn(&UIScene_SkinSelectMenu::PSNSignInReturned, pParam,true);
|
||||
#endif
|
||||
#endif
|
||||
}
|
||||
return 0;
|
||||
|
||||
Reference in New Issue
Block a user