Esempio n. 1
0
        private bool _handleLimpetPurchasedEvent(LimpetPurchasedEvent @event)
        {
            Cargo cargo = GetCargoWithEDName("Drones") ?? new Cargo("Drones");

            cargo.AddDetailedQty(CargoType.owned, @event.amount, @event.price);
            AddOrUpdateCargo(cargo);
            return(true);
        }
Esempio n. 2
0
 private void handleLimpetPurchasedEvent(LimpetPurchasedEvent @event)
 {
     if (@event.timestamp > updateDat)
     {
         updateDat = @event.timestamp;
         if (_handleLimpetPurchasedEvent(@event))
         {
             writeInventory();
         }
     }
 }
Esempio n. 3
0
        public void _handleLimpetPurchasedEvent(LimpetPurchasedEvent @event)
        {
            Cargo cargo = GetCargoWithEDName("Drones");

            if (cargo != null)
            {
                cargo.owned += @event.amount;
            }
            else
            {
                Cargo newCargo = new Cargo("Drones", @event.amount, @event.price);
                newCargo.haulage = 0;
                newCargo.stolen  = 0;
                newCargo.owned   = @event.amount;
                AddCargo(newCargo);
            }
        }
Esempio n. 4
0
 private void handleLimpetPurchasedEvent(LimpetPurchasedEvent @event)
 {
     _handleLimpetPurchasedEvent(@event);
     writeInventory();
 }