|
@@ -6,20 +6,19 @@ using ET;
|
|
|
|
|
|
namespace GFGGame
|
|
|
{
|
|
|
- public class StorySProxy
|
|
|
+ public class InstanceZonesSProxy
|
|
|
{
|
|
|
//请求剧情关卡数据
|
|
|
public static async ETTask GetStoryInfos()
|
|
|
{
|
|
|
- M2C_GetStoryInfos response = null;
|
|
|
- response = (M2C_GetStoryInfos)await MessageHelper.SendToServer(new C2M_GetStoryInfos());
|
|
|
+ M2C_GetInstanceZonesInfos response = null;
|
|
|
+ response = (M2C_GetInstanceZonesInfos)await MessageHelper.SendToServer(new C2M_GetInstanceZonesInfos());
|
|
|
if(response != null)
|
|
|
{
|
|
|
if(response.Error == ErrorCode.ERR_Success)
|
|
|
{
|
|
|
InstanceZonesDataManager.InitScoreList(response.ksScore, response.vsScore);
|
|
|
InstanceZonesDataManager.InitStarList(response.ksStar, response.vsStar);
|
|
|
- StoryDataManager.InitBoxBonusStates(response.ksBonusState, response.vsBonusState);
|
|
|
InstanceZonesDataManager.InitLevelPass(response.ksPass, response.VsPass);
|
|
|
}
|
|
|
}
|
|
@@ -28,8 +27,8 @@ namespace GFGGame
|
|
|
//完成剧情对话关卡
|
|
|
public static async ETTask FinishStoryDialogLevel(int levelCfgId)
|
|
|
{
|
|
|
- M2C_FinishStoryDialog response = null;
|
|
|
- response = (M2C_FinishStoryDialog)await MessageHelper.SendToServer(new C2M_FinishStoryDialog()
|
|
|
+ M2C_FinishInstanceZonesDialog response = null;
|
|
|
+ response = (M2C_FinishInstanceZonesDialog)await MessageHelper.SendToServer(new C2M_FinishInstanceZonesDialog()
|
|
|
{
|
|
|
LevelCfgId = levelCfgId
|
|
|
});
|
|
@@ -51,8 +50,8 @@ namespace GFGGame
|
|
|
//完成剧情战斗关卡
|
|
|
public static async ETTask FinishStoryFightLevel(int levelCfgId, int score, int npcScore, bool useRecomend)
|
|
|
{
|
|
|
- M2C_FinishStoryFightLevel response = null;
|
|
|
- response = (M2C_FinishStoryFightLevel)await MessageHelper.SendToServer(new C2M_FinishStoryFightLevel()
|
|
|
+ M2C_FinishInstanceZonesFightLevel response = null;
|
|
|
+ response = (M2C_FinishInstanceZonesFightLevel)await MessageHelper.SendToServer(new C2M_FinishInstanceZonesFightLevel()
|
|
|
{
|
|
|
LevelCfgId = levelCfgId,
|
|
|
Score = score,
|
|
@@ -66,8 +65,6 @@ namespace GFGGame
|
|
|
//更新数据
|
|
|
InstanceZonesDataManager.TryUpdateScore(response.LevelCfgId, response.Score);
|
|
|
InstanceZonesDataManager.TryUpdateLevelStar(response.LevelCfgId, response.Star);
|
|
|
- var levelCfg = StoryLevelCfgArray.Instance.GetCfg(levelCfgId);
|
|
|
- StoryDataManager.UpdateBoxBonusStates(levelCfg.chapterId, response.BoxStates);
|
|
|
//展示奖励
|
|
|
List<ItemData> bonusList = StoryBonusDataCache.GetBonusList(response.LevelCfgId, response.HasOnceBonus);
|
|
|
if(response.RandomBonusList != null)
|
|
@@ -102,8 +99,8 @@ namespace GFGGame
|
|
|
//剧情战斗关卡失败,更新最高分
|
|
|
public static async ETTask StoryFightLevelFail(int levelCfgId, int score)
|
|
|
{
|
|
|
- M2C_FinishStoryFightLevelFail response = null;
|
|
|
- response = (M2C_FinishStoryFightLevelFail)await MessageHelper.SendToServer(new C2M_FinishStoryFightLevelFail()
|
|
|
+ M2C_FinishInstanceZonesFightLevelFail response = null;
|
|
|
+ response = (M2C_FinishInstanceZonesFightLevelFail)await MessageHelper.SendToServer(new C2M_FinishInstanceZonesFightLevelFail()
|
|
|
{
|
|
|
LevelCfgId = levelCfgId,
|
|
|
Score = score,
|
|
@@ -120,8 +117,8 @@ namespace GFGGame
|
|
|
//快速完成关卡战斗
|
|
|
public static async ETTask FinishStoryFightQuickly(int levelCfgId, int times)
|
|
|
{
|
|
|
- M2C_FinishStoryFightQuickly response = null;
|
|
|
- response = (M2C_FinishStoryFightQuickly)await MessageHelper.SendToServer(new C2M_FinishStoryFightQuickly()
|
|
|
+ M2C_FinishInstanceZonesFightQuickly response = null;
|
|
|
+ response = (M2C_FinishInstanceZonesFightQuickly)await MessageHelper.SendToServer(new C2M_FinishInstanceZonesFightQuickly()
|
|
|
{
|
|
|
LevelCfgId = levelCfgId,
|
|
|
times = times
|