removed unused processesseessess
This commit is contained in:
parent
348f355eb2
commit
4fdc567e08
158 changed files with 1317 additions and 3351 deletions
|
|
@ -1,17 +1,9 @@
|
|||
"use strict";
|
||||
|
||||
// Layer: entity-runtime/items/growth-system
|
||||
// Owns passive grass normalization and zunchi lifecycle stage ticking. The
|
||||
// lifecycle step is kept as a pipeline adapter only.
|
||||
// Owns zunchi lifecycle stage ticking. Grass growth is handled by
|
||||
// simulation_item_ant_system.js via sparse random stage advances.
|
||||
(function (global) {
|
||||
function updateGrass(item) {
|
||||
if (!item || item.dead || item.type !== "grass") return false;
|
||||
// Grass is intentionally not simulated per item. World.update randomly
|
||||
// advances one grass by one discrete stage every few seconds.
|
||||
normalizeGrassStage(item);
|
||||
return true;
|
||||
}
|
||||
|
||||
function updateZunchiLifecycle(item, dt, worldRef) {
|
||||
if (!item || item.dead || item.type !== "zunchi") return false;
|
||||
item.lifecycleTimer += dt;
|
||||
|
|
@ -19,20 +11,15 @@
|
|||
if (item.lifecycleTimer < interval) return false;
|
||||
const lifecycleDt = Math.min(item.lifecycleTimer, 2.4);
|
||||
item.lifecycleTimer = 0;
|
||||
global.TarinaiItemDynamicZunchiSystem?.updateLifecycle(item, lifecycleDt, worldRef);
|
||||
global.TarinaiItemDynamicZunchiSystem.updateLifecycle(item, lifecycleDt, worldRef);
|
||||
return true;
|
||||
}
|
||||
|
||||
function update(item, dt, worldRef) {
|
||||
if (!item || item.dead) return { done: true };
|
||||
if (item.type === "grass") updateGrass(item);
|
||||
else if (item.type === "zunchi") updateZunchiLifecycle(item, dt, worldRef);
|
||||
if (item.type === "zunchi") updateZunchiLifecycle(item, dt, worldRef);
|
||||
return { done: false };
|
||||
}
|
||||
|
||||
global.TarinaiItemGrowthSystem = Object.freeze({
|
||||
updateGrass,
|
||||
updateZunchiLifecycle,
|
||||
update,
|
||||
});
|
||||
global.TarinaiItemGrowthSystem = Object.freeze({ update });
|
||||
})(typeof window !== "undefined" ? window : globalThis);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue