protected virtual MiscItemFactory[] InitMiscFactories() { return(Data.MiscDescriptors .Select(wd => { var itemDescriptor = Data.GetItemDescriptor(ObjectCategory.Miscellenaous, wd.Identifer); switch (wd.Name) { case "Name Bones": return new ChampionBonesFactory( wd.Name, wd.Weight, ActionCombos[itemDescriptor.AttackCombo], GetStorageTypes(itemDescriptor.CarryLocation), RenderersSource.GetItemRenderer(ResourceProvider.Instance.Content.Load <Texture2D>(wd.TexturePath))); default: if (wd.FoodValue != null) { return new FoodMiscFactory( wd.FoodValue.Value, wd.Name, wd.Weight, ActionCombos[itemDescriptor.AttackCombo], GetStorageTypes(itemDescriptor.CarryLocation), RenderersSource.GetItemRenderer(ResourceProvider.Instance.Content.Load <Texture2D>(wd.TexturePath))); } else if (wd.WaterValue != null) { return new WaterMiscFactory( wd.WaterValue.Value, wd.Name, wd.Weight, ActionCombos[itemDescriptor.AttackCombo], GetStorageTypes(itemDescriptor.CarryLocation), RenderersSource.GetItemRenderer(ResourceProvider.Instance.Content.Load <Texture2D>(wd.TexturePath))); } else { return new MiscItemFactory( wd.Name, wd.Weight, ActionCombos[itemDescriptor.AttackCombo], GetStorageTypes(itemDescriptor.CarryLocation), RenderersSource.GetItemRenderer(ResourceProvider.Instance.Content.Load <Texture2D>(wd.TexturePath))); } } }) .ToArray()); }
protected virtual ScrollItemFactory[] InitScrollFactories() { return(Data.ScrollDescriptors .Select(wd => { var itemDescriptor = Data.GetItemDescriptor(ObjectCategory.Scroll, wd.Identifer); return new ScrollItemFactory( wd.Name, wd.Weight, ActionCombos[itemDescriptor.AttackCombo], GetStorageTypes(itemDescriptor.CarryLocation), RenderersSource.GetItemRenderer(ResourceProvider.Instance.Content.Load <Texture2D>(wd.TexturePath))); }) .ToArray()); }
protected override ExplosionProjectilSpell <TImpact> ApplySpellEffect(ILiveEntity entity, IPowerSymbol powerSymbol, int skillLevel) { int kineticEnergy = MathHelper.Clamp(21, (powerSymbol.LevelOrdinal + 2) * (4 + (skillLevel << 1)), 255); var values = F327_kzzz_CHAMPION_IsProjectileSpellCast(entity, kineticEnergy, 0); if (values != null) { var val = values.Value; var res = new ExplosionProjectilSpell <TImpact>(val.KineticEnergy, val.StepEnergy, val.Attack); res.Projectile.Renderer = RenderersSource.GetProjectileSpellRenderer(res.Projectile, Texture); return(res); } else { return(null); } }
protected virtual ClothItemFactory[] InitClothFactories() { return(Data.ArmorDescriptors .Select(wd => { var itemDescriptor = Data.GetItemDescriptor(ObjectCategory.Clothe, wd.Identifer); return new ClothItemFactory( wd.Name, wd.Weight, ActionCombos[itemDescriptor.AttackCombo], GetStorageTypes(itemDescriptor.CarryLocation), wd.ArmorStrength, wd.SharpResistance, false, //TODO is shield ? RenderersSource.GetItemRenderer(ResourceProvider.Instance.Content.Load <Texture2D>(wd.TexturePath))); }) .ToArray());; }
protected virtual WeaponItemFactory[] InitWeaponFactories() { return(Data.WeaponDescriptors .Select(wd => { var itemDescriptor = Data.GetItemDescriptor(ObjectCategory.Weapon, wd.Identifer); switch (itemDescriptor.InCategoryIndex) { case 2: return new TorchWeaponItemFactory( wd.Name, wd.Weight, ActionCombos[itemDescriptor.AttackCombo], GetStorageTypes(itemDescriptor.CarryLocation), wd.DeltaEnergy, (WeaponClass)wd.Class, wd.KineticEnergy, wd.ShootDamage, wd.Strength, RenderersSource.GetItemRenderer(ResourceProvider.Instance.Content.Load <Texture2D>(wd.TexturePath))); default: return new WeaponItemFactory( wd.Name, wd.Weight, ActionCombos[itemDescriptor.AttackCombo], GetStorageTypes(itemDescriptor.CarryLocation), wd.DeltaEnergy, (WeaponClass)wd.Class, wd.KineticEnergy, wd.ShootDamage, wd.Strength, RenderersSource.GetItemRenderer(ResourceProvider.Instance.Content.Load <Texture2D>(wd.TexturePath))); } }) .ToArray()); }