You are viewing a potentially older version of this package. View all versions.
Solon-RandomDelivery-1.5.5 icon

RandomDelivery

A dropship delivers 2-4 random free shop items to your ship each day - some arrive as live traps or hostile monsters instead. Host-synced, configurable, with in-game LethalConfig support.

Date uploaded 2 weeks ago
Version 1.5.5
Download link Solon-RandomDelivery-1.5.5.zip
Downloads 772
Dependency string Solon-RandomDelivery-1.5.5

This mod requires the following mods to function

BepInEx-BepInExPack-5.4.2100 icon
BepInEx-BepInExPack

BepInEx pack for Mono Unity games. Preconfigured and ready to use.

Preferred version: 5.4.2100

README

RandomDelivery

RANDOM DELIVERY

Lethal Company BepInEx Version License

Language / Язык: English · Русский

RANDOM DELIVERY

Author: Solo00n

Every morning the item dropship flies in and drops a free batch of random shop items on your landing pad — except some of them arrive as live traps or hostile monsters instead.

WHAT IT DOES

  • Daily air-drop — the game's real item dropship is dispatched on schedule, lands by the ship and drops a batch of 2–4 random buyable items, for free (your credits are untouched).
  • Auto item pool — pulls every orderable item from the terminal shop, including ones other mods add; ship upgrades are excluded.
  • Selection modes — Random (equal chance) or PriceWeighted (cheaper items are more likely, with an optional on-sale boost).
  • Traps and monsters — each slot can instead be a live trap (Turret / Landmine) or a small monster, dropped at the ship's own spots when its hatch opens.
  • Whole-delivery modes — a once-per-delivery chance the entire delivery is all traps, or all monsters.
  • Allow / block lists — for items, traps and monsters, so you decide exactly what can arrive.
  • Flexible schedule — dispatch time(s) on the in-game clock, several deliveries per day, per-slot replacement chances.
  • Take-off cleanup — the moment the ship leaves the planet, everything the delivery left behind (its traps, monsters and any items still lying outside) is removed; loot brought aboard is kept.
  • In-game config — every setting is editable live through LethalConfig.

HOW IT WORKS

  • Items ride the vanilla ItemDropship: the chosen indices are added to Terminal.orderedItemsFromTerminal (the same list a paid order uses, minus the credit charge), so the ship flies in, lands and drops them exactly where terminal orders land.
  • The descent is started at the scheduled DeliveryTimes clock time, and traps/monsters spawn at the ship's own item-drop spots the moment its hatch opens, so everything arrives together in the same place.
  • Monsters spawn via RoundManager.SpawnEnemyGameObject, traps via NetworkObject.Spawn — no custom network objects.
  • The monster pool is built from every loaded EnemyType filtered by the allow-list, so any allowed small monster can appear on any moon.

MULTIPLAYER (HOST-AUTHORITATIVE)

Only the host generates and dispatches deliveries; clients never generate their own, so everyone shares one authoritative delivery.

Items: queued onto the host's terminal order and delivered by the game's own dropship, which replicates to all clients.
Traps and monsters: spawned server-side through NetworkObject.Spawn / SpawnEnemyGameObject, so all clients see the same result.
Install: the host must have the mod; clients receive everything through Netcode. Install it on everyone so the whole lobby shares the same config.

REQUIREMENTS

  • BepInEx 5.4.21+ (BepInEx-BepInExPack-5.4.2100)
  • Lethal Company V81
  • Optional: LethalConfig for editing settings in-game.

INSTALLATION

  • Mod manager (r2modman / Thunderstore Mod Manager): search for the mod and click Install.
  • Manual: install the BepInEx pack, then drop RandomDelivery.dll into BepInEx/plugins/.

CONFIGURATION

File: BepInEx/config/Timofey.RandomDelivery.cfg (created on first launch). The .cfg is re-read at the start of every day, and can also be edited live in the LethalConfig menu.

KeyDefaultDescription
EnabledtrueMaster switch for the whole mod.
DeliveryTimes08:30Comma-separated in-game times the dropship is dispatched (day starts 06:00). Each is an HH:MM time, StartOfDay, or a number of seconds after landing. List several for multiple deliveries.
MaxDeliveriesPerDay1Hard cap on deliveries per day.
MinItems / MaxItems2 / 4Slots per delivery (inclusive range).
ItemSelectionModeRandomRandom or PriceWeighted.
PriceWeightFactor1.0Price-weighting steepness (0 = flat, 1 = inverse price, 2 = strongly favour cheap).
DiscountBoosttrueBoost on-sale items in PriceWeighted mode.
DropshipAutoOpenfalseOpen the hatch by itself on landing instead of waiting for a player.
ChanceForTrap / ChanceForMonster15 / 10Per-slot % chance a slot becomes a trap / a monster.
PriorityMonsterWinner when both a trap and a monster hit the same slot.
ChanceForAllTraps / ChanceForAllMonsters0 / 0Once-per-delivery chance the whole delivery is all traps / all monsters.
ChanceForVehicle0Once-per-delivery chance the dropship brings a free Cruiser instead of items; once it does, the rest of the day's deliveries are cancelled.
BypassMonstersGordionLimittrueWhen MonstersGordion is installed, register monsters delivered on 71-Gordion as owned by it, so its cleanup does not despawn them.
SpawnStaggerSeconds0.2Pause between each delivered trap/monster spawn, so a batch never lands in one frame burst.
PrewarmSpawnPrefabstrueLoad each trap/monster prefab once while the dropship is still descending, so the drop itself does not stutter.
CleanupOnShipLeavetrueWhen the ship takes off (lever pulled or midnight auto-leave), remove the delivery's traps, monsters and any of its items still outside. Items aboard or carried are kept; a delivered Cruiser is never touched.
The allow/block lists — AllowedItems/BlockedItems, AllowedTraps/BlockedTraps, AllowedMonsters/BlockedMonsters — live in the ItemFilters, Traps and Monsters sections. A non-empty Allowed* list acts as a whitelist; otherwise the matching Blocked* list applies.

COMPATIBILITY

  • Automatically includes items other mods add to the terminal shop (reads Terminal.buyableItemsList).
  • In-game configuration via LethalConfig (auto-detected, optional — no hard dependency).
  • Uses the game's own dropship and vanilla networked spawns — no custom network objects, low conflict risk.
  • Works on vanilla and modded moons; if a moon has no dropship, the delivery falls back to spawning on the pad next to the ship.
  • Works on the Company moon (71-Gordion) too, where the delivery is dispatched right after landing (its day never reaches a morning clock time).

BUILD

dotnet build -c Release

Output: bin/Release/RandomDelivery.dll. Game assemblies are referenced via the LethalCompany.GameLibs.Steam NuGet package as compile-only (PrivateAssets="all") — no game files are distributed.

CREDITS

  • Solo00n — author.
  • Built on BepInEx and HarmonyX.
  • Licensed under MIT.

RANDOM DELIVERY

Автор: Solo00n

Каждое утро грузовой дропшип прилетает и сбрасывает на посадочную площадку бесплатную партию случайных предметов из магазина — вот только часть из них прибывает в виде живых ловушек или враждебных монстров.

ЧТО ДЕЛАЕТ МОД

  • Ежедневная доставка — настоящий грузовой дропшип отправляется по расписанию, садится у корабля и сбрасывает партию из 2–4 случайных покупаемых предметов, бесплатно (баланс не меняется).
  • Автопул предметов — берёт все заказываемые предметы из терминала, включая добавленные другими модами; улучшения корабля исключены.
  • Режимы выбора — Random (равный шанс) или PriceWeighted (чем дешевле, тем вероятнее, с бонусом за скидку).
  • Ловушки и монстры — любой слот может стать живой ловушкой (Турель / Мина) или маленьким монстром, которые высыпаются в точках выгрузки дропшипа при открытии люка.
  • Режимы всей доставки — шанс один раз за доставку, что вся партия будет только из ловушек либо только из монстров.
  • Белые / чёрные списки — для предметов, ловушек и монстров: вы точно решаете, что может прибыть.
  • Гибкое расписание — время(-на) отправки по внутриигровым часам, несколько доставок в день, пошаговые шансы замены.
  • Зачистка при взлёте — в момент, когда корабль улетает с планеты, всё, что оставил доставщик (его ловушки, монстры и предметы, оставшиеся лежать снаружи), удаляется; занесённый на корабль лут остаётся.
  • Настройка в игре — все параметры меняются вживую через LethalConfig.

КАК ЭТО РАБОТАЕТ

  • Предметы едут на ванильном ItemDropship: выбранные индексы добавляются в Terminal.orderedItemsFromTerminal (тот же список, что и у платного заказа, но без списания кредитов), поэтому корабль прилетает, садится и сбрасывает их туда же, куда падают заказы из терминала.
  • Спуск начинается в заданное время DeliveryTimes, а ловушки/монстры спавнятся в точках выгрузки дропшипа в момент открытия люка — так всё прибывает вместе и в одном месте.
  • Монстры спавнятся через RoundManager.SpawnEnemyGameObject, ловушки — через NetworkObject.Spawn, без своих сетевых объектов.
  • Пул монстров строится из всех загруженных EnemyType с фильтром по белому списку, поэтому любой разрешённый мелкий монстр может появиться на любой луне.

МУЛЬТИПЛЕЕР (HOST-AUTHORITATIVE)

Доставки генерирует и отправляет только хост; клиенты ничего не генерируют сами, поэтому у всех одна авторитетная доставка.

Предметы: добавляются в заказ терминала на хосте и доставляются дропшипом самой игры, что реплицируется всем клиентам.
Ловушки и монстры: спавнятся на сервере через NetworkObject.Spawn / SpawnEnemyGameObject, поэтому итог одинаков у всех.
Установка: мод обязателен у хоста; клиенты получают всё через Netcode. Ставьте всем, чтобы у всего лобби был общий конфиг.

ЗАВИСИМОСТИ

  • BepInEx 5.4.21+ (BepInEx-BepInExPack-5.4.2100)
  • Lethal Company V81
  • Опционально: LethalConfig для настройки в игре.

УСТАНОВКА

  • Через менеджер (r2modman / Thunderstore Mod Manager): найти мод и нажать Install.
  • Вручную: установить BepInEx-пак, затем положить RandomDelivery.dll в BepInEx/plugins/.

НАСТРОЙКА

Файл: BepInEx/config/Timofey.RandomDelivery.cfg (создаётся при первом запуске). .cfg перечитывается в начале каждого дня и правится вживую в меню LethalConfig.

КлючПо умолчаниюОписание
EnabledtrueГлавный выключатель мода.
DeliveryTimes08:30Список времён отправки дропшипа через запятую (день начинается в 06:00). Каждое — время ЧЧ:ММ, StartOfDay или число секунд после посадки. Перечислите несколько для нескольких доставок.
MaxDeliveriesPerDay1Жёсткий лимит доставок в день.
MinItems / MaxItems2 / 4Слотов за доставку (включительно).
ItemSelectionModeRandomRandom или PriceWeighted.
PriceWeightFactor1.0Крутизна весов по цене (0 = ровно, 1 = обратно цене, 2 = сильный уклон в дешёвые).
DiscountBoosttrueБонус к шансу товаров со скидкой в режиме PriceWeighted.
DropshipAutoOpenfalseОткрывать люк автоматически при посадке, не дожидаясь игрока.
ChanceForTrap / ChanceForMonster15 / 10Пошаговый шанс (%) сделать слот ловушкой / монстром.
PriorityMonsterКто побеждает, если в один слот выпали и ловушка, и монстр.
ChanceForAllTraps / ChanceForAllMonsters0 / 0Шанс один раз за доставку, что вся партия — только ловушки / только монстры.
ChanceForVehicle0Шанс один раз за доставку, что дропшип привезёт бесплатный Cruiser вместо предметов; после этого остальные доставки за день отменяются.
BypassMonstersGordionLimittrueЕсли установлен MonstersGordion — помечать доставленных на 71-Gordion монстров как «своих» для него, чтобы его зачистка их не удаляла.
SpawnStaggerSeconds0.2Пауза между спавном каждой ловушки/монстра, чтобы партия не появлялась разом за один кадр.
PrewarmSpawnPrefabstrueПрогружать префабы ловушек/монстров, пока дропшип ещё летит, чтобы сам сброс не подвисал.
CleanupOnShipLeavetrueПри взлёте корабля (рычаг или автоотлёт в полночь) удалять ловушки, монстров и предметы доставки, оставшиеся снаружи. Предметы на корабле или в руках остаются; доставленный Cruiser не трогается.
Белые/чёрные списки — AllowedItems/BlockedItems, AllowedTraps/BlockedTraps, AllowedMonsters/BlockedMonsters — находятся в разделах ItemFilters, Traps и Monsters. Непустой список Allowed* работает как белый список; иначе применяется соответствующий Blocked*.

СОВМЕСТИМОСТЬ

  • Автоматически включает предметы, добавленные другими модами в магазин терминала (читает Terminal.buyableItemsList).
  • Настройка в игре через LethalConfig (определяется автоматически, необязателен — жёсткой зависимости нет).
  • Использует дропшип самой игры и ванильные сетевые спавны — без своих сетевых объектов, низкий риск конфликтов.
  • Работает на ванильных и модовых лунах; если на луне нет дропшипа, доставка запасным путём спавнится на площадке у корабля.
  • Работает и на луне Компании (71-Gordion): там доставка отправляется сразу после посадки (её день не доходит до утреннего времени).

СБОРКА

dotnet build -c Release

Результат: bin/Release/RandomDelivery.dll. Сборки игры подключены через NuGet-пакет LethalCompany.GameLibs.Steam только для компиляции (PrivateAssets="all") — файлы игры не распространяются.

БЛАГОДАРНОСТИ

  • Solo00n — автор.
  • Построено на BepInEx и HarmonyX.
  • Лицензия MIT.

CHANGELOG

Changelog

1.5.5

  • New Cleanup / CleanupOnShipLeave (default on): the moment the ship leaves the planet — the start lever is pulled, or it leaves by itself at midnight — everything the delivery left behind is removed: its traps, its monsters, and any of its items still lying outside. Items that were brought aboard, are carried by a player, sit in a belt bag that is aboard, or are loaded in the Cruiser are kept; a delivered Cruiser itself is never touched. Removals are spread one per frame, so take-off never hitches.

1.5.4

  • Further reduced the spawn-time hitch. Two causes remained after 1.5.3: the first Instantiate of a given prefab loads all of its assets right then, and spawning on back-to-back frames stacked those costs into one visible freeze.
    • PrewarmSpawnPrefabs (default on): each trap/monster prefab is built once, inert, while the dropship is still descending, so the expensive first-time load happens during the flight rather than at the drop.
    • SpawnStaggerSeconds (default 0.2): spawns are spaced out instead of landing on consecutive frames, so the game recovers between them.

1.5.3

  • Performance: traps/monsters are now deployed one per frame instead of a whole batch in a single frame, which was the spawn-time stutter. The direct (no-dropship) fallback spawns are staggered the same way.
  • Performance: the turret/landmine prefabs and the loaded-enemy catalog are scanned once and cached, so each delivery no longer re-runs Resources.FindObjectsOfTypeAll<EnemyType>() or full prefab scans.

1.5.2

  • New Integration / BypassMonstersGordionLimit (default on): when the MonstersGordion mod is installed, monsters we deliver on the Company moon (71-Gordion) are registered into its owned-enemy list, so its ForeignEnemies cleanup no longer despawns them (and they get its AI fix-ups that make monsters work there). Soft reflection — a no-op when MonstersGordion is absent.

1.5.1

  • A Cruiser is never delivered when the players already have one (spawned, ordered, in the dropship, or being delivered) — in that case the delivery falls back to a normal random one instead.

1.5.0

  • New ChanceForVehicle (in [Replacements]): a delivery can bring a free Cruiser via the dropship instead of the item batch. Rolled first; because the dropship carries a vehicle OR items, once a Cruiser arrives the rest of that day's deliveries are cancelled.
  • Deliveries now work on the Company moon (71-Gordion): its day is too short to reach a morning clock time, so there the delivery is dispatched right after landing, every visit. Traps and monsters can be delivered there too, through the normal path.

1.4.5

  • Removed the mine auto-detonation feature entirely (MinesAutoDetonate / MineWarningTime config and all related code, including the grabbable-landmine compat). Landmines are now delivered as plain live traps that detonate when something steps on them, like any facility mine.

1.4.4

  • Fixed the real reason delivered mines never detonated: the arm/detonate coroutine wrote the private Landmine.mineActivated field, which throws a runtime FieldAccessException (the publicized game-libs only expose it at compile time) and silently killed the whole coroutine. The field already defaults to true, so the write was removed. Mines now beep and detonate right after the dropship opens.

1.4.3

  • Mine fix: the Landmine component is now found with includeInactive — previously it was missed when it sat on an inactive child, so the arm/detonate coroutine never started and mines just sat there.
  • New ChanceForAllTraps / ChanceForAllMonsters (in [Replacements]): a once-per-delivery roll that makes the entire delivery all traps or all monsters. If both hit, Priority decides.

1.4.2

  • Reverted 1.4.1's auto-open (the dropship stays closed unless DropshipAutoOpen, as intended).
  • Mine fix: the grabbable-landmine conversion is now suppressed for a generous window around our mine's spawn (was too short before), so our mine stays a normal landmine and detonates right after the ship is opened — not only when the ship departs (which was the converted grabbable mine going off on collision exit). Added detection/spawn/arm diagnostics to the log.

1.4.1

  • Deliveries that carry traps/monsters now auto-open the dropship on arrival so those "burst out" and their mine countdowns start right when it opens and drops the items — instead of waiting for a player to open the (possibly empty-looking) ship, which previously left mines going off only as it departed. Item-only deliveries still respect DropshipAutoOpen. Added land/open/deploy stage logging.

1.4.0

  • Simplified config: removed DeliverItemsViaDropship (the dropship is now always used, with an automatic direct-spawn fallback only if a moon has no dropship), DeliveryInterval (list times in DeliveryTimes instead), and DropshipArrivalTime (the dropship is dispatched at the DeliveryTimes time). DeliveryTimes now defaults to 08:30, so the dropship lands in the morning by default.
  • Mines now detonate even under a BrutalCompany "grabbable landmines" event: the conversion flag is turned off just around our own mine's spawn, so only our mine stays a normal, detonating landmine.
  • Fixed the Backwater Gunkfish alias (its internal name is "Stingray"). Added a one-time log of every loaded enemy name to make monster names easy to verify.

1.3.3

  • Monster pool is now built from all loaded monster assets (filtered by the allow/block lists) instead of only the current moon's enemy list, so every allowed monster can be delivered on any moon and the random pick actually varies. Added monster-pool and per-spawn logging.

1.3.2

  • Dropship descent is now gated to a configurable in-game clock time (DropshipArrivalTime, default 08:30 → lands ~08:45) using the game's own clock, so it no longer arrives at day-start.
  • Mines are skipped when a BrutalCompany-style "grabbable landmines" event is active (that event converts them into pick-ups so they never auto-detonate); added mine arm/detonate logging.

1.3.1

  • Force the dropship to arrive even for pure trap/monster deliveries; fixed direct-fallback navmesh positioning.

1.3.0

  • Dropship now uses vanilla timing — it no longer arrives instantly; it starts its landing run and touches down on the normal schedule (~8:30 / ~8:45), like a real order placed in orbit / on landing.
  • Traps and monsters now drop at the dropship's own item-drop spots when the hatch opens, so they arrive together with the items in the same place (instead of spawning separately around the ship).
  • Dropship stays closed by default like the original; DropshipAutoOpen (default false) makes it open by itself. Traps/monsters appear once the hatch is opened (by a player or by auto-open).
  • Fixed the trap pool being empty on moons that don't list turrets/mines (now scanned across all moons).

1.2.0

  • Items are now delivered by the game's real item dropship: it flies in, lands next to the ship and drops the items like a normal terminal order (still free). Implemented by queueing the chosen items onto Terminal.orderedItemsFromTerminal, which bypasses the credit charge.
  • The dropship auto-opens on landing so items drop without a player interacting (DropshipAutoOpen).
  • New options: DeliverItemsViaDropship (set false to make items appear directly on the pad instead) and DropshipAutoOpen.
  • Traps and monsters still spawn directly on the pad, now snapped to the walkable navmesh (fixes items landing on invisible AI line-of-sight colliders / floating off the pad).

1.1.0

  • Config moved from a JSON file to a standard BepInEx .cfg (BepInEx/config/Timofey.RandomDelivery.cfg), so it is now editable in-game via LethalConfig (auto-detected — no dependency required) with sliders, check-boxes and drop-downs, applied live.
  • Removed the Newtonsoft.Json dependency.
  • .cfg is re-read at the start of each day for external hand edits.

1.0.0

  • Initial release for Lethal Company v81.
  • Daily (or repeated) deliveries of 2-4 random buyable shop items onto the ship's landing pad.
  • Auto-picks up items added by other mods (reads Terminal.buyableItemsList); excludes ship upgrades.
  • Random and PriceWeighted item selection modes, with optional discount boost.
  • Per-slot chance to replace an item with a Turret/Landmine trap or a small monster (Manticoil, Roaming/Red Locust, Hoarding Bug, Gunkfish, Slime, Tulip Snake, Maneater).
  • Allow/block lists for items, traps and monsters.
  • Flexible JSON config (BepInEx/config/RandomDelivery.json), re-read at the start of every day.
  • Host-authoritative: only the host generates; results replicate to clients via Unity Netcode.
  • Verbose BepInEx logging of every delivery.