示例#1
0
		private void CreateStats(CreepType type, CreepPropertiesXml properties)
		{
			CreepData creepData = properties.Get(type);
			Name = creepData.Name;
			CreateStat("Hp", creepData.MaxHp);
			CreateStat("Speed", creepData.Speed);
			CreateStat("Resistance", creepData.Resistance);
			CreateStat("Gold", creepData.GoldReward);
			if (Player.Current != null)
				ApplyBuff(new BuffEffect(Player.Current.Avatar.GetType().Name + "GoldMultiplier"));
			State = new CreepState();
			foreach (var modifier in creepData.TypeDamageModifier)
				State.SetVulnerabilityWithValue(modifier.Key, modifier.Value);
		}
示例#2
0
        private void CreateStats(CreepType type, CreepPropertiesXml properties)
        {
            CreepData creepData = properties.Get(type);

            Name = creepData.Name;
            CreateStat("Hp", creepData.MaxHp);
            CreateStat("Speed", creepData.Speed);
            CreateStat("Resistance", creepData.Resistance);
            CreateStat("Gold", creepData.GoldReward);
            if (Player.Current != null)
            {
                ApplyBuff(new BuffEffect(Player.Current.Avatar.GetType().Name + "GoldMultiplier"));
            }
            State = new CreepState();
            foreach (var modifier in creepData.TypeDamageModifier)
            {
                State.SetVulnerabilityWithValue(modifier.Key, modifier.Value);
            }
        }