Пример #1
0
        public static void Action(FCEvent evt, bool canUseShuttle = false)
        {
            try
            {
                TaxDeliveryMode taxDeliveryMode = TaxDeliveryModeForSettlement(canUseShuttle);

                switch (taxDeliveryMode)
                {
                case TaxDeliveryMode.Caravan:
                    SendCaravan(evt);
                    break;

                case TaxDeliveryMode.DropPod:
                    SendDropPod(evt);
                    break;

                case TaxDeliveryMode.Shuttle:
                    SendShuttle(evt);
                    break;

                default:
                    SpawnOnTaxSpot(evt);
                    break;
                }
            }
            catch (Exception e)
            {
                Log.ErrorOnce("Critical delivery failure, spawning things on tax spot instead! Message: " + e.Message + " StackTrace: " + e.StackTrace + " Source: " + e.Source, 77239232);
                evt.goods.ForEach(thing => PaymentUtil.placeThing(thing));
            }
        }
Пример #2
0
 private static void SpawnOnTaxSpot(FCEvent evt)
 {
     MakeDeliveryLetterAndMessage(evt);
     evt.goods.ForEach(thing => PaymentUtil.placeThing(thing));
 }