/**
 * Health and Habits Management System
 * Handles health conditions, weight management, death mechanics, and habit tracking
 * Ported from Python health/health_manager.py
 */
import { Person } from '../../models/Person.js';
import { Player } from '../../models/Player.js';
export type WeightType = 'Underweight' | 'Normal' | 'Overweight' | 'Obese';
export type HabitType = 'positive' | 'negative';
export type HabitStatus = 'active' | 'quitting';
export interface HealthCondition {
    id: string;
    title: string;
    healthModifier: number;
    averageDuration: number;
    date: string | null;
    description: string;
    image?: string;
    isCured?: boolean;
}
export interface Habit {
    name: string;
    description: string;
    type: 'habit';
    habitType: HabitType;
    status: HabitStatus;
    quitProgress: number;
}
/**
 * Determine weight category based on weight value
 */
export declare function getWeightType(weight: number): WeightType;
/**
 * Enforce weight boundaries (0-100)
 */
export declare function handleWeight(person: Person): void;
/**
 * Update person's health based on weight type and health conditions
 */
export declare function handleHealth(player: Player, person: Person): void;
/**
 * Handle player character death event
 * Sets controller to inactive and queues the death message
 */
export declare function handleDeath(player: Player): void;
/**
 * Calculate death chance based on age and health.
 * This follows the Python implementation:
 * - Base death chance increases with age brackets
 * - Final chance is divided by health (lower health = higher death chance)
 *
 * Death probabilities per tick (called once per day in-game):
 * - Age 20-30: 0.000001 / health
 * - Age 30-40: 0.000002 / health
 * - Age 40-50: 0.000003 / health
 * - Age 50-60: 0.000004 / health
 * - Age 60-70: 0.000005 / health
 * - Age 70-82: 0.000006 / health (noticeable increase)
 * - Age 82-100: 0.0002 / health (significant increase)
 * - Age 100+: 0.0012 / health (high probability)
 *
 * @param person - Person object with age and health attributes
 * @returns Updated death chance value
 */
export declare function updateDeathChance(person: Person): number;
/**
 * Check if a person should die based on their death chance.
 * Called once per in-game day for each character.
 *
 * @param person - Person to check
 * @returns true if the person dies, false otherwise
 */
export declare function checkDeath(person: Person): boolean;
/**
 * Result of a death check for a relationship person
 */
export interface RelationshipDeathResult {
    person: Person;
    index: number;
    message: string;
}
/**
 * Check death for all relationship persons (family members, friends, etc.)
 * Updates their death chance on birthday and checks if they die.
 * Matches Python's updateAge() behavior for relationships.
 *
 * @param player - Player object with relationships array
 * @returns Array of death results for any characters that died
 */
export declare function checkRelationshipDeaths(player: Player): RelationshipDeathResult[];
/**
 * Update age for all relationship characters and check for deaths.
 * This should be called once per in-game day (like Python's updateAge).
 *
 * @param player - Player object
 * @returns Array of death messages for any characters that died
 */
export declare function updateRelationshipAges(player: Player): string[];
/**
 * Get the title for a relationship person based on their relationships array.
 * Used for death messages and other notifications.
 *
 * @param person - The relationship person
 * @returns Title string (e.g., "mother", "father", "grandmother") or empty string
 */
export declare function getRelationshipTitle(person: Person): string;
/**
 * Enforce hunger and thirst boundaries (minimum 0)
 */
export declare function handleHunger(person: Person): Person;
/**
 * Process meal event, reducing hunger and thirst
 */
export declare function mealEvent(player: Player): Player;
/**
 * Create a new health condition
 */
export declare function createHealthCondition(id: string, title: string, healthModifier: number, averageDuration: number, description: string, image?: string): HealthCondition;
/**
 * Get list of all available health conditions
 */
export declare function getHealthConditions(): HealthCondition[];
/**
 * Apply a health condition to a person
 */
export declare function applyHealthCondition(player: Player, person: Person, conditionId: string): void;
/**
 * Create a habit
 */
export declare function createHabit(name: string, description: string, habitType?: HabitType): Habit;
/**
 * Negative habit definitions
 */
export declare const negativeHabits: Record<string, Habit>;
/**
 * Positive habit definitions
 */
export declare const positiveHabits: Record<string, Habit>;
/**
 * Initialize habits for a person based on age
 */
export declare function setHabits(person: Person): Person;
/**
 * Start the process of quitting a habit
 * Sets the habit status to 'quitting' and recalculates peak energy
 * (quitting habits cost +5 energy per day while quitting)
 *
 * @param player - Player object with character and message queue
 * @param habitName - Name of the habit to quit (e.g., 'smoking', 'overeating')
 * @returns true if the habit was found and set to quitting, false otherwise
 */
export declare function quitHabit(player: Player, habitName: string): boolean;
/**
 * Stop trying to quit a habit and reset progress
 * Reverts the habit status to 'active' and resets quit progress to 0
 * Recalculates peak energy (no longer paying the +5 energy cost for quitting)
 *
 * @param player - Player object with character and message queue
 * @param habitName - Name of the habit to stop quitting
 * @returns true if the habit was found and reset, false otherwise
 */
export declare function stopQuitHabit(player: Player, habitName: string): boolean;
/**
 * Process habit quitting progress. After 30 days, habit is successfully quit.
 * Called once per week (on weekly tick) to increment quit progress.
 *
 * Habit quitting mechanics:
 * - Each week, quitProgress increments by 1 for habits with status 'quitting'
 * - After 30 weeks of quitting, the habit is removed completely
 * - Peak energy is recalculated when a habit is successfully quit
 * - The player is notified when a habit is successfully quit
 *
 * @param player - Player object for message queue
 * @param person - Person object with habits array
 * @returns Number of habits that were successfully quit
 */
export declare function handleHabitChanges(player: Player, person: Person): number;
/**
 * Update player character's biological stats (hunger, thirst, weight)
 */
export declare function updateBio(player: Player): Player;
export declare const healthManager: {
    getWeightType: typeof getWeightType;
    handleWeight: typeof handleWeight;
    handleHealth: typeof handleHealth;
    handleDeath: typeof handleDeath;
    updateDeathChance: typeof updateDeathChance;
    checkDeath: typeof checkDeath;
    checkRelationshipDeaths: typeof checkRelationshipDeaths;
    updateRelationshipAges: typeof updateRelationshipAges;
    getRelationshipTitle: typeof getRelationshipTitle;
    handleHunger: typeof handleHunger;
    mealEvent: typeof mealEvent;
    getHealthConditions: typeof getHealthConditions;
    applyHealthCondition: typeof applyHealthCondition;
    createHealthCondition: typeof createHealthCondition;
    setHabits: typeof setHabits;
    quitHabit: typeof quitHabit;
    stopQuitHabit: typeof stopQuitHabit;
    handleHabitChanges: typeof handleHabitChanges;
    createHabit: typeof createHabit;
    negativeHabits: Record<string, Habit>;
    positiveHabits: Record<string, Habit>;
    updateBio: typeof updateBio;
};
//# sourceMappingURL=health_manager.d.ts.map