Remove server encryption
This commit is contained in:
@@ -119,143 +119,6 @@ NavMeshSettings:
|
||||
debug:
|
||||
m_Flags: 0
|
||||
m_NavMeshData: {fileID: 0}
|
||||
--- !u!1 &31289686
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 31289687}
|
||||
- component: {fileID: 31289689}
|
||||
- component: {fileID: 31289688}
|
||||
m_Layer: 5
|
||||
m_Name: Text (TMP)
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!224 &31289687
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 31289686}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children: []
|
||||
m_Father: {fileID: 603486473}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 1, y: 1}
|
||||
m_AnchoredPosition: {x: 0, y: 0}
|
||||
m_SizeDelta: {x: 0, y: 0}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!114 &31289688
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 31289686}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Material: {fileID: 0}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_RaycastTarget: 1
|
||||
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
|
||||
m_Maskable: 1
|
||||
m_OnCullStateChanged:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
m_text: You are on a self-built instance of the game. You will not be able to access
|
||||
any server endpoints as a result.
|
||||
m_isRightToLeft: 0
|
||||
m_fontAsset: {fileID: 11400000, guid: 4fd546dd0900395408d2de20f5025882, type: 2}
|
||||
m_sharedMaterial: {fileID: -1476194838487357290, guid: 4fd546dd0900395408d2de20f5025882, type: 2}
|
||||
m_fontSharedMaterials: []
|
||||
m_fontMaterial: {fileID: 0}
|
||||
m_fontMaterials: []
|
||||
m_fontColor32:
|
||||
serializedVersion: 2
|
||||
rgba: 4294967295
|
||||
m_fontColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_enableVertexGradient: 0
|
||||
m_colorMode: 3
|
||||
m_fontColorGradient:
|
||||
topLeft: {r: 1, g: 1, b: 1, a: 1}
|
||||
topRight: {r: 1, g: 1, b: 1, a: 1}
|
||||
bottomLeft: {r: 1, g: 1, b: 1, a: 1}
|
||||
bottomRight: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_fontColorGradientPreset: {fileID: 0}
|
||||
m_spriteAsset: {fileID: 0}
|
||||
m_tintAllSprites: 0
|
||||
m_StyleSheet: {fileID: 0}
|
||||
m_TextStyleHashCode: -1183493901
|
||||
m_overrideHtmlColors: 0
|
||||
m_faceColor:
|
||||
serializedVersion: 2
|
||||
rgba: 4294967295
|
||||
m_fontSize: 24
|
||||
m_fontSizeBase: 24
|
||||
m_fontWeight: 400
|
||||
m_enableAutoSizing: 0
|
||||
m_fontSizeMin: 18
|
||||
m_fontSizeMax: 72
|
||||
m_fontStyle: 0
|
||||
m_HorizontalAlignment: 2
|
||||
m_VerticalAlignment: 512
|
||||
m_textAlignment: 65535
|
||||
m_characterSpacing: 0
|
||||
m_wordSpacing: 0
|
||||
m_lineSpacing: 0
|
||||
m_lineSpacingMax: 0
|
||||
m_paragraphSpacing: 0
|
||||
m_charWidthMaxAdj: 0
|
||||
m_TextWrappingMode: 1
|
||||
m_wordWrappingRatios: 0.4
|
||||
m_overflowMode: 0
|
||||
m_linkedTextComponent: {fileID: 0}
|
||||
parentLinkedComponent: {fileID: 0}
|
||||
m_enableKerning: 0
|
||||
m_ActiveFontFeatures: 6e72656b
|
||||
m_enableExtraPadding: 0
|
||||
checkPaddingRequired: 0
|
||||
m_isRichText: 1
|
||||
m_EmojiFallbackSupport: 1
|
||||
m_parseCtrlCharacters: 1
|
||||
m_isOrthographic: 1
|
||||
m_isCullingEnabled: 0
|
||||
m_horizontalMapping: 0
|
||||
m_verticalMapping: 0
|
||||
m_uvLineOffset: 0
|
||||
m_geometrySortingOrder: 0
|
||||
m_IsTextObjectScaleStatic: 0
|
||||
m_VertexBufferAutoSizeReduction: 0
|
||||
m_useMaxVisibleDescender: 1
|
||||
m_pageToDisplay: 1
|
||||
m_margin: {x: 0, y: 0, z: 0, w: 0}
|
||||
m_isUsingLegacyAnimationComponent: 0
|
||||
m_isVolumetricText: 0
|
||||
m_hasFontAssetChanged: 0
|
||||
m_baseMaterial: {fileID: 0}
|
||||
m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
|
||||
--- !u!222 &31289689
|
||||
CanvasRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 31289686}
|
||||
m_CullTransparentMesh: 1
|
||||
--- !u!1 &40776219
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -1859,101 +1722,8 @@ MonoBehaviour:
|
||||
exitButton: {fileID: 1354600018}
|
||||
updateText: {fileID: 673338280}
|
||||
updateButton: {fileID: 1292044491}
|
||||
selfBuiltPanel: {fileID: 603486472}
|
||||
profileButton: {fileID: 1895205574}
|
||||
profilePrefab: {fileID: 3162524169402907368, guid: ed502784d1f0b48ee8e614eb6d09f2fb, type: 3}
|
||||
--- !u!1 &603486472
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 603486473}
|
||||
- component: {fileID: 603486475}
|
||||
- component: {fileID: 603486474}
|
||||
- component: {fileID: 603486476}
|
||||
m_Layer: 5
|
||||
m_Name: SelfBuiltPanel
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 0
|
||||
--- !u!224 &603486473
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 603486472}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children:
|
||||
- {fileID: 31289687}
|
||||
m_Father: {fileID: 1263503583}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 1, y: 0}
|
||||
m_AnchorMax: {x: 1, y: 0}
|
||||
m_AnchoredPosition: {x: -170, y: 103.5}
|
||||
m_SizeDelta: {x: 300, y: 175}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!114 &603486474
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 603486472}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Material: {fileID: 0}
|
||||
m_Color: {r: 0.28235295, g: 0.28235295, b: 0.28235295, a: 1}
|
||||
m_RaycastTarget: 1
|
||||
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
|
||||
m_Maskable: 1
|
||||
m_OnCullStateChanged:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
m_Sprite: {fileID: 10907, guid: 0000000000000000f000000000000000, type: 0}
|
||||
m_Type: 1
|
||||
m_PreserveAspect: 0
|
||||
m_FillCenter: 1
|
||||
m_FillMethod: 4
|
||||
m_FillAmount: 1
|
||||
m_FillClockwise: 1
|
||||
m_FillOrigin: 0
|
||||
m_UseSpriteMesh: 0
|
||||
m_PixelsPerUnitMultiplier: 1
|
||||
--- !u!222 &603486475
|
||||
CanvasRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 603486472}
|
||||
m_CullTransparentMesh: 1
|
||||
--- !u!114 &603486476
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 603486472}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 9c3738bf0236e043c9bdf9972b8a7375, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
frequency: 8
|
||||
minSize: 1
|
||||
maxSize: 1.1
|
||||
--- !u!1 &673338277
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -3031,7 +2801,6 @@ RectTransform:
|
||||
- {fileID: 1401523578}
|
||||
- {fileID: 673338278}
|
||||
- {fileID: 989689724}
|
||||
- {fileID: 603486473}
|
||||
- {fileID: 319334212}
|
||||
- {fileID: 1895205571}
|
||||
m_Father: {fileID: 0}
|
||||
|
||||
@@ -36,12 +36,12 @@ public class AccountChangePassword : MonoBehaviour
|
||||
}
|
||||
changePasswordBackButton.interactable = false;
|
||||
changePasswordSubmitButton.interactable = false;
|
||||
EncryptedWWWForm dataForm = new();
|
||||
WWWForm dataForm = new();
|
||||
dataForm.AddField("oldpassword", changePasswordCurrentPasswordInput.text);
|
||||
dataForm.AddField("newpassword", changePasswordNewPasswordInput.text);
|
||||
dataForm.AddField("token", BazookaManager.Instance.GetAccountSession());
|
||||
dataForm.AddField("username", BazookaManager.Instance.GetAccountName());
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "changeAccountPassword.php", dataForm.form);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "changeAccountPassword.php", dataForm);
|
||||
request.SetRequestHeader("Requester", "BerryDashClient");
|
||||
request.SetRequestHeader("ClientVersion", Application.version);
|
||||
request.SetRequestHeader("ClientPlatform", Application.platform.ToString());
|
||||
@@ -53,7 +53,7 @@ public class AccountChangePassword : MonoBehaviour
|
||||
Tools.UpdateStatusText(changePasswordStatusText, "Failed to make HTTP request", Color.red);
|
||||
return;
|
||||
}
|
||||
string response = SensitiveInfo.Decrypt(request.downloadHandler.text, SensitiveInfo.SERVER_RECEIVE_TRANSFER_KEY);
|
||||
string response = request.downloadHandler.text;
|
||||
if (response == "-999")
|
||||
{
|
||||
Tools.UpdateStatusText(changePasswordStatusText, "Server error while fetching data", Color.red);
|
||||
|
||||
@@ -29,12 +29,12 @@ public class AccountChangeUsername : MonoBehaviour
|
||||
{
|
||||
changeUsernameBackButton.interactable = false;
|
||||
changeUsernameSubmitButton.interactable = false;
|
||||
EncryptedWWWForm dataForm = new();
|
||||
WWWForm dataForm = new();
|
||||
dataForm.AddField("oldusername", changeUsernameCurrentUsernameInput.text);
|
||||
dataForm.AddField("newusername", changeUsernameNewUsernameInput.text);
|
||||
dataForm.AddField("token", BazookaManager.Instance.GetAccountSession());
|
||||
dataForm.AddField("username", BazookaManager.Instance.GetAccountName());
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "changeAccountUsername.php", dataForm.form);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "changeAccountUsername.php", dataForm);
|
||||
request.SetRequestHeader("Requester", "BerryDashClient");
|
||||
request.SetRequestHeader("ClientVersion", Application.version);
|
||||
request.SetRequestHeader("ClientPlatform", Application.platform.ToString());
|
||||
@@ -46,7 +46,7 @@ public class AccountChangeUsername : MonoBehaviour
|
||||
Tools.UpdateStatusText(changeUsernameStatusText, "Failed to make HTTP request", Color.red);
|
||||
return;
|
||||
}
|
||||
string response = SensitiveInfo.Decrypt(request.downloadHandler.text, SensitiveInfo.SERVER_RECEIVE_TRANSFER_KEY);
|
||||
string response = request.downloadHandler.text;
|
||||
if (response == "-999")
|
||||
{
|
||||
Tools.UpdateStatusText(changeUsernameStatusText, "Server error while fetching data", Color.red);
|
||||
|
||||
@@ -49,11 +49,11 @@ public class AccountLoggedIn : MonoBehaviour
|
||||
loggedInRefreshLoginButton.interactable = false;
|
||||
loggedInLogoutButton.interactable = false;
|
||||
loggedInBackButton.interactable = false;
|
||||
EncryptedWWWForm dataForm = new();
|
||||
WWWForm dataForm = new();
|
||||
dataForm.AddField("username", BazookaManager.Instance.GetAccountName());
|
||||
dataForm.AddField("token", BazookaManager.Instance.GetAccountSession());
|
||||
dataForm.AddField("saveData", Convert.ToBase64String(Encoding.UTF8.GetBytes(BazookaManager.Instance.saveFile.ToString(Formatting.None))));
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "saveAccount.php", dataForm.form);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "saveAccount.php", dataForm);
|
||||
request.SetRequestHeader("Requester", "BerryDashClient");
|
||||
request.SetRequestHeader("ClientVersion", Application.version);
|
||||
request.SetRequestHeader("ClientPlatform", Application.platform.ToString());
|
||||
@@ -70,7 +70,7 @@ public class AccountLoggedIn : MonoBehaviour
|
||||
Tools.UpdateStatusText(loggedInText, "Failed to make HTTP request", Color.red);
|
||||
return;
|
||||
}
|
||||
string response = SensitiveInfo.Decrypt(request.downloadHandler.text, SensitiveInfo.SERVER_RECEIVE_TRANSFER_KEY);
|
||||
string response = request.downloadHandler.text;
|
||||
if (response == "-999")
|
||||
{
|
||||
Tools.UpdateStatusText(loggedInText, "Server error while fetching data", Color.red);
|
||||
@@ -117,10 +117,10 @@ public class AccountLoggedIn : MonoBehaviour
|
||||
loggedInRefreshLoginButton.interactable = false;
|
||||
loggedInLogoutButton.interactable = false;
|
||||
loggedInBackButton.interactable = false;
|
||||
EncryptedWWWForm dataForm = new();
|
||||
WWWForm dataForm = new();
|
||||
dataForm.AddField("token", BazookaManager.Instance.GetAccountSession());
|
||||
dataForm.AddField("username", BazookaManager.Instance.GetAccountName());
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "loadAccount.php", dataForm.form);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "loadAccount.php", dataForm);
|
||||
request.SetRequestHeader("Requester", "BerryDashClient");
|
||||
request.SetRequestHeader("ClientVersion", Application.version);
|
||||
request.SetRequestHeader("ClientPlatform", Application.platform.ToString());
|
||||
@@ -137,7 +137,7 @@ public class AccountLoggedIn : MonoBehaviour
|
||||
Tools.UpdateStatusText(loggedInText, "Failed to make HTTP request", Color.red);
|
||||
return;
|
||||
}
|
||||
string response = SensitiveInfo.Decrypt(request.downloadHandler.text, SensitiveInfo.SERVER_RECEIVE_TRANSFER_KEY);
|
||||
string response = request.downloadHandler.text;
|
||||
if (response == "-999")
|
||||
{
|
||||
Tools.UpdateStatusText(loggedInText, "Server error while fetching data", Color.red);
|
||||
|
||||
@@ -35,11 +35,11 @@ public class AccountLogin : MonoBehaviour
|
||||
Tools.UpdateStatusText(loginPanelStatusText, "All input fields must be filled", Color.red);
|
||||
return;
|
||||
}
|
||||
EncryptedWWWForm dataForm = new();
|
||||
WWWForm dataForm = new();
|
||||
dataForm.AddField("username", loginUsernameInput.text);
|
||||
dataForm.AddField("password", loginPasswordInput.text);
|
||||
dataForm.AddField("currentHighScore", BazookaManager.Instance.GetGameStoreHighScore().ToString());
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "loginAccount.php", dataForm.form);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "loginAccount.php", dataForm);
|
||||
request.SetRequestHeader("Requester", "BerryDashClient");
|
||||
request.SetRequestHeader("ClientVersion", Application.version);
|
||||
request.SetRequestHeader("ClientPlatform", Application.platform.ToString());
|
||||
@@ -51,7 +51,7 @@ public class AccountLogin : MonoBehaviour
|
||||
Tools.UpdateStatusText(loginPanelStatusText, "Failed to make HTTP request", Color.red);
|
||||
return;
|
||||
}
|
||||
string response = SensitiveInfo.Decrypt(request.downloadHandler.text, SensitiveInfo.SERVER_RECEIVE_TRANSFER_KEY);
|
||||
string response = request.downloadHandler.text;
|
||||
if (response == "-999")
|
||||
{
|
||||
Tools.UpdateStatusText(loginPanelStatusText, "Server error while fetching data", Color.red);
|
||||
|
||||
@@ -29,10 +29,10 @@ public class AccountRefreshLogin : MonoBehaviour
|
||||
{
|
||||
refreshLoginBackButton.interactable = false;
|
||||
refreshLoginSubmitButton.interactable = false;
|
||||
EncryptedWWWForm dataForm = new();
|
||||
WWWForm dataForm = new();
|
||||
dataForm.AddField("username", refreshLoginUsernameInput.text);
|
||||
dataForm.AddField("password", refreshLoginPasswordInput.text);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "loginAccount.php", dataForm.form);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "loginAccount.php", dataForm);
|
||||
request.SetRequestHeader("Requester", "BerryDashClient");
|
||||
request.SetRequestHeader("ClientVersion", Application.version);
|
||||
request.SetRequestHeader("ClientPlatform", Application.platform.ToString());
|
||||
@@ -44,7 +44,7 @@ public class AccountRefreshLogin : MonoBehaviour
|
||||
Tools.UpdateStatusText(refreshLoginStatusText, "Failed to make HTTP request", Color.red);
|
||||
return;
|
||||
}
|
||||
string response = SensitiveInfo.Decrypt(request.downloadHandler.text, SensitiveInfo.SERVER_RECEIVE_TRANSFER_KEY);
|
||||
string response = request.downloadHandler.text;
|
||||
if (response == "-999")
|
||||
{
|
||||
Tools.UpdateStatusText(refreshLoginStatusText, "Server error while fetching data", Color.red);
|
||||
|
||||
@@ -56,11 +56,11 @@ public class AccountRegister : MonoBehaviour
|
||||
}
|
||||
registerBackButton.interactable = false;
|
||||
registerSubmitButton.interactable = false;
|
||||
EncryptedWWWForm dataForm = new();
|
||||
WWWForm dataForm = new();
|
||||
dataForm.AddField("username", registerUsernameInput.text);
|
||||
dataForm.AddField("email", registerEmailInput.text);
|
||||
dataForm.AddField("password", registerPasswordInput.text);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "registerAccount.php", dataForm.form);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "registerAccount.php", dataForm);
|
||||
request.SetRequestHeader("Requester", "BerryDashClient");
|
||||
request.SetRequestHeader("ClientVersion", Application.version);
|
||||
request.SetRequestHeader("ClientPlatform", Application.platform.ToString());
|
||||
@@ -72,7 +72,7 @@ public class AccountRegister : MonoBehaviour
|
||||
Tools.UpdateStatusText(registerPanelStatusText, "Failed to make HTTP request", Color.red);
|
||||
return;
|
||||
}
|
||||
string response = SensitiveInfo.Decrypt(request.downloadHandler.text, SensitiveInfo.SERVER_RECEIVE_TRANSFER_KEY);
|
||||
string response = request.downloadHandler.text;
|
||||
if (response == "-999")
|
||||
{
|
||||
Tools.UpdateStatusText(registerPanelStatusText, "Server error while fetching data", Color.red);
|
||||
|
||||
@@ -248,11 +248,11 @@ public class ChatroomMenu : MonoBehaviour
|
||||
return;
|
||||
}
|
||||
|
||||
EncryptedWWWForm dataForm = new();
|
||||
WWWForm dataForm = new();
|
||||
dataForm.AddField("content", text);
|
||||
dataForm.AddField("token", BazookaManager.Instance.GetAccountSession());
|
||||
dataForm.AddField("username", BazookaManager.Instance.GetAccountName());
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "sendChatroomMessage.php", dataForm.form);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "sendChatroomMessage.php", dataForm);
|
||||
request.SetRequestHeader("Requester", "BerryDashClient");
|
||||
request.SetRequestHeader("ClientVersion", Application.version);
|
||||
request.SetRequestHeader("ClientPlatform", Application.platform.ToString());
|
||||
@@ -262,7 +262,7 @@ public class ChatroomMenu : MonoBehaviour
|
||||
backButton.interactable = true;
|
||||
return;
|
||||
}
|
||||
string response = SensitiveInfo.Decrypt(request.downloadHandler.text, SensitiveInfo.SERVER_RECEIVE_TRANSFER_KEY);
|
||||
string response = request.downloadHandler.text;
|
||||
if (response == "-999")
|
||||
{
|
||||
ShowStatus("Server error while fetching data");
|
||||
@@ -361,7 +361,7 @@ public class ChatroomMenu : MonoBehaviour
|
||||
Debug.LogError("Failed to fetch chatroom messages: " + request.error);
|
||||
return;
|
||||
}
|
||||
string response = SensitiveInfo.Decrypt(request.downloadHandler.text, SensitiveInfo.SERVER_RECEIVE_TRANSFER_KEY);
|
||||
string response = request.downloadHandler.text;
|
||||
var shouldClear = true;
|
||||
switch (response)
|
||||
{
|
||||
@@ -500,11 +500,11 @@ public class ChatroomMenu : MonoBehaviour
|
||||
|
||||
async Task HandleDelete()
|
||||
{
|
||||
EncryptedWWWForm dataForm = new();
|
||||
WWWForm dataForm = new();
|
||||
dataForm.AddField("id", selectedMessageForOptions.ID.ToString());
|
||||
dataForm.AddField("token", BazookaManager.Instance.GetAccountSession());
|
||||
dataForm.AddField("username", BazookaManager.Instance.GetAccountName());
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "deleteChatroomMessage.php", dataForm.form);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "deleteChatroomMessage.php", dataForm);
|
||||
request.SetRequestHeader("Requester", "BerryDashClient");
|
||||
request.SetRequestHeader("ClientVersion", Application.version);
|
||||
request.SetRequestHeader("ClientPlatform", Application.platform.ToString());
|
||||
@@ -518,12 +518,12 @@ public class ChatroomMenu : MonoBehaviour
|
||||
{
|
||||
var newContent = editMessagePanelCurrent.transform.GetChild(0).GetChild(4).GetComponent<TMP_InputField>().text;
|
||||
selectedMessageForOptions.Content = newContent;
|
||||
EncryptedWWWForm dataForm = new();
|
||||
WWWForm dataForm = new();
|
||||
dataForm.AddField("id", selectedMessageForOptions.ID.ToString());
|
||||
dataForm.AddField("content", newContent);
|
||||
dataForm.AddField("token", BazookaManager.Instance.GetAccountSession());
|
||||
dataForm.AddField("username", BazookaManager.Instance.GetAccountName());
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "editChatroomMessage.php", dataForm.form);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "editChatroomMessage.php", dataForm);
|
||||
request.SetRequestHeader("Requester", "BerryDashClient");
|
||||
request.SetRequestHeader("ClientVersion", Application.version);
|
||||
request.SetRequestHeader("ClientPlatform", Application.platform.ToString());
|
||||
@@ -538,12 +538,12 @@ public class ChatroomMenu : MonoBehaviour
|
||||
|
||||
async Task HandleReport()
|
||||
{
|
||||
EncryptedWWWForm dataForm = new();
|
||||
WWWForm dataForm = new();
|
||||
dataForm.AddField("id", selectedMessageForOptions.ID.ToString());
|
||||
dataForm.AddField("reason", reportMessagePanelReportReason.text);
|
||||
dataForm.AddField("token", BazookaManager.Instance.GetAccountSession());
|
||||
dataForm.AddField("username", BazookaManager.Instance.GetAccountName());
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "reportChatroomMessage.php", dataForm.form);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "reportChatroomMessage.php", dataForm);
|
||||
request.SetRequestHeader("Requester", "BerryDashClient");
|
||||
request.SetRequestHeader("ClientVersion", Application.version);
|
||||
request.SetRequestHeader("ClientPlatform", Application.platform.ToString());
|
||||
|
||||
@@ -1,12 +0,0 @@
|
||||
using UnityEngine;
|
||||
|
||||
public class EncryptedWWWForm
|
||||
{
|
||||
public readonly WWWForm form = new();
|
||||
|
||||
public void AddField(string key, string value)
|
||||
{
|
||||
if (SensitiveInfo.SERVER_RECEIVE_TRANSFER_KEY.Trim() != string.Empty && SensitiveInfo.SERVER_SEND_TRANSFER_KEY.Trim() != string.Empty)
|
||||
form.AddField(SensitiveInfo.Encrypt(key, SensitiveInfo.SERVER_SEND_TRANSFER_KEY), SensitiveInfo.Encrypt(value, SensitiveInfo.SERVER_SEND_TRANSFER_KEY));
|
||||
}
|
||||
}
|
||||
@@ -1,2 +0,0 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 3bc52d706b8e5c9ea9eab9e3836dbfec
|
||||
@@ -134,7 +134,7 @@ public class IconMarketplaceDownloadIcon : MonoBehaviour
|
||||
currentIcons.Add(icon.UUID);
|
||||
}
|
||||
ShowStatus("Loading...");
|
||||
EncryptedWWWForm dataForm = new();
|
||||
WWWForm dataForm = new();
|
||||
dataForm.AddField("userId", (BazookaManager.Instance.GetAccountID() ?? 0).ToString());
|
||||
dataForm.AddField("sortBy", optionsPanelSortByDropdown.value.ToString());
|
||||
dataForm.AddField("priceRangeEnabled", optionsPanelPriceRangeToggle.isOn.ToString());
|
||||
@@ -145,7 +145,7 @@ public class IconMarketplaceDownloadIcon : MonoBehaviour
|
||||
dataForm.AddField("onlyShowEnabled", optionsPanelOnlyShowToggle.isOn.ToString());
|
||||
dataForm.AddField("onlyShowValue", optionsPanelOnlyShowDropdown.value.ToString());
|
||||
dataForm.AddField("currentIcons", Convert.ToBase64String(Encoding.UTF8.GetBytes(currentIcons.ToString(Formatting.None))));
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "getMarketplaceIcons.php", dataForm.form);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "getMarketplaceIcons.php", dataForm);
|
||||
request.SetRequestHeader("Requester", "BerryDashClient");
|
||||
request.SetRequestHeader("ClientVersion", Application.version);
|
||||
request.SetRequestHeader("ClientPlatform", Application.platform.ToString());
|
||||
@@ -158,7 +158,7 @@ public class IconMarketplaceDownloadIcon : MonoBehaviour
|
||||
ShowStatus("Failed to make HTTP request");
|
||||
return;
|
||||
}
|
||||
string response = SensitiveInfo.Decrypt(request.downloadHandler.text, SensitiveInfo.SERVER_RECEIVE_TRANSFER_KEY);
|
||||
string response = request.downloadHandler.text;
|
||||
if (response == "-999")
|
||||
{
|
||||
ShowStatus("Server error while fetching data");
|
||||
|
||||
@@ -90,13 +90,13 @@ public class IconMarketplaceUploadIcon : MonoBehaviour
|
||||
uploadButton.interactable = false;
|
||||
backButton.interactable = false;
|
||||
selectButton.interactable = false;
|
||||
EncryptedWWWForm dataForm = new();
|
||||
WWWForm dataForm = new();
|
||||
dataForm.AddField("token", BazookaManager.Instance.GetAccountSession());
|
||||
dataForm.AddField("username", BazookaManager.Instance.GetAccountName());
|
||||
dataForm.AddField("name", birdNameInput.text);
|
||||
dataForm.AddField("price", birdPriceInput.text);
|
||||
dataForm.AddField("filecontent", birdData);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "uploadMarketplaceIcon.php", dataForm.form);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "uploadMarketplaceIcon.php", dataForm);
|
||||
request.SetRequestHeader("Requester", "BerryDashClient");
|
||||
request.SetRequestHeader("ClientVersion", Application.version);
|
||||
request.SetRequestHeader("ClientPlatform", Application.platform.ToString());
|
||||
@@ -109,7 +109,7 @@ public class IconMarketplaceUploadIcon : MonoBehaviour
|
||||
Tools.UpdateStatusText(statusText, "Failed to make HTTP request", Color.red);
|
||||
return;
|
||||
}
|
||||
string response = SensitiveInfo.Decrypt(request.downloadHandler.text, SensitiveInfo.SERVER_RECEIVE_TRANSFER_KEY);
|
||||
string response = request.downloadHandler.text;
|
||||
if (response == "-999")
|
||||
{
|
||||
uploadButton.interactable = true;
|
||||
|
||||
@@ -208,9 +208,9 @@ public class LeaderboardsMenu : MonoBehaviour
|
||||
}
|
||||
}
|
||||
UpdateStatus(true, "Loading...");
|
||||
EncryptedWWWForm dataForm = new();
|
||||
WWWForm dataForm = new();
|
||||
dataForm.AddField("type", "0");
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "getTopPlayers.php", dataForm.form);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "getTopPlayers.php", dataForm);
|
||||
request.SetRequestHeader("Requester", "BerryDashClient");
|
||||
request.SetRequestHeader("ClientVersion", Application.version);
|
||||
request.SetRequestHeader("ClientPlatform", Application.platform.ToString());
|
||||
@@ -218,7 +218,7 @@ public class LeaderboardsMenu : MonoBehaviour
|
||||
if (request.result == UnityWebRequest.Result.Success)
|
||||
{
|
||||
UpdateStatus(false);
|
||||
string response = SensitiveInfo.Decrypt(request.downloadHandler.text, SensitiveInfo.SERVER_RECEIVE_TRANSFER_KEY);
|
||||
string response = request.downloadHandler.text;
|
||||
if (response == "-999")
|
||||
{
|
||||
UpdateStatus(true, "Server error while fetching data");
|
||||
@@ -342,10 +342,10 @@ public class LeaderboardsMenu : MonoBehaviour
|
||||
}
|
||||
}
|
||||
UpdateStatus(true, "Loading...");
|
||||
EncryptedWWWForm dataForm = new();
|
||||
WWWForm dataForm = new();
|
||||
dataForm.AddField("showType", showAmount.ToString());
|
||||
dataForm.AddField("type", "1");
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "getTopPlayers.php", dataForm.form);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "getTopPlayers.php", dataForm);
|
||||
request.SetRequestHeader("Requester", "BerryDashClient");
|
||||
request.SetRequestHeader("ClientVersion", Application.version);
|
||||
request.SetRequestHeader("ClientPlatform", Application.platform.ToString());
|
||||
@@ -353,7 +353,7 @@ public class LeaderboardsMenu : MonoBehaviour
|
||||
if (request.result == UnityWebRequest.Result.Success)
|
||||
{
|
||||
UpdateStatus(false);
|
||||
string response = SensitiveInfo.Decrypt(request.downloadHandler.text, SensitiveInfo.SERVER_RECEIVE_TRANSFER_KEY);
|
||||
string response = request.downloadHandler.text;
|
||||
if (response == "-999")
|
||||
{
|
||||
UpdateStatus(true, "Server error while fetching data");
|
||||
@@ -477,9 +477,9 @@ public class LeaderboardsMenu : MonoBehaviour
|
||||
}
|
||||
}
|
||||
UpdateStatus(true, "Loading...");
|
||||
EncryptedWWWForm dataForm = new();
|
||||
WWWForm dataForm = new();
|
||||
dataForm.AddField("type", "2");
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "getTopPlayers.php", dataForm.form);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "getTopPlayers.php", dataForm);
|
||||
request.SetRequestHeader("Requester", "BerryDashClient");
|
||||
request.SetRequestHeader("ClientVersion", Application.version);
|
||||
request.SetRequestHeader("ClientPlatform", Application.platform.ToString());
|
||||
@@ -487,7 +487,7 @@ public class LeaderboardsMenu : MonoBehaviour
|
||||
if (request.result == UnityWebRequest.Result.Success)
|
||||
{
|
||||
UpdateStatus(false);
|
||||
string response = SensitiveInfo.Decrypt(request.downloadHandler.text, SensitiveInfo.SERVER_RECEIVE_TRANSFER_KEY);
|
||||
string response = request.downloadHandler.text;
|
||||
if (response == "-999")
|
||||
{
|
||||
UpdateStatus(true, "Server error while fetching data");
|
||||
@@ -610,9 +610,9 @@ public class LeaderboardsMenu : MonoBehaviour
|
||||
}
|
||||
}
|
||||
UpdateStatus(true, "Loading...");
|
||||
EncryptedWWWForm dataForm = new();
|
||||
WWWForm dataForm = new();
|
||||
dataForm.AddField("type", "3");
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "getTopPlayers.php", dataForm.form);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "getTopPlayers.php", dataForm);
|
||||
request.SetRequestHeader("Requester", "BerryDashClient");
|
||||
request.SetRequestHeader("ClientVersion", Application.version);
|
||||
request.SetRequestHeader("ClientPlatform", Application.platform.ToString());
|
||||
@@ -620,7 +620,7 @@ public class LeaderboardsMenu : MonoBehaviour
|
||||
if (request.result == UnityWebRequest.Result.Success)
|
||||
{
|
||||
UpdateStatus(false);
|
||||
string response = SensitiveInfo.Decrypt(request.downloadHandler.text, SensitiveInfo.SERVER_RECEIVE_TRANSFER_KEY);
|
||||
string response = request.downloadHandler.text;
|
||||
if (response == "-999")
|
||||
{
|
||||
UpdateStatus(true, "Server error while fetching data");
|
||||
@@ -743,9 +743,9 @@ public class LeaderboardsMenu : MonoBehaviour
|
||||
}
|
||||
}
|
||||
UpdateStatus(true, "Loading...");
|
||||
EncryptedWWWForm dataForm = new();
|
||||
WWWForm dataForm = new();
|
||||
dataForm.AddField("type", "4");
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "getTopPlayers.php", dataForm.form);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "getTopPlayers.php", dataForm);
|
||||
request.SetRequestHeader("Requester", "BerryDashClient");
|
||||
request.SetRequestHeader("ClientVersion", Application.version);
|
||||
request.SetRequestHeader("ClientPlatform", Application.platform.ToString());
|
||||
@@ -753,7 +753,7 @@ public class LeaderboardsMenu : MonoBehaviour
|
||||
if (request.result == UnityWebRequest.Result.Success)
|
||||
{
|
||||
UpdateStatus(false);
|
||||
string response = SensitiveInfo.Decrypt(request.downloadHandler.text, SensitiveInfo.SERVER_RECEIVE_TRANSFER_KEY);
|
||||
string response = request.downloadHandler.text;
|
||||
if (response == "-999")
|
||||
{
|
||||
UpdateStatus(true, "Server error while fetching data");
|
||||
|
||||
@@ -7,7 +7,6 @@ public class MenuScript : MonoBehaviour
|
||||
public Button exitButton;
|
||||
public TMP_Text updateText;
|
||||
public Button updateButton;
|
||||
public GameObject selfBuiltPanel;
|
||||
public Button profileButton;
|
||||
public ProfileMenu profilePrefab;
|
||||
|
||||
@@ -28,7 +27,6 @@ public class MenuScript : MonoBehaviour
|
||||
Application.Quit();
|
||||
});
|
||||
}
|
||||
if (SensitiveInfo.SERVER_RECEIVE_TRANSFER_KEY.Trim() == string.Empty || SensitiveInfo.SERVER_SEND_TRANSFER_KEY.Trim() == string.Empty) selfBuiltPanel.SetActive(true);
|
||||
}
|
||||
|
||||
void Start()
|
||||
|
||||
@@ -122,9 +122,9 @@ public class ProfileMenu : MonoBehaviour
|
||||
|
||||
public async Task Init(BigInteger playerID)
|
||||
{
|
||||
EncryptedWWWForm dataForm = new();
|
||||
WWWForm dataForm = new();
|
||||
dataForm.AddField("uesrId", playerID.ToString());
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "getAccountProfile.php", dataForm.form);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "getAccountProfile.php", dataForm);
|
||||
request.SetRequestHeader("Requester", "BerryDashClient");
|
||||
request.SetRequestHeader("ClientVersion", Application.version);
|
||||
request.SetRequestHeader("ClientPlatform", Application.platform.ToString());
|
||||
@@ -133,7 +133,7 @@ public class ProfileMenu : MonoBehaviour
|
||||
{
|
||||
return;
|
||||
}
|
||||
string response = SensitiveInfo.Decrypt(request.downloadHandler.text, SensitiveInfo.SERVER_RECEIVE_TRANSFER_KEY);
|
||||
string response = request.downloadHandler.text;
|
||||
var jsonResponse = JObject.Parse(response);
|
||||
if ((bool)jsonResponse["success"])
|
||||
{
|
||||
@@ -191,9 +191,9 @@ public class ProfileMenu : MonoBehaviour
|
||||
Destroy(post.gameObject);
|
||||
}
|
||||
}
|
||||
EncryptedWWWForm dataForm = new();
|
||||
WWWForm dataForm = new();
|
||||
dataForm.AddField("targetId", playerID.ToString());
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "getAccountProfileMessages.php", dataForm.form);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "getAccountProfileMessages.php", dataForm);
|
||||
request.SetRequestHeader("Requester", "BerryDashClient");
|
||||
request.SetRequestHeader("ClientVersion", Application.version);
|
||||
request.SetRequestHeader("ClientPlatform", Application.platform.ToString());
|
||||
@@ -202,7 +202,7 @@ public class ProfileMenu : MonoBehaviour
|
||||
{
|
||||
return;
|
||||
}
|
||||
string response = SensitiveInfo.Decrypt(request.downloadHandler.text, SensitiveInfo.SERVER_RECEIVE_TRANSFER_KEY);
|
||||
string response = request.downloadHandler.text;
|
||||
var posts = JArray.Parse(response).ToObject<ProfileMessageResponse[]>();
|
||||
foreach (var post in posts)
|
||||
{
|
||||
@@ -275,12 +275,12 @@ public class ProfileMenu : MonoBehaviour
|
||||
|
||||
async Task SendPostVote(BigInteger postId, bool liked, TMP_Text entryLikesCount, TMP_Text entryLikesTexture)
|
||||
{
|
||||
EncryptedWWWForm dataForm = new();
|
||||
WWWForm dataForm = new();
|
||||
dataForm.AddField("targetId", postId.ToString());
|
||||
dataForm.AddField("liked", liked ? "1" : "0");
|
||||
dataForm.AddField("username", BazookaManager.Instance.GetAccountName());
|
||||
dataForm.AddField("token", BazookaManager.Instance.GetAccountSession());
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "voteAccountProfileMessage.php", dataForm.form);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "voteAccountProfileMessage.php", dataForm);
|
||||
request.SetRequestHeader("Requester", "BerryDashClient");
|
||||
request.SetRequestHeader("ClientVersion", Application.version);
|
||||
request.SetRequestHeader("ClientPlatform", Application.platform.ToString());
|
||||
@@ -289,7 +289,7 @@ public class ProfileMenu : MonoBehaviour
|
||||
{
|
||||
return;
|
||||
}
|
||||
string response = SensitiveInfo.Decrypt(request.downloadHandler.text, SensitiveInfo.SERVER_RECEIVE_TRANSFER_KEY);
|
||||
string response = request.downloadHandler.text;
|
||||
try
|
||||
{
|
||||
var jsonResponse = JObject.Parse(response);
|
||||
@@ -337,11 +337,11 @@ public class ProfileMenu : MonoBehaviour
|
||||
|
||||
async Task UploadPost(string message)
|
||||
{
|
||||
EncryptedWWWForm dataForm = new();
|
||||
WWWForm dataForm = new();
|
||||
dataForm.AddField("content", message);
|
||||
dataForm.AddField("username", BazookaManager.Instance.GetAccountName());
|
||||
dataForm.AddField("token", BazookaManager.Instance.GetAccountSession());
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "uploadAccountProfileMessage.php", dataForm.form);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "uploadAccountProfileMessage.php", dataForm);
|
||||
request.SetRequestHeader("Requester", "BerryDashClient");
|
||||
request.SetRequestHeader("ClientVersion", Application.version);
|
||||
request.SetRequestHeader("ClientPlatform", Application.platform.ToString());
|
||||
@@ -350,7 +350,7 @@ public class ProfileMenu : MonoBehaviour
|
||||
{
|
||||
return;
|
||||
}
|
||||
string response = SensitiveInfo.Decrypt(request.downloadHandler.text, SensitiveInfo.SERVER_RECEIVE_TRANSFER_KEY);
|
||||
string response = request.downloadHandler.text;
|
||||
try
|
||||
{
|
||||
var jsonResponse = JObject.Parse(response);
|
||||
@@ -367,11 +367,11 @@ public class ProfileMenu : MonoBehaviour
|
||||
|
||||
async Task DeletePost(GameObject entryObject, BigInteger targetId)
|
||||
{
|
||||
EncryptedWWWForm dataForm = new();
|
||||
WWWForm dataForm = new();
|
||||
dataForm.AddField("targetId", targetId.ToString());
|
||||
dataForm.AddField("username", BazookaManager.Instance.GetAccountName());
|
||||
dataForm.AddField("token", BazookaManager.Instance.GetAccountSession());
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "deleteAccountProfileMessage.php", dataForm.form);
|
||||
using UnityWebRequest request = UnityWebRequest.Post(SensitiveInfo.SERVER_DATABASE_PREFIX + "deleteAccountProfileMessage.php", dataForm);
|
||||
request.SetRequestHeader("Requester", "BerryDashClient");
|
||||
request.SetRequestHeader("ClientVersion", Application.version);
|
||||
request.SetRequestHeader("ClientPlatform", Application.platform.ToString());
|
||||
@@ -380,7 +380,7 @@ public class ProfileMenu : MonoBehaviour
|
||||
{
|
||||
return;
|
||||
}
|
||||
string response = SensitiveInfo.Decrypt(request.downloadHandler.text, SensitiveInfo.SERVER_RECEIVE_TRANSFER_KEY);
|
||||
string response = request.downloadHandler.text;
|
||||
try
|
||||
{
|
||||
var jsonResponse = JObject.Parse(response);
|
||||
|
||||
Reference in New Issue
Block a user