protected override void StartShowWindow(object[] data) { qy.PlayerData player = data[0] as qy.PlayerData; playerdata = player; UpdatePanel(); }
public OfflineData(qy.PlayerData playerData) { storyid = playerData.questId; heartTime = (playerData.hertTimestamp * 1000).ToString(); gold = playerData.coinNum; heart = playerData.heartNum; star = playerData.starNum; name = playerData.nickName; uid = playerData.userId; level = playerData.eliminateLevel; roleId = playerData.role != null? playerData.role.id:""; items = new List <PlayerDataMessage.PropItem>(); foreach (qy.config.PropItem item in playerData.propsDic.Values) { PlayerDataMessage.PropItem prop = new PlayerDataMessage.PropItem(); prop.itemId = item.id; prop.count = item.count; prop.uuid = item.uuid; prop.vanishTime = item.vanishTime; items.Add(prop); } discipline = playerData.ability.discipline; loyalty = playerData.ability.loyalty; wisdom = playerData.ability.wisdom; storyExp = playerData.totalExp.ToString(); lvExp = playerData.currExp.ToString(); storyLv = playerData.level; roles = new List <PlayerDataMessage.RoleData>(); foreach (string id in playerData.rolesState.Keys) { qy.PlayerData.RoleState state = playerData.rolesState[id]; PlayerDataMessage.RoleData role = new PlayerDataMessage.RoleData(); role.roleId = id; role.status = (int)state; roles.Add(role); } stories = new List <PlayerDataMessage.StoryData>(); foreach (string id in playerData.complatedQuests.Keys) { PlayerDataMessage.StoryData storyData = new PlayerDataMessage.StoryData(); storyData.storyId = id; stories.Add(storyData); } timestamp = GameUtils.DateTimeToTimestamp(System.DateTime.Now).ToString(); }