Fixed mice behavior of eating everything (#23322)
* Added precondition for EatTask * Added Thirsty precondition for htn drink task * Added start state for hungry and thirsty components * Update nutrition.yml * Fixed pascalcase's
This commit is contained in:
@@ -1305,7 +1305,17 @@
|
||||
Dead:
|
||||
Base: splat-0
|
||||
- type: Food
|
||||
- type: Thirst
|
||||
startingThirst: 25 # spawn with Okay thirst state
|
||||
thresholds:
|
||||
OverHydrated: 35
|
||||
Okay: 25
|
||||
Thirsty: 15
|
||||
Parched: 10
|
||||
Dead: 0
|
||||
baseDecayRate: 0.04
|
||||
- type: Hunger
|
||||
currentHunger: 25 # spawn with Okay hunger state
|
||||
thresholds:
|
||||
Overfed: 35
|
||||
Okay: 25
|
||||
|
||||
@@ -4,6 +4,9 @@
|
||||
# Picks a nearby food, moves into range, then eats it and waits the idle time.
|
||||
- tasks:
|
||||
- !type:HTNPrimitiveTask
|
||||
preconditions:
|
||||
- !type:HungryPrecondition
|
||||
minHungerState: Starving # See HungerThreshold enum
|
||||
operator: !type:UtilityOperator
|
||||
proto: NearbyFood
|
||||
|
||||
@@ -31,6 +34,9 @@
|
||||
# Picks nearby drink then consumes it and waits idle time
|
||||
- tasks:
|
||||
- !type:HTNPrimitiveTask
|
||||
preconditions:
|
||||
- !type:ThirstyPrecondition
|
||||
minThirstState: Parched # See ThirstThreshold enum
|
||||
operator: !type:UtilityOperator
|
||||
proto: NearbyDrink
|
||||
|
||||
|
||||
Reference in New Issue
Block a user