public override void Deserialize(GenericReader reader) { base.Deserialize(reader); var version = reader.GetVersion(); if (version < 2) { WebForm = new DonationWebFormOptions(); } switch (version) { case 4: FallbackAccount = reader.ReadAccount(); goto case 3; case 3: CreditBonus = reader.ReadDouble(); goto case 2; case 2: WebForm = new DonationWebFormOptions(reader); goto case 1; case 1: TierFactor = reader.ReadDouble(); goto case 0; case 0: { if (version < 2) { new MySQLConnectionInfo(reader); // MySQL _CurrencyType = new ItemTypeSelectProperty(reader); // CurrencyType reader.ReadString(); // TableName } ShowHistory = reader.ReadBool(); if (version < 2) { CurrencyPrice = reader.ReadDouble(); // UnitPrice } MoneySymbol = reader.ReadChar(); if (version < 2) { MoneyAbbr = reader.ReadString(); // MoneyAbbr reader.ReadBool(); // GiftingEnabled } } break; } Info = new DonationStatistics(); }
public EtherealCharcoalDeed() : base(0x14F0) { Name = "an ethereal charcoal dyeing deed"; Weight = 1.0; LootType = LootType.Blessed; EtherealType = typeof(EtherealHorse); Hue = 1175; }
public EtherealCharcoalDeed() : base( 0x14F0 ) { Name = "an ethereal charcoal dyeing deed"; Weight = 1.0; LootType = LootType.Blessed; EtherealType = typeof(EtherealHorse); Hue = 1175; }
public override void Deserialize(GenericReader reader) { base.Deserialize(reader); LootType = LootType.Blessed; reader.ReadInt(); EtherealType = reader.ReadType(); }
public override void Deserialize( GenericReader reader ) { base.Deserialize( reader ); LootType = LootType.Blessed; reader.ReadInt(); EtherealType = reader.ReadType(); }
public override void Clear() { base.Clear(); MySQL = new MySQLConnectionInfo("", 0, "", "", ODBCVersion.V_5_1, ""); MoneySymbol = ' '; MoneyAbbr = ""; TableName = ""; ShowHistory = false; GiftingEnabled = false; ExchangeRate = 1.0; CurrencyType = "Gold"; }
public override void Reset() { base.Reset(); MySQL = new MySQLConnectionInfo("localhost", 3306, "root", "", ODBCVersion.V_5_1, "donate_db"); MoneySymbol = '$'; MoneyAbbr = "USD"; TableName = "donate_trans"; ShowHistory = false; GiftingEnabled = true; ExchangeRate = 1.0; CurrencyType = "Gold"; }
public override void Clear() { base.Clear(); MySQL = new MySQLConnectionInfo("", 0, "", "", ODBCVersion.V_5_1, ""); MoneySymbol = ' '; MoneyAbbr = ""; TableName = ""; ShowHistory = false; GiftingEnabled = false; ExchangeRate = 1.0; CurrencyType = "Gold"; }
public override void Deserialize(GenericReader reader) { base.Deserialize(reader); var version = reader.GetVersion(); switch (version) { case 2: _CashAbbr = reader.ReadTextDef(); goto case 1; case 1: CashProperty = new ObjectProperty(reader); goto case 0; case 0: { if (version < 1) { var t = new ItemTypeSelectProperty(reader); CashType = t.InternalType; } else { CashType = new TypeSelectProperty <object>(reader); } _CashName = reader.ReadTextDef(); _ShowCashName = reader.ReadBool(); _Trading = reader.ReadBool(); Discount = reader.ReadInt(); DiscountEnabled = reader.ReadBool(); DiscountYell = reader.ReadBool(); } break; } if (CashProperty == null) { CashProperty = new ObjectProperty(); } if (version < 2) { _CashAbbr = String.Join(String.Empty, _CashName.GetString().Select(Char.IsUpper)); } }
public override void Deserialize(GenericReader reader) { base.Deserialize(reader); int version = reader.GetVersion(); switch (version) { case 1: CashProperty = new ObjectProperty(reader); goto case 0; case 0: { if (version < 1) { var t = new ItemTypeSelectProperty(reader); CashType = t.InternalType; } else { CashType = new TypeSelectProperty <object>(reader); } CashName = reader.ReadTextDef(); ShowCashName = reader.ReadBool(); Trading = reader.ReadBool(); Discount = reader.ReadInt(); DiscountEnabled = reader.ReadBool(); DiscountYell = reader.ReadBool(); } break; } if (CashProperty == null) { CashProperty = new ObjectProperty(); } }
public override void Deserialize(GenericReader reader) { base.Deserialize(reader); int version = reader.GetVersion(); switch (version) { case 0: { MySQL = new MySQLConnectionInfo(reader); CurrencyType = new ItemTypeSelectProperty(reader); TableName = reader.ReadString(); ShowHistory = reader.ReadBool(); ExchangeRate = reader.ReadDouble(); MoneySymbol = reader.ReadChar(); MoneyAbbr = reader.ReadString(); GiftingEnabled = reader.ReadBool(); } break; } }
public override void Deserialize(GenericReader reader) { base.Deserialize(reader); var version = reader.GetVersion(); switch (version) { case 4: { reader.ReadDictionary( r => { var info = new DynamicBuyInfo(r); return(new KeyValuePair <Item, DynamicBuyInfo>(info.Item, info)); }, _DynamicStock); } goto case 3; case 3: { _WasStocked = reader.ReadBool(); CanRestock = reader.ReadBool(); } goto case 2; case 2: _CashAbbr = reader.ReadTextDef(); goto case 1; case 1: CashProperty = new ObjectProperty(reader); goto case 0; case 0: { if (version < 1) { var t = new ItemTypeSelectProperty(reader); CashType = t.InternalType; } else { CashType = new TypeSelectProperty <object>(reader); } _CashName = reader.ReadTextDef(); _ShowCashName = reader.ReadBool(); _Trading = reader.ReadBool(); Discount = reader.ReadInt(); DiscountEnabled = reader.ReadBool(); DiscountYell = reader.ReadBool(); } break; } if (CashProperty == null) { CashProperty = new ObjectProperty(); } if (version < 3) { CanRestock = true; } if (version < 2) { _CashAbbr = String.Join(String.Empty, _CashName.GetString().Select(Char.IsUpper)); } _DynamicStock.RemoveRange(o => o.Key.Deleted || o.Value == null || o.Value.Item != o.Key); }
public override void Reset() { base.Reset(); MySQL = new MySQLConnectionInfo("localhost", 3306, "root", "", ODBCVersion.V_5_1, "donate_db"); MoneySymbol = '$'; MoneyAbbr = "USD"; TableName = "donate_trans"; ShowHistory = false; GiftingEnabled = true; ExchangeRate = 1.0; CurrencyType = "Gold"; }
public override void Deserialize(GenericReader reader) { base.Deserialize(reader); int version = reader.GetVersion(); switch (version) { case 0: { MySQL = new MySQLConnectionInfo(reader); CurrencyType = new ItemTypeSelectProperty(reader); TableName = reader.ReadString(); ShowHistory = reader.ReadBool(); ExchangeRate = reader.ReadDouble(); MoneySymbol = reader.ReadChar(); MoneyAbbr = reader.ReadString(); GiftingEnabled = reader.ReadBool(); } break; } }
public override void Deserialize(GenericReader reader) { base.Deserialize(reader); var version = reader.GetVersion(); if (version < 2) { WebForm = new DonationWebFormOptions(); } switch (version) { case 4: FallbackAccount = reader.ReadAccount(); goto case 3; case 3: CreditBonus = reader.ReadDouble(); goto case 2; case 2: WebForm = new DonationWebFormOptions(reader); goto case 1; case 1: TierFactor = reader.ReadDouble(); goto case 0; case 0: { if (version < 2) { new MySQLConnectionInfo(reader); // MySQL _CurrencyType = new ItemTypeSelectProperty(reader); // CurrencyType reader.ReadString(); // TableName } ShowHistory = reader.ReadBool(); if (version < 2) { CurrencyPrice = reader.ReadDouble(); // UnitPrice } MoneySymbol = reader.ReadChar(); if (version < 2) { MoneyAbbr = reader.ReadString(); // MoneyAbbr reader.ReadBool(); // GiftingEnabled } } break; } Info = new DonationStatistics(); }