public static bool IsCanSweepCopyScene(int sceneid) { //藏经阁谁都可以扫荡 if (sceneid == (int)Games.GlobeDefine.GameDefine_Globe.TLI_COPYSCENEID.TLI_CANGJINGGE) { return(true); } if (Singleton <ObjManager> .Instance.MainPlayer != null) { int nCost = Singleton <ObjManager> .Instance.MainPlayer.VipCost; int nLevel = 0; int nLeft = 0; GetVipLevel(nCost, ref nLevel, ref nLeft); Tab_VipBook tBook = TableManager.GetVipBookByID(nLevel, 0); if (tBook != null) { for (int i = 0; i < tBook.getSceneIdCount(); i++) { if (sceneid == tBook.GetSceneIdbyIndex(i)) { return(tBook.GetSweepCountbyIndex(i) > 0); } } } } return(false); }
public static int GetVipCopySceneMaxBuyNum(int sceneid) { Tab_VipBook tBook = TableManager.GetVipBookByID(GetVipLv(), 0); if (tBook != null) { for (int i = 0; i < tBook.getSceneIdCount(); i++) { if (sceneid == tBook.GetSceneIdbyIndex(i)) { return(tBook.GetBuyCountbyIndex(i)); } } } return(0); }
/* * 获得副本剩余可购买次数,包括剧情幅本 */ public static int GetVipCopySceneRemainBuyNum(int sceneid, bool bIsSingle) { Tab_VipBook pVipBook = TableManager.GetVipBookByID(GetVipLv(), 0); if (pVipBook == null) { return(GlobeVar.INVALID_ID); } if (GCGame.Utils.GetSceneType(sceneid) == (int)Games.GlobeDefine.GameDefine_Globe.SCENE_TYPE.SCENETYPE_STORYCOPYSCENE) { return(GameManager.gameManager.PlayerDataPool.CommonData.GetCommonData((int)Games.UserCommonData.USER_COMMONDATA.CD_VIP_STORY_COPYSCENE)); } else if (GCGame.Utils.GetSceneType(sceneid) == (int)Games.GlobeDefine.GameDefine_Globe.SCENE_TYPE.SCENETYPE_COPYSCENE) { if (pVipBook.getBuyCountCount() != s_nVipCopySceneArray.Length) { return(0); } if (bIsSingle) { for (int i = 0; i < pVipBook.getSceneIdCount(); ++i) { if (pVipBook.GetSceneIdbyIndex(i) == sceneid) { return(GameManager.gameManager.PlayerDataPool.CommonData.GetCommonData(s_nVipCopySceneArray[i])); } } } else { //这里还没有找到场景,去组队幅本里找 return(GetVipTeamCopySceneNum(sceneid)); } } return(GlobeVar.INVALID_ID); }