每日自动提交 2026-04-13 18:30
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Assets.MyGame.Scripts.Net.APIRequest.Params
|
||||
{
|
||||
[Serializable]
|
||||
public class GetUserParam:RequestParamBase
|
||||
{
|
||||
public string userid;
|
||||
}
|
||||
}
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 3c56ed098f6dd7c4c99acaad8c769ed7
|
||||
guid: b51e71cd9738bbf40be414078e722e0d
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
@@ -42,42 +42,62 @@ namespace Assets.MyGame.Scripts.Net.APIRequest.Params
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 购买月卡请求参数
|
||||
/// 购买月卡请求参数(GET)
|
||||
/// Swagger: GET /api/Hall/BuyMonthCard
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
public class BuyMonthCardParam : RequestParamBase
|
||||
{
|
||||
public int cardType; // 月卡类型
|
||||
/// <summary>月卡类型 1=周卡 2=月卡 3=年卡</summary>
|
||||
public int type;
|
||||
|
||||
/// <summary>金币价格(用于校验)</summary>
|
||||
public int gold;
|
||||
|
||||
/// <summary>现金价格</summary>
|
||||
public double money;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 购买道具请求参数
|
||||
/// 购买道具请求参数(GET)
|
||||
/// Swagger: GET /api/Hall/BuyProp
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
public class BuyPropParam : RequestParamBase
|
||||
{
|
||||
public int propId; // 道具ID
|
||||
public int count; // 数量
|
||||
/// <summary>道具编号</summary>
|
||||
public string propNumber;
|
||||
|
||||
/// <summary>购买数量</summary>
|
||||
public int count;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 购买金币请求参数
|
||||
/// 购买金币请求参数(GET)
|
||||
/// Swagger: GET /api/Hall/BuyGold
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
public class BuyGoldParam : RequestParamBase
|
||||
{
|
||||
/// <summary>商品编号(GoldShopConfig.number)</summary>
|
||||
public string number;
|
||||
|
||||
public long goldAmount; // 金币数量
|
||||
/// <summary>购买数量</summary>
|
||||
public int count;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 购买钻石请求参数
|
||||
/// 购买钻石请求参数(GET)
|
||||
/// Swagger: GET /api/Hall/BuyDiamond
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
public class BuyDiamondParam : RequestParamBase
|
||||
{
|
||||
|
||||
public int diamondAmount; // 钻石数量
|
||||
/// <summary>商品编号(DiamondShopConfig.number)</summary>
|
||||
public string number;
|
||||
|
||||
/// <summary>购买数量</summary>
|
||||
public int count;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -71,43 +71,43 @@ namespace Assets.MyGame.Scripts.Net
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 购买月卡(POST)
|
||||
/// 参数:用户ID、月卡类型
|
||||
/// 返回:MonthCardInfo(月卡信息)
|
||||
/// 购买月卡(GET)
|
||||
/// 参数:type(1=周卡 2=月卡 3=年卡)、gold(金币价)、money(现金价)
|
||||
/// 返回:string(data 为结果描述字符串)
|
||||
/// </summary>
|
||||
public static void BuyMonthCard(BuyMonthCardParam req, Action<MonthCardInfo> callback)
|
||||
public static void BuyMonthCard(BuyMonthCardParam req, Action<string> callback)
|
||||
{
|
||||
APIManager.Response<MonthCardInfo>(APIType.Hall_BuyMonthCard, req, callback);
|
||||
APIManager.Response<string>(APIType.Hall_BuyMonthCard, req, callback);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 购买道具(POST)
|
||||
/// 参数:道具ID、数量
|
||||
/// 返回:PropInfo(道具信息)
|
||||
/// 购买道具(GET)
|
||||
/// 参数:propNumber(道具编号)、count(数量)
|
||||
/// 返回:string(data 为结果描述字符串)
|
||||
/// </summary>
|
||||
public static void BuyProp(BuyPropParam req, Action<PropInfo> callback)
|
||||
public static void BuyProp(BuyPropParam req, Action<string> callback)
|
||||
{
|
||||
APIManager.Response<PropInfo>(APIType.Hall_BuyProp, req, callback);
|
||||
APIManager.Response<string>(APIType.Hall_BuyProp, req, callback);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 购买金币(POST)
|
||||
/// 参数:用户ID、金币数量
|
||||
/// 返回:GoldInfo(金币信息)
|
||||
/// 购买金币(GET)
|
||||
/// 参数:number(GoldShopConfig.number)、count(数量)
|
||||
/// 返回:string(data 为结果描述字符串)
|
||||
/// </summary>
|
||||
public static void BuyGold(BuyGoldParam req, Action<GoldInfo> callback)
|
||||
public static void BuyGold(BuyGoldParam req, Action<string> callback)
|
||||
{
|
||||
APIManager.Response<GoldInfo>(APIType.Hall_BuyGold, req, callback);
|
||||
APIManager.Response<string>(APIType.Hall_BuyGold, req, callback);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 购买钻石(POST)
|
||||
/// 参数:用户ID、钻石数量
|
||||
/// 返回:DiamondInfo(钻石信息)
|
||||
/// 购买钻石(GET)
|
||||
/// 参数:number(DiamondShopConfig.number)、count(数量)
|
||||
/// 返回:string(data 为结果描述字符串)
|
||||
/// </summary>
|
||||
public static void BuyDiamond(BuyDiamondParam req, Action<DiamondInfo> callback)
|
||||
public static void BuyDiamond(BuyDiamondParam req, Action<string> callback)
|
||||
{
|
||||
APIManager.Response<DiamondInfo>(APIType.Hall_BuyDiamond, req, callback);
|
||||
APIManager.Response<string>(APIType.Hall_BuyDiamond, req, callback);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
using Assets.MyGame.Scripts.Net.APIRequest.Objs;
|
||||
using Assets.MyGame.Scripts.Net.API;
|
||||
using Assets.MyGame.Scripts.Net.APIRequest;
|
||||
using Assets.MyGame.Scripts.Net.APIRequest.Objs;
|
||||
using Assets.MyGame.Scripts.Net.APIRequest.Params;
|
||||
using Assets.MyGame.Scripts.Net.APIResponses.HomeMain_User;
|
||||
using Newtonsoft.Json.Linq;
|
||||
@@ -68,7 +70,17 @@ namespace Assets.MyGame.Scripts.Net
|
||||
{
|
||||
APIManager.Response<long>(APIType.User_GetNoReadCount, callback);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取未读邮件数量(GET,无参)
|
||||
/// 返回:long(未读数量)
|
||||
/// </summary>
|
||||
public static void GetUser(string userID,Action<UserData> callback)
|
||||
{
|
||||
APIManager.Response<UserData>(APIType.User_GetUser,new GetUserParam
|
||||
{
|
||||
userid=userID
|
||||
}, callback);
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
namespace Assets.MyGame.Scripts.Net.API.GameConfig_SubClass
|
||||
{
|
||||
@@ -8,6 +9,7 @@ namespace Assets.MyGame.Scripts.Net.API.GameConfig_SubClass
|
||||
[Serializable]
|
||||
public class DiamondShopConfig
|
||||
{
|
||||
public Sprite sprite_Icon;
|
||||
/// <summary>
|
||||
/// 商品编号
|
||||
/// </summary>
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
namespace Assets.MyGame.Scripts.Net.API.GameConfig_SubClass
|
||||
{
|
||||
@@ -8,6 +9,7 @@ namespace Assets.MyGame.Scripts.Net.API.GameConfig_SubClass
|
||||
[Serializable]
|
||||
public class GoldShopConfig
|
||||
{
|
||||
public Sprite sprite_Icon;
|
||||
/// <summary>
|
||||
/// 商品编号
|
||||
/// </summary>
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
namespace Assets.MyGame.Scripts.Net.API.GameConfig_SubClass
|
||||
{
|
||||
@@ -8,6 +9,7 @@ namespace Assets.MyGame.Scripts.Net.API.GameConfig_SubClass
|
||||
[Serializable]
|
||||
public class PropFragmentConfig : BasePropInfo
|
||||
{
|
||||
public Sprite sprite_Icon;
|
||||
/// <summary>
|
||||
/// 合成所需碎片数量
|
||||
/// </summary>
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
namespace Assets.MyGame.Scripts.Net.API.GameConfig_SubClass
|
||||
{
|
||||
@@ -9,6 +10,7 @@ namespace Assets.MyGame.Scripts.Net.API.GameConfig_SubClass
|
||||
[Serializable]
|
||||
public class PropInfConfig : BasePropInfo
|
||||
{
|
||||
public Sprite sprite_Icon;
|
||||
/// <summary>
|
||||
/// 关联游戏编号(空表示全部)
|
||||
/// </summary>
|
||||
|
||||
@@ -1,16 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Assets.MyGame.Scripts.Net.APIResponses.Login_SubClass
|
||||
{
|
||||
[Serializable]
|
||||
public class DefaultAPIResponse
|
||||
{
|
||||
public int code;
|
||||
public string? info;
|
||||
public string data;
|
||||
}
|
||||
}
|
||||
@@ -1,8 +1,10 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class UserBaseInfo
|
||||
{
|
||||
public Sprite avatarSprite;
|
||||
public string userName { get; set; }
|
||||
public string password { get; set; }
|
||||
public string number { get; set; }
|
||||
|
||||
@@ -11,7 +11,15 @@ namespace Assets.MyGame.Scripts.Net.API
|
||||
/// 用户 Token 及完整用户信息(Swagger: UserToken)
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
public class UserToken
|
||||
public class UserToken:UserData
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// 登录 Token
|
||||
/// </summary>
|
||||
public string token;
|
||||
}
|
||||
public class UserData
|
||||
{
|
||||
/// <summary>
|
||||
/// 基础信息,包括昵称、头像等基本信息
|
||||
@@ -65,7 +73,7 @@ namespace Assets.MyGame.Scripts.Net.API
|
||||
/// <summary>
|
||||
/// 拥有的翅膀列表
|
||||
/// </summary>
|
||||
public List< BaseUserProp> wingList;
|
||||
public List<BaseUserProp> wingList;
|
||||
|
||||
/// <summary>
|
||||
/// 当前使用的战神
|
||||
@@ -101,10 +109,7 @@ namespace Assets.MyGame.Scripts.Net.API
|
||||
/// </summary>
|
||||
public StaticInfo @static;
|
||||
|
||||
/// <summary>
|
||||
/// 登录 Token
|
||||
/// </summary>
|
||||
public string token;
|
||||
|
||||
/// <summary>
|
||||
/// 玩家因子
|
||||
/// </summary>
|
||||
|
||||
Reference in New Issue
Block a user