public WeihuaGames.ClientClass.RecruiteNpc FromProtobuf(com.kodgames.corgi.protocol.RecruiteNpc recruiteNpc) { if (recruiteNpc != null) { this.npcId = recruiteNpc.npcId; this.avatarId = recruiteNpc.avatarId; this.name = recruiteNpc.name; this.level = recruiteNpc.level; this.traitType = recruiteNpc.traitType; this.breakthroughLevel = recruiteNpc.breakthroughLevel; this.qualityType = recruiteNpc.qualityType; this.npcDesc = recruiteNpc.npcDesc; foreach (int num in recruiteNpc.skillIds) { this.skillIds.Add(num); } foreach (com.kodgames.corgi.protocol.Attribute attribute in recruiteNpc.attributes) { WeihuaGames.ClientClass.Attribute item = new WeihuaGames.ClientClass.Attribute(); item.FromProtobuf(attribute); this.attributes.Add(item); } } return(this); }
public void ShallowCopy(WeihuaGames.ClientClass.Avatar avatar) { this.guid = avatar.Guid; this.resourceId = avatar.ResourceId; this.levelAttrib.Level = avatar.LevelAttrib.Level; this.levelAttrib.Experience = avatar.LevelAttrib.Experience; this.BreakthoughtLevel = avatar.BreakthoughtLevel; this.attributes = avatar.Attributes; this.meridianDatas = avatar.meridianDatas; this.domineer = avatar.domineer; this.isAvatar = avatar.isAvatar; this.traitType = avatar.traitType; this.name = avatar.name; }
public void Copy(WeihuaGames.ClientClass.CombatAvatarData data) { this.avatarType = data.avatarType; this.resourceId = data.resourceId; this.breakThrough = data.breakThrough; this.displayName = data.displayName; this.battlePosition = data.battlePosition; this.evaluation = data.evaluation; this.scale = data.scale; this.npcType = data.npcType; this.levelAttrib.Copy(data.LevelAttrib); this.equipments = new List <WeihuaGames.ClientClass.EquipmentData>(); this.illusionID = data.illusionID; foreach (WeihuaGames.ClientClass.EquipmentData data2 in data.equipments) { WeihuaGames.ClientClass.EquipmentData item = new WeihuaGames.ClientClass.EquipmentData(); item.Copy(data2); this.equipments.Add(item); } this.skills = new List <WeihuaGames.ClientClass.SkillData>(); foreach (WeihuaGames.ClientClass.SkillData data4 in data.Skills) { WeihuaGames.ClientClass.SkillData data5 = new WeihuaGames.ClientClass.SkillData(); data5.Copy(data4); this.skills.Add(data5); } this.buffs = new List <WeihuaGames.ClientClass.BuffData>(); foreach (WeihuaGames.ClientClass.BuffData data6 in data.buffs) { WeihuaGames.ClientClass.BuffData data7 = new WeihuaGames.ClientClass.BuffData(); data7.Copy(data6); this.buffs.Add(data7); } this.attributes = new List <WeihuaGames.ClientClass.Attribute>(); foreach (WeihuaGames.ClientClass.Attribute attribute in data.Attributes) { WeihuaGames.ClientClass.Attribute attribute2 = new WeihuaGames.ClientClass.Attribute(); attribute2.Copy(attribute); this.attributes.Add(attribute2); } }
public void ShallowCopy(WeihuaGames.ClientClass.RecruiteNpc recruiteNpc) { this.avatarId = recruiteNpc.avatarId; this.name = recruiteNpc.name; this.level = recruiteNpc.level; this.npcId = recruiteNpc.npcId; this.traitType = recruiteNpc.traitType; this.breakthroughLevel = recruiteNpc.breakthroughLevel; this.qualityType = recruiteNpc.qualityType; this.npcDesc = recruiteNpc.npcDesc; this.skillIds.Clear(); foreach (int num in recruiteNpc.skillIds) { this.skillIds.Add(num); } this.attributes.Clear(); foreach (WeihuaGames.ClientClass.Attribute attribute in recruiteNpc.attributes) { WeihuaGames.ClientClass.Attribute item = new WeihuaGames.ClientClass.Attribute(); item.Copy(attribute); this.attributes.Add(item); } }
public void Copy(WeihuaGames.ClientClass.Attribute attrib) { this.type = attrib.type; this.value = attrib.value; }