refactor(packages): 0.R5 - the shop's week is rolled by its tick and asking reads it; needs start filled and vehicles start with their list; character, physics, vehicles and nativeecho's lazy starts are defaults; --tighten over all four
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
67d8079c47
commit
87259f989d
31 changed files with 104 additions and 111 deletions
|
|
@ -1,10 +1,10 @@
|
|||
# run.ludic - `gh` game hours of whatever the body is doing, taken out of the four bars
|
||||
function nd_add(needs_st: mut NeedsState, k: int, d: float) -> void {
|
||||
function nd_add(needs_st: NeedsState, k: int, d: float) -> void {
|
||||
let lv = nd_lv(needs_st)
|
||||
lv[k] = Math.clamp(lv[k] + d, 0.0, 100.0)
|
||||
}
|
||||
|
||||
export function needs_run(needs_st: mut NeedsState, gh: float) -> void {
|
||||
export function needs_run(needs_st: NeedsState, gh: float) -> void {
|
||||
let a = NeedsWorld.activity()
|
||||
nd_add(needs_st, NEED_FOOD, (NeedsWorld.bonus(NEED_FOOD) - nd_food_rate(a) * NeedsWorld.drain(NEED_FOOD)) * gh)
|
||||
if NeedsWorld.thirst() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue