

Offline No Spoil
Preserves perishable food in offline inventories and configured containers.
Description
Recommended: Download version 1.6.1-pre.3.
中文玩家文档:https://vscn.studio/docs/offlinenospoil
<span style="color: #e03e2d;">This mod is not intended to be actively maintained. I will only update it when serious issues arise for players on Chinese servers. If you need more frequent updates and maintenance, you can consider using another similar mod instead.</span>
<span style="color: #169179;">Recommended mods: No Offline Container Food Spoil、No offline food spoil</span>
<span style="color: #e03e2d;">Starting with version 1.4.1, the mod is now a Universal mod (client + server), fixing an issue where clients generated a large number of “OfflineNoSpoil behavior not found” warnings when joining a server.</span>
<span style="color: #e03e2d;">Version 1.4.0 remains a server-side-only mod with the same functionality.</span>
The author is currently busy with studies, graduation, and the anxiety surrounding future employment — an important stage of life that requires a significant amount of time and energy. Because of this, it is simply not practical to manually write a complete tutorial for every feature. These mods also provide no direct financial benefit; they are mainly developed to improve the experience of servers and players.
If you have any questions about the documentation or features, or if you encounter a bug, feel free to @mention me in the comments. I will try to respond as soon as possible and fix confirmed issues.
Due to limited time and resources, issues affecting Chinese servers and serious bugs will be given priority. Thank you for your understanding and support.
Configuration generator with an ECharts spoilage timeline and editable JSON loading.
1. How protection is decided
A container must first be eligible
The mod handles a container only when all of the following are true:
EnabledandProtectPlacedContainersare bothtrue.- The block code matches at least one entry in
ContainerBlockCodePatterns. - The container does not trigger a slot, work, policy, or claim-lookup safety fallback. While work is merely queued or deferred, its live spoilage multiplier still follows the current state.
Otherwise the game uses normal spoilage rules from Vanilla or other mods. Offline No Spoil changes only spoilage; drying, curing, ripening, melting, hardening, and machine processing are unaffected.
Player hotbar and backpack
By default, only hotbar and backpack inventories are handled. After a player disconnects, the mod records in-game calendar time. When that player fully joins again, non-empty slots are processed in batches. A PlayerInventorySpoilMultiplier of 0 skips all offline spoilage, 0.5 skips half, and 1 uses normal spoilage. Set MaxPlayerPerishHours to cap actual perish time per login; for example, 168 allows at most seven in-game days of actual spoilage. Nested food in an item's contents attribute is also processed recursively. Separate slot and nested-work budgets prevent complex items from consuming one server tick.
The task captures item references at login, so items acquired or replaced afterward never inherit an older offline interval. If the server restarts before that inventory task finishes, those in-memory references cannot be verified safely; the unfinished interval falls back to normal spoilage. Later offline sessions are still recorded and protected normally. With ShowOfflineNoSpoilInfo enabled, player food tooltips append a fixed short block:
Offline No Spoil Offline spoilage rate: 20% Actual cap: 7d</pre> Container categories and subjects
<table style="border-collapse: collapse; width: 100%;" border="1"> <thead> <tr> <th style="padding: 6px 8px; text-align: left;">Container location</th> <th style="padding: 6px 8px; text-align: left;">Protection subject</th> <th style="padding: 6px 8px; text-align: left;">Switch</th> <th style="padding: 6px 8px; text-align: left;">Default</th> </tr> </thead> <tbody> <tr> <td style="padding: 6px 8px; vertical-align: top;">One unambiguous private land claim</td>Ratings & reviews
Sign in to leave a rating or comment.

