← スキル一覧に戻る

decay-upkeep
by Bbeierle12
⭐ 3🍴 0📅 2026年1月9日
SKILL.md
name: decay-upkeep description: Building decay and upkeep systems for survival games. Use when implementing timer-based decay, Tool Cupboard patterns (Rust-style protection radius), resource upkeep costs, or server performance management through automatic cleanup. Balances gameplay and server health.
Decay & Upkeep
Timer-based building decay and resource-based upkeep for survival games.
Quick Start
import { DecayManager } from './scripts/decay-manager.js';
import { UpkeepSystem } from './scripts/upkeep-system.js';
import { ToolCupboard } from './scripts/tool-cupboard.js';
// Decay without protection
const decay = new DecayManager({
mode: 'rust',
decayMultiplier: 1.0
});
decay.addPiece(piece);
decay.tick(deltaTime); // Called every frame/tick
// Tool Cupboard protection
const tc = new ToolCupboard({
radius: 30,
upkeepCost: { wood: 100, stone: 50 }
});
tc.setPosition(position);
tc.depositResources({ wood: 500, stone: 250 });
// Protected pieces won't decay while upkeep is paid
Reference
See references/decay-upkeep-advanced.md for:
- Decay rate formulas by material
- Tool Cupboard mechanics (Rust pattern)
- Upkeep scaling with base size
- Server performance benefits
- Anti-raid delay mechanics
Scripts
scripts/decay-manager.js- Tick-based decay, material rates, damage statesscripts/upkeep-system.js- Resource drain, calculation, UI datascripts/tool-cupboard.js- Protection radius, authorization, resource storagescripts/cleanup-scheduler.js- Server-side cleanup of abandoned structures
Decay Modes
- Rust: Linear decay over 8-24 hours (material dependent), prevented by Tool Cupboard
- ARK: Slower decay (days to weeks), tribe-based protection
- Minecraft: No decay (creative/survival), optional via mods
Design Philosophy
Decay serves dual purposes in survival games: gameplay balance (prevents infinite hoarding) and server performance (removes abandoned bases). The Tool Cupboard pattern elegantly ties both together—players must actively maintain bases, and inactive players' structures automatically clean up.
スコア
総合スコア
50/100
リポジトリの品質指標に基づく評価
✓SKILL.md
SKILL.mdファイルが含まれている
+20
○LICENSE
ライセンスが設定されている
0/10
○説明文
100文字以上の説明がある
0/10
○人気
GitHub Stars 100以上
0/15
○最近の活動
3ヶ月以内に更新がある
0/10
○フォーク
10回以上フォークされている
0/5
✓Issue管理
オープンIssueが50未満
+5
✓言語
プログラミング言語が設定されている
+5
○タグ
1つ以上のタグが設定されている
0/5
レビュー
💬
レビュー機能は近日公開予定です