| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116 | 
							- using System;
 
- using UnityEngine;
 
- using FairyGUI;
 
- using ET;
 
- using System.Collections.Generic;
 
- namespace GFGGame
 
- {
 
-     public class RoleDataManager
 
-     {
 
-         public static bool powerTimeServerLock;
 
-         public static long roleId;
 
-         public static string roleName;
 
-         public static int rechargeTotal;
 
-         public static int rechargeTotalMon;
 
-         public static int power
 
-         {
 
-             get
 
-             {
 
-                 return GameGlobal.myNumericComponent.GetAsInt(NumericType.Power);
 
-             }
 
-         }
 
-         public static int gold
 
-         {
 
-             get
 
-             {
 
-                 return ItemDataManager.GetItemNum(ConstItemID.GOLD); //GameGlobal.myNumericComponent.GetAsInt(NumericType.Gold);
 
-             }
 
-         }
 
-         private static int _exp = 0;
 
-         public static int exp
 
-         {
 
-             get
 
-             {
 
-                 return GameGlobal.myNumericComponent.GetAsInt(NumericType.Exp);
 
-             }
 
-         }
 
-         public static int lvl
 
-         {
 
-             get
 
-             {
 
-                 return GameGlobal.myNumericComponent.GetAsInt(NumericType.Lvl);
 
-             }
 
-         }
 
-         public static int diaP
 
-         {
 
-             get
 
-             {
 
-                 return ItemDataManager.GetItemNum(ConstItemID.DIAMOND_PURPLE); // GameGlobal.myNumericComponent.GetAsInt(NumericType.DiamondP);
 
-             }
 
-         }
 
-         public static int diaR
 
-         {
 
-             get
 
-             {
 
-                 return ItemDataManager.GetItemNum(ConstItemID.DIAMOND_RED); //GameGlobal.myNumericComponent.GetAsInt(NumericType.DiamondR);
 
-             }
 
-         }
 
-         public static int Liveness
 
-         {
 
-             get
 
-             {
 
-                 return GameGlobal.myNumericComponent.GetAsInt(NumericType.Liveness);
 
-             }
 
-         }
 
-         public static bool CheckPowerFull()
 
-         {
 
-             return RoleDataManager.power >= GameGlobal.myNumericComponent.GetAsInt(NumericType.PowerLimit);
 
-         }
 
-         public static void InitServerData()
 
-         {
 
-             roleName = GameGlobal.zoneScene.GetComponent<RoleInfosComponent>().GetCurrentRoleName();
 
-         }
 
-         private static int oldLvValue;
 
-         public static void RoleLvUp(int oldValue)
 
-         {
 
-             oldLvValue = oldValue;
 
-             Timers.inst.Remove(CheckUpLv);
 
-             Timers.inst.Remove(OpenRoleLvUpView);
 
-             Timers.inst.Add(1, 0, CheckUpLv);
 
-         }
 
-         private static void CheckUpLv(object param)
 
-         {
 
-             if (GuideDataManager.currentGuideId > 0) return;
 
-             if (ViewManager.isViewOpen(typeof(FunctionOpenView).Name)) return;//等功能开启展示完成后再展示角色升级
 
-             if (GRoot.inst.GetTopWindow() == null)
 
-             {
 
-                 OpenRoleLvUpView(null);
 
-                 Timers.inst.Remove(CheckUpLv);
 
-             }
 
-             
 
-             if (ViewManager.isViewOpen(typeof(StroyFightResultView).Name))
 
-             {
 
-                 Timers.inst.Add(0.2f, 1, OpenRoleLvUpView);
 
-             }
 
-         }
 
-         private static void OpenRoleLvUpView(object param)
 
-         {
 
-             ViewManager.Show<RoleLvUpView>(oldLvValue);
 
-             Timers.inst.Remove(CheckUpLv);
 
-         }
 
-     }
 
- }
 
 
  |