16 Commits

Author SHA1 Message Date
Curtis Merrill c57bad4075 avoid near and far #define s 2026-11-01 15:19:04 -05:00
dobbry-vechur 0e09347cff NPCs rank sleep spots by comfort, then shade, warmth and distance
- spots rank by the game's own comfort, so beds and hammocks beat chairs and stools
- equal comfort falls back to the sun penalty, then to floor warmth, which rest quality counts for every sleeper
- the nearest spot wins among equal ranks in the free scan around the NPC
2026-10-31 01:34:54 +04:00
dobbry-vechur 07910a5d8c Meals take real time and give way to harm and orders
- a decision that acted keeps its move surplus or debt into the next turn
- dropped meals are never resumed
- a meal or fire cut short by harm or an order hands back to its task
2026-10-25 10:58:47 +04:00
dobbry-vechur 30ddeaa935 Option costs name what holds the NPC and what was checked
- an option names its walk and the stay that holds the NPC at its spot
- an option names what its judgment rests on: assumption, own tile, destination or route
- stay on its own tile and walk with no route have named forms
2026-10-25 10:41:21 +04:00
dobbry-vechur 5f669eb1e7 The warmth need is named temperature regulation
- need, goal, executor, plan use temperature name
- behavior tree nodes, predicates and test goals use the same name
2026-10-25 10:41:21 +04:00
dobbry-vechur e20bd74d70 Only tests set a committed goal directly
- tests commit a goal without ending the old pursuit
- the game commits a goal only through arbitration
2026-10-25 10:41:20 +04:00
dobbry-vechur 0ae825b1e5 Keep the steady noise sleeper short of exhausted naps 2026-10-25 01:28:35 +04:00
dobbry-vechur 127a3e71fc Steady noise holds an NPC's sleep back
- a second noise wake holds sleep back, doubling per wake up to 16 minutes
- hold ends when the noise stops, the NPC moves or its hearing changes
- a sleep goal from before the hold doesn't lie down during it
2026-10-23 18:25:20 +04:00
dobbry-vechur 703084385f A task survives the NPC resting
- a task NPC lying down to rest keeps its task and backlog for afterwards
- stopping task in dialogue drops the one put aside
- a camp mission keeps the task a forage interrupted, not the forage
2026-10-23 18:25:20 +04:00
dobbry-vechur fb4f5cdff2 NPCs that can't fall asleep don't try to sleep
- can_sleep predicate checks CANNOT_SLEEP instead of meth only
- sleep executor, address_needs() and sleep resume in move() skip it too
- a settling NPC gets up when CANNOT_SLEEP appears
2026-10-13 18:58:35 +04:00
dobbry-vechur d3706d849f Followers with a camp don't wander off to camp work while following
- skip camp jobs and worker downtime while walking with the player
2026-10-13 18:58:35 +04:00
dobbry-vechur 13799089de Woken NPCs lie back down where they are; a stalled sleep yields to work
- three wakes in half an hour stall sleep until nothing else is on offer
- a woken NPC lies back down on its own tile, or searches again
- waking an NPC by talk gives an hour awake, not a sleep rule change
- added woken passengers to the NPC trip bench
2026-10-13 18:58:35 +04:00
dobbry-vechur d199493ced NPCs settle into sleep on their own cadence
- lying down rolls every 3 minutes, easier the longer the NPC lies still
- a spot that fails for 30 minutes is skipped; status shows Trying to sleep
- the sleep attempt is saved with the NPC
- sunlit spots score lower than shaded ones
- an NPC at its spot doesn't lie down while danger is near
2026-10-13 18:58:35 +04:00
dobbry-vechur 75925be694 Followers may rest once the leader settles in, and on belted seats
- the accompany floor relaxes to the need's own level as the leader stays in one place
- a belted seat or vehicle bed counts as resting aboard
- embark prefers a belted seat after an assigned one
- embark drops the last-path seat preference
- sleeping under a relaxed floor isn't announced as an override
2026-10-13 18:58:35 +04:00
dobbry-vechur f2c43bea45 Split sleep readiness out of the sleep roll
- moved the comfort, sleepiness and stim terms into sleep_readiness
- can_sleep keeps the throttle and rolls on top of it
2026-10-13 18:58:35 +04:00
dobbry-vechur 38ef247130 Disable NPC Needs leaves NPCs tired, never harmed
- awake sleepiness caps at DEAD_TIRED - 1 instead of TIRED
- sleep deprivation stays at zero without needs
- added no_npc_food_sleepiness_stops_short_of_dead_tired
2026-10-13 18:58:35 +04:00