功能批量实现 优化 服务端 新浮动小游戏框架 新界面UI
This commit is contained in:
File diff suppressed because it is too large
Load Diff
@@ -55,6 +55,13 @@ public class GameServerBridge : MonoBehaviour
|
||||
var nm = NetworkManager.Instance;
|
||||
if (nm == null) { Debug.LogWarning("[Bridge] NetworkManager 不存在"); return; }
|
||||
|
||||
ArenaRoomService arenaRoomService = ArenaRoomService.Instance;
|
||||
if (arenaRoomService != null && arenaRoomService.IsInRoom)
|
||||
{
|
||||
Debug.Log("[Bridge] 当前处于房间模式,跳过世界排行榜提交");
|
||||
return;
|
||||
}
|
||||
|
||||
_hasSubmitted = true;
|
||||
|
||||
try
|
||||
|
||||
@@ -49,6 +49,33 @@ namespace GameServer.Client
|
||||
[JsonProperty("message")] public string message;
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public class AvatarUploadResponse
|
||||
{
|
||||
[JsonProperty("success")] public bool success;
|
||||
[JsonProperty("steam_id")] public string steam_id;
|
||||
[JsonProperty("avatar_url")] public string avatar_url;
|
||||
[JsonProperty("error_code")] public string error_code;
|
||||
[JsonProperty("message")] public string message;
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public class SteamFriendsImportRequest
|
||||
{
|
||||
[JsonProperty("steam_id")] public string steam_id;
|
||||
[JsonProperty("steam_friends")] public List<string> steam_friends;
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public class SteamFriendsImportResponse
|
||||
{
|
||||
[JsonProperty("success")] public bool success;
|
||||
[JsonProperty("added")] public int added;
|
||||
[JsonProperty("skipped")] public int skipped;
|
||||
[JsonProperty("error_code")] public string error_code;
|
||||
[JsonProperty("message")] public string message;
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public class ProfileData
|
||||
{
|
||||
@@ -56,6 +83,7 @@ namespace GameServer.Client
|
||||
[JsonProperty("error_code")] public string error_code;
|
||||
[JsonProperty("message")] public string message;
|
||||
[JsonProperty("steam_id")] public string steam_id;
|
||||
[JsonProperty("uid")] public int uid;
|
||||
[JsonProperty("display_name")] public string display_name;
|
||||
[JsonProperty("avatar_url")] public string avatar_url;
|
||||
[JsonProperty("player_level")] public int player_level;
|
||||
@@ -216,7 +244,9 @@ namespace GameServer.Client
|
||||
public class ArenaRoomParticipant
|
||||
{
|
||||
[JsonProperty("steam_id")] public string steam_id;
|
||||
[JsonProperty("uid")] public int uid;
|
||||
[JsonProperty("display_name")] public string display_name;
|
||||
[JsonProperty("avatar_url")] public string avatar_url;
|
||||
[JsonProperty("is_host")] public bool is_host;
|
||||
[JsonProperty("is_ready")] public bool is_ready;
|
||||
[JsonProperty("join_order")] public int join_order;
|
||||
@@ -258,4 +288,172 @@ namespace GameServer.Client
|
||||
[JsonProperty("has_submitted")] public bool has_submitted;
|
||||
[JsonProperty("join_order")] public int join_order;
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public class ArenaRoomChatMessage
|
||||
{
|
||||
[JsonProperty("id")] public long id;
|
||||
[JsonProperty("room_code")] public string room_code;
|
||||
[JsonProperty("steam_id")] public string steam_id;
|
||||
[JsonProperty("sender_id")] public string sender_id;
|
||||
[JsonProperty("receiver_id")] public string receiver_id;
|
||||
[JsonProperty("uid")] public int uid;
|
||||
[JsonProperty("display_name")] public string display_name;
|
||||
[JsonProperty("avatar_url")] public string avatar_url;
|
||||
[JsonProperty("content")] public string content;
|
||||
[JsonProperty("created_at")] public string created_at;
|
||||
[JsonProperty("is_read")] public int is_read;
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public class ArenaRoomHistoryData
|
||||
{
|
||||
[JsonProperty("room_code")] public string room_code;
|
||||
[JsonProperty("messages")] public List<ArenaRoomChatMessage> messages;
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public class SocialWorldHistoryData
|
||||
{
|
||||
[JsonProperty("messages")] public List<ArenaRoomChatMessage> messages;
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public class SocialPrivateHistoryData
|
||||
{
|
||||
[JsonProperty("partner_id")] public string partner_id;
|
||||
[JsonProperty("messages")] public List<ArenaRoomChatMessage> messages;
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public class SocialFriendEntry
|
||||
{
|
||||
[JsonProperty("friend_steam_id")] public string friend_steam_id;
|
||||
[JsonProperty("uid")] public int uid;
|
||||
[JsonProperty("friend_name")] public string friend_name;
|
||||
[JsonProperty("friend_avatar")] public string friend_avatar;
|
||||
[JsonProperty("online")] public bool online;
|
||||
[JsonProperty("status")] public string status;
|
||||
[JsonProperty("since")] public string since;
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public class SocialFriendsListData
|
||||
{
|
||||
[JsonProperty("friends")] public List<SocialFriendEntry> friends;
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public class SocialFriendsApiResponse
|
||||
{
|
||||
[JsonProperty("success")] public bool success;
|
||||
[JsonProperty("friends")] public List<SocialFriendEntry> friends;
|
||||
[JsonProperty("added")] public int added;
|
||||
[JsonProperty("skipped")] public int skipped;
|
||||
[JsonProperty("error_code")] public string error_code;
|
||||
[JsonProperty("message")] public string message;
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public class MailApiRewardEntry
|
||||
{
|
||||
[JsonProperty("reward_name")] public string reward_name;
|
||||
[JsonProperty("reward_type")] public string reward_type;
|
||||
[JsonProperty("reward_amount")] public int reward_amount;
|
||||
[JsonProperty("reward_description")] public string reward_description;
|
||||
[JsonProperty("reward_key")] public string reward_key;
|
||||
[JsonProperty("reward_store_item_id")] public int reward_store_item_id;
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public class MailApiEntry
|
||||
{
|
||||
[JsonProperty("mail_id")] public int mail_id;
|
||||
[JsonProperty("mail_title")] public string mail_title;
|
||||
[JsonProperty("mail_sender")] public string mail_sender;
|
||||
[JsonProperty("mail_date")] public string mail_date;
|
||||
[JsonProperty("mail_body")] public string mail_body;
|
||||
[JsonProperty("mail_description")] public string mail_description;
|
||||
[JsonProperty("mail_image_url")] public string mail_image_url;
|
||||
[JsonProperty("updated_at")] public string updated_at;
|
||||
[JsonProperty("rewards")] public List<MailApiRewardEntry> rewards;
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public class MailApiDeletionEntry
|
||||
{
|
||||
[JsonProperty("deletion_id")] public int deletion_id;
|
||||
[JsonProperty("mail_id")] public int mail_id;
|
||||
[JsonProperty("title")] public string title;
|
||||
[JsonProperty("reclaim_rewards")] public bool reclaim_rewards;
|
||||
[JsonProperty("deleted_at")] public string deleted_at;
|
||||
[JsonProperty("rewards")] public List<MailApiRewardEntry> rewards;
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public class MailApiVersionResponse
|
||||
{
|
||||
[JsonProperty("success")] public bool success;
|
||||
[JsonProperty("revision")] public string revision;
|
||||
[JsonProperty("count")] public int count;
|
||||
[JsonProperty("error_code")] public string error_code;
|
||||
[JsonProperty("message")] public string message;
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public class MailApiListResponse
|
||||
{
|
||||
[JsonProperty("success")] public bool success;
|
||||
[JsonProperty("revision")] public string revision;
|
||||
[JsonProperty("count")] public int count;
|
||||
[JsonProperty("mails")] public List<MailApiEntry> mails;
|
||||
[JsonProperty("deletions")] public List<MailApiDeletionEntry> deletions;
|
||||
[JsonProperty("error_code")] public string error_code;
|
||||
[JsonProperty("message")] public string message;
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public class MailClaimRequest
|
||||
{
|
||||
[JsonProperty("steam_id")] public string steam_id;
|
||||
[JsonProperty("mail_id")] public int mail_id;
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public class MailClaimResponse
|
||||
{
|
||||
[JsonProperty("success")] public bool success;
|
||||
[JsonProperty("mail_id")] public int mail_id;
|
||||
[JsonProperty("steam_id")] public string steam_id;
|
||||
[JsonProperty("error_code")] public string error_code;
|
||||
[JsonProperty("message")] public string message;
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public class SocialPresenceUpdateData
|
||||
{
|
||||
[JsonProperty("steam_id")] public string steam_id;
|
||||
[JsonProperty("uid")] public int uid;
|
||||
[JsonProperty("display_name")] public string display_name;
|
||||
[JsonProperty("avatar_url")] public string avatar_url;
|
||||
[JsonProperty("status")] public string status;
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public class SocialFriendRequestEntry
|
||||
{
|
||||
[JsonProperty("id")] public long id;
|
||||
[JsonProperty("from_steam_id")] public string from_steam_id;
|
||||
[JsonProperty("uid")] public int uid;
|
||||
[JsonProperty("from_name")] public string from_name;
|
||||
[JsonProperty("from_avatar")] public string from_avatar;
|
||||
[JsonProperty("created_at")] public string created_at;
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public class SocialFriendRequestsListData
|
||||
{
|
||||
[JsonProperty("requests")] public List<SocialFriendRequestEntry> requests;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user