public Relic(RelicTransferModel relic) { relicName = relic.RelicName; relicSpriteName = relic.RelicSpriteName; relicDescription = relic.RelicDescription; relicRarity = relic.RelicRarity; relicEffects = new List <Effect>(); foreach (var item in relic.RelicEffectsString) { string[] s = item.Split(' '); var effectType = Type.GetType("Models." + s[0] + "Effect"); Effect effect = Activator.CreateInstance(effectType) as Effect; List <string> temp = new List <string>(); foreach (var i in Enumerable.Range(1, s.Length - 1)) { temp.Add(s[i]); } effect.SetEffect(temp); relicEffects.Add(effect); } }
public Armor(string name, int armorClass, Rarity rarity) : base(name, rarity) { ArmorClass = armorClass; }
//----------------------------------------------------------------------------------------------------------------------------------------------// // CONSTRUCTORS // //----------------------------------------------------------------------------------------------------------------------------------------------// public Skin(int ID, string Weapon, string Name, string Collection, int PatternID, double SkinFloat, decimal Price, DateTime DateAdded, Rarity Rarity) { id = ID; weapon = Weapon; name = Name; collection = Collection; patternID = PatternID; skinFloat = SkinFloat / 1000000000; price = Price; dateAdded = DateAdded; rarity = Rarity; }
public GameItem(string name, Rarity rarity) { Name = name; Rarity = rarity; }
public Weapon(string name, int damage, float attackSpeed, Rarity rarity) : base(name, rarity) { Damage = damage; AttackSpeed = attackSpeed; }