Code Documentation
;; CONSIDERATIONS for future implementation...
;;-----------------------------------------------
;; Ailments increase with advanced Age
;; - use Age (in relation to life expectancy) as modified/amplifier for any erosions on Energy, Stamina, Health-Temp, Health-Base
;; - model Agent States, Variable Levels, Events that convert Variable Levels into States
;; Vital Levels: Health-Base, Health-Temp, Energy, Stamina, Illness, Attention, Stress, Fear, Anger, Sadness, Pain, Pleasure, Sedentary,
;; Events
;; States (defined via Vital Level variable and thresholds, interpreted and triggered by corresponding Events)
;;
;; Architectural Approach: separate the events, from the Level update logic, from the consequences (state transitions, and their impact on Vital Levels) - make it modular and logic tractable
;; .... balance Logic Chain in one place, vs. all Change Logic centrally accessible
;;
;; NUTRITION CYCLE - Make Food-Intake dependent on eating trigger (hungry threshold, social eating, bored eating, frustration/stress eating, sugar/alcohol dependency)
;; Change from current push-food at fixed intervals, to pull-food, whenever agent feels like (conditions/triggers see above)
;;
;; Introduce concept of "VELOCITY" / Rate of Change / Flow-Rate in the dynamics of Vitals vs. Events (a throttle in terms of frequency & probability)
Globals [
LifeSpan-Min
LifeSpan-Max
StartHealth-Min
StartHealth-Max
threshold-Sleep
threshold-Hunger
threshold-Trauma
threshold-Injury
threshold-Obese
threshold-Starving
threshold-IllnessPeople-own[
;; Parameters...
LifeSpan
Age
Name-First
Name-Last
;; AGENT Individual Operational Properties - affected by either EVENTs or other Parameters (aggregates)
;; Distinguish categories: Physical, Emotional, Cognitive, Social - inhibitory or amplifying modifiers
Health-Base
Health-Temp
Stamina-Level ;; can be exerted by too much prolongued effort (recover by rest)
Energy-Level ;; nurtured by food, 0=empty stomach, 100=saturated, > 100 overweight, < 0 starving
Metabolism-Rate ;; defines how long food lasts in relation to Energy Level impact
;; Attention-Level ;; limited attention budget based on level of busy and stress
;; Stress-Level ;; Level expressed between 0-100% ... caused by sustained Fear, Anger, Sadness, Disgust
;; Fear-Level ;; Level expressed between 0-100% ... caused by THREAT Events
;;Anger-Level ;; Level expressed between 0-100% ... caused by
;; Sadness-Level ;; Level expressed between 0-100% ... caused by LOSS Events
;; Greed-Level ;; Level expressed between 0-100% ... caused by
;; Pain-Level ;; Level expressed between 0-100% ... caused by Injury, Sickness, Traumatic Experience (EVENT)
;; Pleasure-Level ;; Level expressed between 0-100% ... physical, positive Experience
;; Illness-Level ;; aggregate illness, from e.g. infection, bad nutrition/life style
Sedentary-Level ;; lack of movement, leading to overweight/diabetes, health impact -- PHYSICAL trait
Lethargy-Level ;; depression, lack of motivation -- EMOTIONAL trait
;; These are fairly static pre-dispositions (genetic, or childhood/life-time conditioned)
Mental-Strength ;; determination in goal-pursuit, problem-solving -> Curiosity, Memory, Thinking Efficiency, Intelligence
Physical-Strength ;; moderates ACTIVITY impact on STAMINA-Level
Emotional-Strength ;; Resilience against Adversity, Self-soothing ability, Emotional Pain Tolerance
;; Agent STATES.... BOOL (0 or 1 - derived from corresponding LEVELs and THRESHOLDs)
Obese-State ;; interpreted as "is this agent currently OBESE?" (so it can be counted by Monitor/Reporter
Starving-State ;;
Illness-State ;;
Joy ;; Level expressed between 0-100% ... emotional, positive Experience
;; Event Counters.... (events come with magnitude, which influences the related Level)
Nutrition-Counter
Injury-Counter
Trauma-Counter
Pleasure-Counter
Accident-Counter
Adversity-Counter ;; rejection, failure events