public static Money operator /(Money m1, decimal m2) { decimal ret = (Decimal)Math.Ceiling((double)m1.TotalCopper / (double)m2); Money m = new Money(0, 0, ret); return m; }
public static Money operator *(Money m1, decimal m2) { var ret = Math.Ceiling(m1.TotalCopper * m2); Money m = new Money(0, 0, ret); return m; }
public static Money operator -(Money m1, Money m2) { var ret = m1.TotalCopper - m2.TotalCopper; Money m = new Money(0, 0, ret); return m; }
public HotItem() : this(false) { BuyContext = new ItemContext(false, this); BuyContext.Rules = BuyRules; BuyContext.DisplayName = "Buy"; SellContext = new ItemContext(true, this); SellContext.Rules = SellRules; SellContext.DisplayName = "Sell"; UnitPriceMoney = new Money(0, 0, 0); //SellMoney = new Money(); //BuyMoney = new Money(); }