---@meta
-- Generated by generate_types.lua - DO NOT EDIT MANUALLY

---@class game
---@field active_mods string[]
---@field mod_runtime table<string, any>
---@field mod_storage table<string, any>
---@field on_every_x_hooks table
---@field iuse_functions table
---@field hooks hooks
---@field current_mod string
---@field current_mod_path string
---@field cata_internal table
game = {}

---@class OnCharacterResetStatsParams
---@field character Character
on_character_reset_stats = {}

---@class OnMapgenPostprocessParams
---@field map Map
---@field omt Tripoint
---@field when TimePoint
on_mapgen_postprocess = {}

---@class OnMonDeathParams
---@field mon Monster
---@field killer Character
on_mon_death = {}
--================---- Classes ----================

---@class ActivityTypeId
---@field NULL_ID fun(): ActivityTypeId
---@field implements_int_id fun(): boolean
---@field is_null fun(arg1: ActivityTypeId): boolean
---@field is_valid fun(arg1: ActivityTypeId): boolean
---@field obj fun(arg1: ActivityTypeId): ActivityTypeRaw
---@field str fun(arg1: ActivityTypeId): string
---@field serialize fun(arg1: ActivityTypeId)
---@field deserialize fun(arg1: ActivityTypeId)
---@field __tostring fun(arg1: ActivityTypeId): string
ActivityTypeId = {}
---@return ActivityTypeId
---@overload fun(arg1: ActivityTypeId): ActivityTypeId
---@overload fun(arg1: string): ActivityTypeId
function ActivityTypeId.new() end

---@class Angle
---@field from_arcmin fun(arg1: number): Angle
---@field from_degrees fun(arg1: number): Angle
---@field from_radians fun(arg1: number): Angle
---@field to_arcmin fun(arg1: Angle): number
---@field to_degrees fun(arg1: Angle): number
---@field to_radians fun(arg1: Angle): number
---@field __eq fun(arg1: Angle, arg2: Angle): boolean
---@field __le fun(arg1: Angle, arg2: Angle): boolean
---@field __lt fun(arg1: Angle, arg2: Angle): boolean
Angle = {}
---@return Angle
function Angle.new() end

---@class Avatar : Player, Character, Creature
Avatar = {}
---@return Avatar
function Avatar.new() end

---@class BionicDataId
---@field NULL_ID fun(): BionicDataId
---@field implements_int_id fun(): boolean
---@field is_null fun(arg1: BionicDataId): boolean
---@field is_valid fun(arg1: BionicDataId): boolean
---@field obj fun(arg1: BionicDataId): BionicDataRaw
---@field str fun(arg1: BionicDataId): string
---@field serialize fun(arg1: BionicDataId)
---@field deserialize fun(arg1: BionicDataId)
---@field __tostring fun(arg1: BionicDataId): string
BionicDataId = {}
---@return BionicDataId
---@overload fun(arg1: BionicDataId): BionicDataId
---@overload fun(arg1: string): BionicDataId
function BionicDataId.new() end

---@class BodyPartTypeId
---@field NULL_ID fun(): BodyPartTypeId
---@field implements_int_id fun(): boolean
---@field int_id fun(arg1: BodyPartTypeId): BodyPartTypeIntId
---@field is_null fun(arg1: BodyPartTypeId): boolean
---@field is_valid fun(arg1: BodyPartTypeId): boolean
---@field obj fun(arg1: BodyPartTypeId): BodyPartTypeRaw
---@field str fun(arg1: BodyPartTypeId): string
---@field serialize fun(arg1: BodyPartTypeId)
---@field deserialize fun(arg1: BodyPartTypeId)
---@field __tostring fun(arg1: BodyPartTypeId): string
BodyPartTypeId = {}
---@return BodyPartTypeId
---@overload fun(arg1: BodyPartTypeId): BodyPartTypeId
---@overload fun(arg1: BodyPartTypeIntId): BodyPartTypeId
---@overload fun(arg1: string): BodyPartTypeId
function BodyPartTypeId.new() end

---@class BodyPartTypeIntId
---@field is_valid fun(arg1: BodyPartTypeIntId): boolean
---@field obj fun(arg1: BodyPartTypeIntId): BodyPartTypeRaw
---@field str_id fun(arg1: BodyPartTypeIntId): BodyPartTypeId
---@field __tostring fun(arg1: BodyPartTypeIntId): string
BodyPartTypeIntId = {}
---@return BodyPartTypeIntId
---@overload fun(arg1: BodyPartTypeIntId): BodyPartTypeIntId
---@overload fun(arg1: BodyPartTypeId): BodyPartTypeIntId
function BodyPartTypeIntId.new() end

---@class Character : Creature
---@field cash integer
---@field focus_pool integer
---@field follower_ids CharacterId[]
---@field male boolean
---@field mutation_category_level table<MutationCategoryTraitId, int>
---@field name string
---@field activate_mutation fun(arg1: Character, arg2: MutationBranchId)
---@field add_addiction fun(arg1: Character, arg2: AddictionType, arg3: integer)
---@field add_bionic fun(arg1: Character, arg2: BionicDataId)
---@field addiction_level fun(arg1: Character, arg2: AddictionType): integer
---@field add_item_with_id fun(arg1: Character, arg2: ItypeId, arg3: integer) @Adds an item with the given id and amount
---@field add_morale fun(arg1: Character, arg2: MoraleTypeDataId, arg3: integer, arg4: integer, arg5: TimeDuration, arg6: TimeDuration, arg7: boolean, arg8: ItypeRaw)
---@field age fun(arg1: Character): integer
---@field all_items fun(arg1: Character, arg2: boolean): Item[] @Gets all items
---@field all_items_with_flag fun(arg1: Character, arg2: JsonFlagId, arg3: boolean): Item[] @Gets all items with the given flag
---@field assign_activity fun(arg1: Character, arg2: ActivityTypeId, arg3: integer, arg4: integer, arg5: integer, arg6: string)
---@field base_age fun(arg1: Character): integer
---@field base_height fun(arg1: Character): integer
---@field bionic_armor_bonus fun(arg1: Character, arg2: BodyPartTypeIntId, arg3: DamageType): number
---@field bionics_weight fun(arg1: Character): Mass
---@field blood_loss fun(arg1: Character, arg2: BodyPartTypeIntId): integer
---@field blossoms fun(arg1: Character)
---@field bodypart_exposure fun(arg1: Character): table<BodyPartTypeIntId, double>
---@field bodyweight fun(arg1: Character): Mass
---@field cancel_activity fun(arg1: Character)
---@field can_hear fun(arg1: Character, arg2: Tripoint, arg3: integer): boolean
---@field can_mount fun(arg1: Character, arg2: Monster): boolean
---@field can_pick_volume fun(arg1: Character, arg2: Volume): boolean
---@field can_pick_weight fun(arg1: Character, arg2: Mass, arg3: boolean): boolean
---@field can_run fun(arg1: Character): boolean
---@field can_unwield fun(arg1: Character, arg2: Item): boolean
---@field can_wield fun(arg1: Character, arg2: Item): boolean
---@field check_mount_is_spooked fun(arg1: Character): boolean
---@field check_mount_will_move fun(arg1: Character, arg2: Tripoint): boolean
---@field clear_bionics fun(arg1: Character)
---@field clear_morale fun(arg1: Character)
---@field clear_mutations fun(arg1: Character)
---@field clear_skills fun(arg1: Character)
---@field cough fun(arg1: Character, arg2: boolean, arg3: integer)
---@field crossed_threshold fun(arg1: Character): boolean
---@field deactivate_mutation fun(arg1: Character, arg2: MutationBranchId)
---@field dismount fun(arg1: Character)
---@field expose_to_disease fun(arg1: Character, arg2: DiseaseTypeId)
---@field fall_asleep fun(arg1: Character) | fun(arg1: Character, arg2: TimeDuration)
---@field forced_dismount fun(arg1: Character)
---@field get_all_skills fun(arg1: Character): SkillLevelMap
---@field get_armor_acid fun(arg1: Character, arg2: BodyPartTypeIntId): integer
---@field get_base_traits fun(arg1: Character): MutationBranchId[]
---@field get_bionics fun(arg1: Character): BionicDataId[]
---@field get_dex fun(arg1: Character): integer
---@field get_dex_base fun(arg1: Character): integer
---@field get_dex_bonus fun(arg1: Character): integer
---@field get_faction_id fun(arg1: Character): FactionId
---@field get_fatigue fun(arg1: Character): integer
---@field get_free_bionics_slots fun(arg1: Character, arg2: BodyPartTypeIntId): integer
---@field get_healthy fun(arg1: Character): number
---@field get_healthy_mod fun(arg1: Character): number
---@field get_highest_category fun(arg1: Character): MutationCategoryTraitId
---@field get_hostile_creatures fun(arg1: Character, arg2: integer): Creature[]
---@field getID fun(arg1: Character): CharacterId
---@field get_int fun(arg1: Character): integer
---@field get_int_base fun(arg1: Character): integer
---@field get_int_bonus fun(arg1: Character): integer
---@field get_item_with_id fun(arg1: Character, arg2: ItypeId, arg3: boolean): Item @Gets the first occurrence of an item with the given id
---@field get_kcal_percent fun(arg1: Character): number
---@field get_lowest_hp fun(arg1: Character): integer
---@field get_max_power_level fun(arg1: Character): Energy
---@field get_melee_stamina_cost fun(arg1: Character, arg2: Item): integer
---@field get_morale fun(arg1: Character, arg2: MoraleTypeDataId): integer
---@field get_morale_level fun(arg1: Character): integer
---@field get_movement_mode fun(arg1: Character): CharacterMoveMode
---@field get_mutations fun(arg1: Character, arg2: boolean): MutationBranchId[]
---@field get_painkiller fun(arg1: Character): integer
---@field get_part_encumbrance fun(arg1: Character, arg2: BodyPartTypeId): integer
---@field get_part_temp_btu fun(arg1: Character, arg2: BodyPartTypeIntId): integer @Gets the current temperature of a specific body part (in Body Temperature Units).
---@field get_per fun(arg1: Character): integer
---@field get_per_base fun(arg1: Character): integer
---@field get_per_bonus fun(arg1: Character): integer
---@field get_power_level fun(arg1: Character): Energy
---@field get_rad fun(arg1: Character): integer
---@field get_shout_volume fun(arg1: Character): integer
---@field get_skill_level fun(arg1: Character, arg2: SkillId): integer
---@field get_skill_level_object fun(arg1: Character, arg2: SkillId): SkillLevel
---@field get_sleep_deprivation fun(arg1: Character): integer
---@field get_stamina fun(arg1: Character): integer
---@field get_stamina_max fun(arg1: Character): integer
---@field get_stim fun(arg1: Character): integer
---@field get_stored_kcal fun(arg1: Character): integer
---@field get_str fun(arg1: Character): integer
---@field get_str_base fun(arg1: Character): integer
---@field get_str_bonus fun(arg1: Character): integer
---@field get_temp_btu fun(arg1: Character): table<BodyPartTypeIntId, int> @Gets all bodyparts and their associated temperatures (in Body Temperature Units).
---@field get_thirst fun(arg1: Character): integer
---@field get_time_died fun(arg1: Character): TimePoint
---@field get_total_bionics_slots fun(arg1: Character, arg2: BodyPartTypeIntId): integer
---@field get_used_bionics_slots fun(arg1: Character, arg2: BodyPartTypeIntId): integer
---@field get_visible_creatures fun(arg1: Character, arg2: integer): Creature[]
---@field get_working_arm_count fun(arg1: Character): integer
---@field get_working_leg_count fun(arg1: Character): integer
---@field global_sm_location fun(arg1: Character): Tripoint
---@field global_square_location fun(arg1: Character): Tripoint
---@field has_active_bionic fun(arg1: Character, arg2: BionicDataId): boolean
---@field has_active_mutation fun(arg1: Character, arg2: MutationBranchId): boolean
---@field has_activity fun(arg1: Character, arg2: ActivityTypeId): boolean
---@field has_addiction fun(arg1: Character, arg2: AddictionType): boolean
---@field has_alarm_clock fun(arg1: Character): boolean
---@field has_any_bionic fun(arg1: Character): boolean
---@field has_base_trait fun(arg1: Character, arg2: MutationBranchId): boolean
---@field has_bionic fun(arg1: Character, arg2: BionicDataId): boolean
---@field has_bionics fun(arg1: Character): boolean
---@field has_child_flag fun(arg1: Character, arg2: MutationBranchId): boolean
---@field has_item_with_flag fun(arg1: Character, arg2: JsonFlagId, arg3: boolean): boolean @Checks for an item with the given flag
---@field has_item_with_id fun(arg1: Character, arg2: ItypeId, arg3: boolean): boolean @Checks for an item with the given id
---@field has_mabuff fun(arg1: Character, arg2: MartialArtsBuffId): boolean
---@field has_max_power fun(arg1: Character): boolean
---@field has_morale fun(arg1: Character, arg2: MoraleTypeDataId): boolean
---@field has_morale_to_craft fun(arg1: Character): boolean
---@field has_morale_to_read fun(arg1: Character): boolean
---@field has_opposite_trait fun(arg1: Character, arg2: MutationBranchId): boolean
---@field has_power fun(arg1: Character): boolean
---@field has_trait_flag fun(arg1: Character, arg2: JsonTraitFlagId): boolean
---@field has_two_arms fun(arg1: Character): boolean
---@field has_watch fun(arg1: Character): boolean
---@field heal fun(arg1: Character, arg2: BodyPartTypeIntId, arg3: integer)
---@field healall fun(arg1: Character, arg2: integer)
---@field healing_rate fun(arg1: Character, arg2: number): number
---@field healing_rate_medicine fun(arg1: Character, arg2: number, arg3: BodyPartTypeIntId): number
---@field hearing_ability fun(arg1: Character): number
---@field height fun(arg1: Character): integer
---@field hitall fun(arg1: Character, arg2: integer, arg3: integer, arg4: Creature): integer
---@field hurtall fun(arg1: Character, arg2: integer, arg3: Creature, arg4: boolean)
---@field in_climate_control fun(arg1: Character): boolean
---@field inv_remove_item fun(arg1: Character, arg2: Item) @Removes given `Item` from character's inventory. The `Item` must be in the inventory, neither wielded nor worn.
---@field irradiate fun(arg1: Character, arg2: number, arg3: boolean): boolean
---@field is_armed fun(arg1: Character): boolean
---@field is_blind fun(arg1: Character): boolean
---@field is_deaf fun(arg1: Character): boolean
---@field is_hauling fun(arg1: Character): boolean
---@field is_invisible fun(arg1: Character): boolean
---@field is_limb_broken fun(arg1: Character, arg2: BodyPartTypeIntId): boolean
---@field is_limb_disabled fun(arg1: Character, arg2: BodyPartTypeIntId): boolean
---@field is_max_power fun(arg1: Character): boolean
---@field is_mounted fun(arg1: Character): boolean
---@field is_quiet fun(arg1: Character): boolean
---@field is_rad_immune fun(arg1: Character): boolean
---@field is_stealthy fun(arg1: Character): boolean
---@field is_throw_immune fun(arg1: Character): boolean
---@field is_weak_to_water fun(arg1: Character): boolean
---@field is_wearing fun(arg1: Character, arg2: Item): boolean
---@field is_wearing_active_optcloak fun(arg1: Character): boolean
---@field is_wearing_active_power_armor fun(arg1: Character): boolean
---@field is_wearing_helmet fun(arg1: Character): boolean
---@field is_wearing_on_bp fun(arg1: Character, arg2: ItypeId, arg3: BodyPartTypeIntId): boolean
---@field is_wearing_power_armor fun(arg1: Character, arg2: boolean): boolean
---@field is_wielding fun(arg1: Character, arg2: Item): boolean
---@field is_worn fun(arg1: Character, arg2: Item): boolean
---@field item_worn_with_flag fun(arg1: Character, arg2: JsonFlagId, arg3: BodyPartTypeIntId): Item
---@field item_worn_with_id fun(arg1: Character, arg2: ItypeId, arg3: BodyPartTypeIntId): Item
---@field knows_recipe fun(arg1: Character, arg2: RecipeId): boolean
---@field learn_recipe fun(arg1: Character, arg2: RecipeId)
---@field mabuff_armor_bonus fun(arg1: Character, arg2: DamageType): integer
---@field mabuff_arpen_bonus fun(arg1: Character, arg2: DamageType): integer
---@field mabuff_attack_cost_mult fun(arg1: Character): number
---@field mabuff_attack_cost_penalty fun(arg1: Character): integer
---@field mabuff_block_bonus fun(arg1: Character): integer
---@field mabuff_damage_bonus fun(arg1: Character, arg2: DamageType): integer
---@field mabuff_damage_mult fun(arg1: Character, arg2: DamageType): number
---@field mabuff_dodge_bonus fun(arg1: Character): number
---@field mabuff_speed_bonus fun(arg1: Character): integer
---@field mabuff_tohit_bonus fun(arg1: Character): number
---@field max_stored_kcal fun(arg1: Character): integer
---@field metabolic_rate fun(arg1: Character): number
---@field mod_base_age fun(arg1: Character, arg2: integer)
---@field mod_base_height fun(arg1: Character, arg2: integer)
---@field mod_dex_bonus fun(arg1: Character, arg2: integer)
---@field mod_fatigue fun(arg1: Character, arg2: integer)
---@field mod_healthy fun(arg1: Character, arg2: number)
---@field mod_healthy_mod fun(arg1: Character, arg2: number, arg3: number)
---@field mod_int_bonus fun(arg1: Character, arg2: integer)
---@field mod_max_power_level fun(arg1: Character, arg2: Energy)
---@field mod_painkiller fun(arg1: Character, arg2: integer)
---@field mod_per_bonus fun(arg1: Character, arg2: integer)
---@field mod_power_level fun(arg1: Character, arg2: Energy)
---@field mod_rad fun(arg1: Character, arg2: integer)
---@field mod_skill_level fun(arg1: Character, arg2: SkillId, arg3: integer)
---@field mod_sleep_deprivation fun(arg1: Character, arg2: integer)
---@field mod_speed_bonus fun(arg1: Character, arg2: integer)
---@field mod_stamina fun(arg1: Character, arg2: integer)
---@field mod_stim fun(arg1: Character, arg2: integer)
---@field mod_stored_kcal fun(arg1: Character, arg2: integer)
---@field mod_str_bonus fun(arg1: Character, arg2: integer)
---@field mod_thirst fun(arg1: Character, arg2: integer)
---@field mount_creature fun(arg1: Character, arg2: Monster)
---@field mutate fun(arg1: Character)
---@field mutate_category fun(arg1: Character, arg2: MutationCategoryTraitId)
---@field mutate_towards fun(arg1: Character, arg2: MutationBranchId[], arg3: integer): boolean
---@field mutate_towards fun(arg1: Character, arg2: MutationBranchId[], arg3: integer): boolean | fun(arg1: Character, arg2: MutationBranchId): boolean
---@field mutate_towards fun(arg1: Character, arg2: MutationBranchId): boolean
---@field mutation_armor fun(arg1: Character, arg2: BodyPartTypeIntId, arg3: DamageType): number
---@field mutation_effect fun(arg1: Character, arg2: MutationBranchId)
---@field mutation_loss_effect fun(arg1: Character, arg2: MutationBranchId)
---@field mutation_ok fun(arg1: Character, arg2: MutationBranchId, arg3: boolean, arg4: boolean): boolean
---@field mutation_value fun(arg1: Character, arg2: string): number
---@field practice fun(arg1: Character, arg2: SkillId, arg3: integer, arg4: integer, arg5: boolean)
---@field read_speed fun(arg1: Character, arg2: boolean): integer
---@field rem_addiction fun(arg1: Character, arg2: AddictionType)
---@field rem_morale fun(arg1: Character, arg2: MoraleTypeDataId)
---@field remove_bionic fun(arg1: Character, arg2: BionicDataId)
---@field remove_child_flag fun(arg1: Character, arg2: MutationBranchId)
---@field remove_mutation fun(arg1: Character, arg2: MutationBranchId, arg3: boolean)
---@field restore_scent fun(arg1: Character)
---@field rest_quality fun(arg1: Character): number
---@field rooted fun(arg1: Character)
---@field rust_rate fun(arg1: Character): integer
---@field set_base_age fun(arg1: Character, arg2: integer)
---@field set_base_height fun(arg1: Character, arg2: integer)
---@field set_dex_bonus fun(arg1: Character, arg2: integer)
---@field set_faction_id fun(arg1: Character, arg2: FactionId)
---@field set_fatigue fun(arg1: Character, arg2: integer)
---@field set_healthy fun(arg1: Character, arg2: number)
---@field set_healthy_mod fun(arg1: Character, arg2: number)
---@field setID fun(arg1: Character, arg2: CharacterId, arg3: boolean)
---@field set_int_bonus fun(arg1: Character, arg2: integer)
---@field set_max_power_level fun(arg1: Character, arg2: Energy)
---@field set_movement_mode fun(arg1: Character, arg2: CharacterMoveMode)
---@field set_mutation fun(arg1: Character, arg2: MutationBranchId)
---@field set_painkiller fun(arg1: Character, arg2: integer)
---@field set_part_temp_btu fun(arg1: Character, arg2: BodyPartTypeIntId, arg3: integer) @Sets a specific body part to a given temperature (in Body Temperature Units).
---@field set_per_bonus fun(arg1: Character, arg2: integer)
---@field set_power_level fun(arg1: Character, arg2: Energy)
---@field set_rad fun(arg1: Character, arg2: integer)
---@field set_skill_level fun(arg1: Character, arg2: SkillId, arg3: integer)
---@field set_sleep_deprivation fun(arg1: Character, arg2: integer)
---@field set_speed_bonus fun(arg1: Character, arg2: integer)
---@field set_stamina fun(arg1: Character, arg2: integer)
---@field set_stim fun(arg1: Character, arg2: integer)
---@field set_stored_kcal fun(arg1: Character, arg2: integer)
---@field set_str_bonus fun(arg1: Character, arg2: integer)
---@field set_temp_btu fun(arg1: Character, arg2: integer) @Sets ALL body parts on a creature to the given temperature (in Body Temperature Units).
---@field set_thirst fun(arg1: Character, arg2: integer)
---@field shout fun(arg1: Character, arg2: string, arg3: boolean)
---@field sight_impaired fun(arg1: Character): boolean
---@field spores fun(arg1: Character)
---@field suffer fun(arg1: Character)
---@field uncanny_dodge fun(arg1: Character): boolean
---@field unset_mutation fun(arg1: Character, arg2: MutationBranchId)
---@field unwield fun(arg1: Character): boolean
---@field volume_capacity fun(arg1: Character): Volume
---@field volume_carried fun(arg1: Character): Volume
---@field vomit fun(arg1: Character)
---@field wake_up fun(arg1: Character)
---@field wearing_something_on fun(arg1: Character, arg2: BodyPartTypeIntId): boolean
---@field weight_carried fun(arg1: Character): Mass
---@field wield fun(arg1: Character, arg2: Item): boolean
---@field worn_with_flag fun(arg1: Character, arg2: JsonFlagId, arg3: BodyPartTypeIntId): boolean
---@field worn_with_id fun(arg1: Character, arg2: ItypeId, arg3: BodyPartTypeIntId): boolean
Character = {}
---@return Character
function Character.new() end

---@class CharacterId
---@field get_value fun(arg1: CharacterId): integer
---@field is_valid fun(arg1: CharacterId): boolean
CharacterId = {}
---@return CharacterId
---@overload fun(arg1: integer): CharacterId
function CharacterId.new() end

---@class Creature
---@field add_effect fun(arg1: Creature, arg2: EffectTypeId, arg3: TimeDuration, arg4: BodyPartTypeId?, arg5: int?) @Effect type, duration, bodypart and intensity
---@field apply_damage fun(arg1: Creature, arg2: Creature, arg3: BodyPartTypeIntId, arg4: integer, arg5: boolean)
---@field as_avatar fun(arg1: Creature): Avatar
---@field as_character fun(arg1: Creature): Character
---@field as_monster fun(arg1: Creature): Monster
---@field as_npc fun(arg1: Creature): Npc
---@field attitude_to fun(arg1: Creature, arg2: Creature): Attitude
---@field clear_effects fun(arg1: Creature)
---@field deal_damage fun(arg1: Creature, arg2: Creature, arg3: BodyPartTypeIntId, arg4: DamageInstance): DealtDamageInstance
---@field digging fun(arg1: Creature): boolean
---@field disp_name fun(arg1: Creature, arg2: boolean, arg3: boolean): string
---@field dodge_roll fun(arg1: Creature): number
---@field get_armor_bash fun(arg1: Creature, arg2: BodyPartTypeIntId): integer
---@field get_armor_bash_base fun(arg1: Creature, arg2: BodyPartTypeIntId): integer
---@field get_armor_bash_bonus fun(arg1: Creature): integer
---@field get_armor_bullet fun(arg1: Creature, arg2: BodyPartTypeIntId): integer
---@field get_armor_bullet_base fun(arg1: Creature, arg2: BodyPartTypeIntId): integer
---@field get_armor_bullet_bonus fun(arg1: Creature): integer
---@field get_armor_cut fun(arg1: Creature, arg2: BodyPartTypeIntId): integer
---@field get_armor_cut_base fun(arg1: Creature, arg2: BodyPartTypeIntId): integer
---@field get_armor_cut_bonus fun(arg1: Creature): integer
---@field get_armor_type fun(arg1: Creature, arg2: DamageType, arg3: BodyPartTypeIntId): integer
---@field get_block_bonus fun(arg1: Creature): integer
---@field get_dodge fun(arg1: Creature): number
---@field get_dodge_base fun(arg1: Creature): number
---@field get_dodge_bonus fun(arg1: Creature): number
---@field get_effect_dur fun(arg1: Creature, arg2: EffectTypeId, arg3: BodyPartTypeId?): TimeDuration
---@field get_effect_int fun(arg1: Creature, arg2: EffectTypeId, arg3: BodyPartTypeId?): integer
---@field get_env_resist fun(arg1: Creature, arg2: BodyPartTypeIntId): integer
---@field get_grammatical_genders fun(arg1: Creature): string[]
---@field get_hit fun(arg1: Creature): number
---@field get_hit_base fun(arg1: Creature): number
---@field get_hit_bonus fun(arg1: Creature): number
---@field get_hp fun(arg1: Creature, arg2: BodyPartTypeIntId?): integer
---@field get_hp_max fun(arg1: Creature, arg2: BodyPartTypeIntId?): integer
---@field get_melee fun(arg1: Creature): number
---@field get_moves fun(arg1: Creature): integer
---@field get_name fun(arg1: Creature): string
---@field get_num_blocks fun(arg1: Creature): integer
---@field get_num_dodges fun(arg1: Creature): integer
---@field get_pain fun(arg1: Creature): integer
---@field get_part_healed_total fun(arg1: Creature, arg2: BodyPartTypeIntId): integer
---@field get_part_hp_cur fun(arg1: Creature, arg2: BodyPartTypeIntId): integer
---@field get_part_hp_max fun(arg1: Creature, arg2: BodyPartTypeIntId): integer
---@field get_perceived_pain fun(arg1: Creature): integer
---@field get_pos_ms fun(arg1: Creature): Tripoint
---@field get_size fun(arg1: Creature): MonsterSize
---@field get_speed fun(arg1: Creature): integer
---@field get_speed_base fun(arg1: Creature): integer
---@field get_speed_bonus fun(arg1: Creature): integer
---@field get_speed_mult fun(arg1: Creature): number
---@field get_value fun(arg1: Creature, arg2: string): string
---@field get_weight fun(arg1: Creature): Mass
---@field get_weight_capacity fun(arg1: Creature): integer
---@field has_effect fun(arg1: Creature, arg2: EffectTypeId, arg3: BodyPartTypeId?): boolean
---@field has_effect_with_flag fun(arg1: Creature, arg2: JsonFlagId, arg3: BodyPartTypeId?): boolean
---@field has_flag fun(arg1: Creature, arg2: MonsterFlag): boolean
---@field has_grab_break_tec fun(arg1: Creature): boolean
---@field has_trait fun(arg1: Creature, arg2: MutationBranchId): boolean
---@field has_weapon fun(arg1: Creature): boolean
---@field hp_percentage fun(arg1: Creature): integer
---@field in_species fun(arg1: Creature, arg2: SpeciesTypeId): boolean
---@field is_avatar fun(arg1: Creature): boolean
---@field is_dead fun(arg1: Creature): boolean
---@field is_elec_immune fun(arg1: Creature): boolean
---@field is_hallucination fun(arg1: Creature): boolean
---@field is_immune_damage fun(arg1: Creature, arg2: DamageType): boolean
---@field is_immune_effect fun(arg1: Creature, arg2: EffectTypeId): boolean
---@field is_monster fun(arg1: Creature): boolean
---@field is_npc fun(arg1: Creature): boolean
---@field is_on_ground fun(arg1: Creature): boolean
---@field is_underwater fun(arg1: Creature): boolean
---@field is_warm fun(arg1: Creature): boolean
---@field knock_back_to fun(arg1: Creature, arg2: Tripoint)
---@field mod_moves fun(arg1: Creature, arg2: integer)
---@field mod_pain fun(arg1: Creature, arg2: integer)
---@field mod_pain_noresist fun(arg1: Creature, arg2: integer)
---@field mod_part_hp_cur fun(arg1: Creature, arg2: BodyPartTypeIntId, arg3: integer)
---@field mod_part_hp_max fun(arg1: Creature, arg2: BodyPartTypeIntId, arg3: integer)
---@field power_rating fun(arg1: Creature): number
---@field ranged_target_size fun(arg1: Creature): number
---@field remove_effect fun(arg1: Creature, arg2: EffectTypeId, arg3: BodyPartTypeId?): boolean
---@field remove_value fun(arg1: Creature, arg2: string)
---@field sees fun(arg1: Creature, arg2: Creature): boolean
---@field set_all_parts_hp_cur fun(arg1: Creature, arg2: integer)
---@field set_all_parts_hp_to_max fun(arg1: Creature)
---@field set_moves fun(arg1: Creature, arg2: integer)
---@field set_pain fun(arg1: Creature, arg2: integer)
---@field set_part_hp_cur fun(arg1: Creature, arg2: BodyPartTypeIntId, arg3: integer)
---@field set_part_hp_max fun(arg1: Creature, arg2: BodyPartTypeIntId, arg3: integer)
---@field set_pos_ms fun(arg1: Creature, arg2: Tripoint)
---@field set_underwater fun(arg1: Creature, arg2: boolean)
---@field set_value fun(arg1: Creature, arg2: string, arg3: string)
---@field sight_range fun(arg1: Creature, arg2: integer): integer
---@field size_melee_penalty fun(arg1: Creature): integer
---@field skin_name fun(arg1: Creature): string
---@field speed_rating fun(arg1: Creature): number
---@field stability_roll fun(arg1: Creature): number
Creature = {}
---@return Creature
function Creature.new() end

--- new(damageType, amount, armorPen, remainingArmorMultiplier, damageMultiplier)
---@class DamageInstance
---@field damage_units DamageUnit[]
---@field add fun(arg1: DamageInstance, arg2: DamageUnit)
---@field add_damage fun(arg1: DamageInstance, arg2: DamageType, arg3: number, arg4: number, arg5: number, arg6: number)
---@field clear fun(arg1: DamageInstance)
---@field empty fun(arg1: DamageInstance): boolean
---@field mult_damage fun(arg1: DamageInstance, arg2: number, arg3: boolean)
---@field total_damage fun(arg1: DamageInstance): number
---@field type_damage fun(arg1: DamageInstance, arg2: DamageType): number
---@field __eq fun(arg1: DamageInstance, arg2: DamageInstance): boolean
DamageInstance = {}
---@return DamageInstance
---@overload fun(arg1: DamageType, arg2: number, arg3: number, arg4: number, arg5: number): DamageInstance
function DamageInstance.new() end

--- new(damageType, amount, armorPen, remainingArmorMultiplier, damageMultiplier)
---@class DamageUnit
---@field amount number
---@field damage_multiplier number
---@field res_mult number
---@field res_pen number
---@field type DamageType
---@field __eq fun(arg1: DamageUnit, arg2: DamageUnit): boolean
DamageUnit = {}
---@return DamageUnit
---@overload fun(arg1: DamageType, arg2: number, arg3: number, arg4: number, arg5: number): DamageUnit
function DamageUnit.new() end

--- Represents the final dealt damage
---@class DealtDamageInstance
---@field bp_hit BodyPartTypeId
---@field dealt_dams int[]
---@field total_damage fun(arg1: DealtDamageInstance): integer
---@field type_damage fun(arg1: DealtDamageInstance, arg2: DamageType): integer
DealtDamageInstance = {}
---@return DealtDamageInstance
function DealtDamageInstance.new() end

---@class DiseaseTypeId
---@field NULL_ID fun(): DiseaseTypeId
---@field implements_int_id fun(): boolean
---@field is_null fun(arg1: DiseaseTypeId): boolean
---@field is_valid fun(arg1: DiseaseTypeId): boolean
---@field obj fun(arg1: DiseaseTypeId): DiseaseTypeRaw
---@field str fun(arg1: DiseaseTypeId): string
---@field serialize fun(arg1: DiseaseTypeId)
---@field deserialize fun(arg1: DiseaseTypeId)
---@field __tostring fun(arg1: DiseaseTypeId): string
DiseaseTypeId = {}
---@return DiseaseTypeId
---@overload fun(arg1: DiseaseTypeId): DiseaseTypeId
---@overload fun(arg1: string): DiseaseTypeId
function DiseaseTypeId.new() end

---@class DistributionGrid
---@field get_resource fun(arg1: DistributionGrid, arg2: boolean): integer @Boolean argument controls recursive behavior
---@field mod_resource fun(arg1: DistributionGrid, arg2: integer, arg3: boolean): integer @Boolean argument controls recursive behavior
DistributionGrid = {}
---@return DistributionGrid
function DistributionGrid.new() end

---@class DistributionGridTracker
---@field get_grid_at_abs_ms fun(arg1: DistributionGridTracker, arg2: Tripoint): DistributionGrid
DistributionGridTracker = {}
---@return DistributionGridTracker
function DistributionGridTracker.new() end

---@class EffectTypeId
---@field NULL_ID fun(): EffectTypeId
---@field implements_int_id fun(): boolean
---@field is_null fun(arg1: EffectTypeId): boolean
---@field is_valid fun(arg1: EffectTypeId): boolean
---@field obj fun(arg1: EffectTypeId): EffectTypeRaw
---@field str fun(arg1: EffectTypeId): string
---@field serialize fun(arg1: EffectTypeId)
---@field deserialize fun(arg1: EffectTypeId)
---@field __tostring fun(arg1: EffectTypeId): string
EffectTypeId = {}
---@return EffectTypeId
---@overload fun(arg1: EffectTypeId): EffectTypeId
---@overload fun(arg1: string): EffectTypeId
function EffectTypeId.new() end

---@class Energy
---@field from_joule fun(arg1: integer): Energy
---@field from_kilojoule fun(arg1: integer): Energy
---@field to_joule fun(arg1: Energy): integer
---@field to_kilojoule fun(arg1: Energy): integer
---@field __eq fun(arg1: Energy, arg2: Energy): boolean
---@field __le fun(arg1: Energy, arg2: Energy): boolean
---@field __lt fun(arg1: Energy, arg2: Energy): boolean
Energy = {}
---@return Energy
function Energy.new() end

---@class FactionId
---@field NULL_ID fun(): FactionId
---@field implements_int_id fun(): boolean
---@field is_null fun(arg1: FactionId): boolean
---@field is_valid fun(arg1: FactionId): boolean
---@field obj fun(arg1: FactionId): FactionRaw
---@field str fun(arg1: FactionId): string
---@field serialize fun(arg1: FactionId)
---@field deserialize fun(arg1: FactionId)
---@field __tostring fun(arg1: FactionId): string
FactionId = {}
---@return FactionId
---@overload fun(arg1: FactionId): FactionId
---@overload fun(arg1: string): FactionId
function FactionId.new() end

---@class FactionRaw
---@field str_id fun(arg1: FactionRaw): FactionId
FactionRaw = {}
---@return FactionRaw
function FactionRaw.new() end

---@class FieldTypeId
---@field NULL_ID fun(): FieldTypeId
---@field implements_int_id fun(): boolean
---@field int_id fun(arg1: FieldTypeId): FieldTypeIntId
---@field is_null fun(arg1: FieldTypeId): boolean
---@field is_valid fun(arg1: FieldTypeId): boolean
---@field obj fun(arg1: FieldTypeId): FieldTypeRaw
---@field str fun(arg1: FieldTypeId): string
---@field serialize fun(arg1: FieldTypeId)
---@field deserialize fun(arg1: FieldTypeId)
---@field __tostring fun(arg1: FieldTypeId): string
FieldTypeId = {}
---@return FieldTypeId
---@overload fun(arg1: FieldTypeId): FieldTypeId
---@overload fun(arg1: FieldTypeIntId): FieldTypeId
---@overload fun(arg1: string): FieldTypeId
function FieldTypeId.new() end

---@class FieldTypeIntId
---@field is_valid fun(arg1: FieldTypeIntId): boolean
---@field obj fun(arg1: FieldTypeIntId): FieldTypeRaw
---@field str_id fun(arg1: FieldTypeIntId): FieldTypeId
---@field __tostring fun(arg1: FieldTypeIntId): string
FieldTypeIntId = {}
---@return FieldTypeIntId
---@overload fun(arg1: FieldTypeIntId): FieldTypeIntId
---@overload fun(arg1: FieldTypeId): FieldTypeIntId
function FieldTypeIntId.new() end

---@class FurnId
---@field NULL_ID fun(): FurnId
---@field implements_int_id fun(): boolean
---@field int_id fun(arg1: FurnId): FurnIntId
---@field is_null fun(arg1: FurnId): boolean
---@field is_valid fun(arg1: FurnId): boolean
---@field obj fun(arg1: FurnId): FurnRaw
---@field str fun(arg1: FurnId): string
---@field serialize fun(arg1: FurnId)
---@field deserialize fun(arg1: FurnId)
---@field __tostring fun(arg1: FurnId): string
FurnId = {}
---@return FurnId
---@overload fun(arg1: FurnId): FurnId
---@overload fun(arg1: FurnIntId): FurnId
---@overload fun(arg1: string): FurnId
function FurnId.new() end

---@class FurnIntId
---@field is_valid fun(arg1: FurnIntId): boolean
---@field obj fun(arg1: FurnIntId): FurnRaw
---@field str_id fun(arg1: FurnIntId): FurnId
---@field __tostring fun(arg1: FurnIntId): string
FurnIntId = {}
---@return FurnIntId
---@overload fun(arg1: FurnIntId): FurnIntId
---@overload fun(arg1: FurnId): FurnIntId
function FurnIntId.new() end

---@class FurnRaw
---@field close FurnId
---@field open FurnId
---@field transforms_into FurnId
---@field get_coverage fun(arg1: FurnRaw): integer
---@field get_flags fun(arg1: FurnRaw): any
---@field get_light_emitted fun(arg1: FurnRaw): integer
---@field get_max_volume fun(arg1: FurnRaw): Volume
---@field get_movecost fun(arg1: FurnRaw): integer
---@field has_flag fun(arg1: FurnRaw, arg2: string): boolean
---@field int_id fun(arg1: FurnRaw): FurnIntId
---@field name fun(arg1: FurnRaw): string
---@field set_coverage fun(arg1: FurnRaw, arg2: integer)
---@field set_flag fun(arg1: FurnRaw, arg2: string)
---@field set_light_emitted fun(arg1: FurnRaw, arg2: integer)
---@field set_max_volume fun(arg1: FurnRaw, arg2: Volume)
---@field set_movecost fun(arg1: FurnRaw, arg2: integer)
---@field str_id fun(arg1: FurnRaw): FurnId
FurnRaw = {}
---@return FurnRaw
function FurnRaw.new() end

---@class Item
---@field charges integer
---@field activate fun(arg1: Item)
---@field add_item_with_id fun(arg1: Item, arg2: ItypeId, arg3: integer) @Adds an item(s) to contents
---@field add_technique fun(arg1: Item, arg2: MartialArtsTechniqueId) @Adds the technique. It isn't treated original, but additional.
---@field ammo_capacity fun(arg1: Item, arg2: boolean): integer @Gets the maximum capacity of a magazine
---@field ammo_consume fun(arg1: Item, arg2: integer, arg3: Tripoint): integer
---@field ammo_current fun(arg1: Item): ItypeId
---@field ammo_data fun(arg1: Item): ItypeRaw
---@field ammo_remaining fun(arg1: Item): integer @Get remaining ammo, works with batteries & stuff too
---@field ammo_required fun(arg1: Item): integer
---@field ammo_set fun(arg1: Item, arg2: ItypeId, arg3: integer)
---@field ammo_unset fun(arg1: Item)
---@field attack_cost fun(arg1: Item): integer
---@field can_contain fun(arg1: Item, arg2: Item): boolean @Checks if this item can contain another
---@field clear_vars fun(arg1: Item) @Erase all variables
---@field conductive fun(arg1: Item): boolean
---@field convert fun(arg1: Item, arg2: ItypeId) @Converts the item as given `ItypeId`.
---@field covers fun(arg1: Item, arg2: BodyPartTypeIntId): boolean @Checks if the item covers a bodypart
---@field current_magazine fun(arg1: Item): Item @Gets the current magazine
---@field deactivate fun(arg1: Item)
---@field display_name fun(arg1: Item, arg2: integer): string @Display name with all bells and whistles like ammo and prefixes
---@field energy_remaining fun(arg1: Item): Energy
---@field erase_var fun(arg1: Item, arg2: string) @Erase variable
---@field get_category_id fun(arg1: Item): string @Gets the category id this item is in
---@field get_comestible_fun fun(arg1: Item): integer
---@field get_kcal fun(arg1: Item): integer
---@field get_mtype fun(arg1: Item): MtypeId @Almost for a corpse.
---@field get_owner fun(arg1: Item): FactionId @Gets the faction id that owns this item
---@field get_owner_name fun(arg1: Item): string
---@field get_quench fun(arg1: Item): integer
---@field get_reload_time fun(arg1: Item): integer
---@field get_rot fun(arg1: Item): TimeDuration @Gets the TimeDuration until this item rots
---@field get_techniques fun(arg1: Item): MartialArtsTechniqueId[] @Gets all techniques. Including original techniques.
---@field get_type fun(arg1: Item): ItypeId
---@field get_var_num fun(arg1: Item, arg2: string, arg3: number): number @Get variable as float number
---@field get_var_str fun(arg1: Item, arg2: string, arg3: string): string @Get variable as string
---@field get_var_tri fun(arg1: Item, arg2: string, arg3: Tripoint): Tripoint @Get variable as tripoint
---@field has_flag fun(arg1: Item, arg2: JsonFlagId): boolean
---@field has_infinite_charges fun(arg1: Item): boolean
---@field has_item_with_id fun(arg1: Item, arg2: ItypeId): boolean @Checks item contents for a given item id
---@field has_own_flag fun(arg1: Item, arg2: JsonFlagId): boolean
---@field has_technique fun(arg1: Item, arg2: MartialArtsTechniqueId): boolean @Checks if this item has the technique as an addition. Doesn't check original techniques.
---@field has_var fun(arg1: Item, arg2: string): boolean @Check for variable of any type
---@field is_active fun(arg1: Item): boolean
---@field is_ammo fun(arg1: Item): boolean
---@field is_ammo_belt fun(arg1: Item): boolean
---@field is_ammo_container fun(arg1: Item): boolean
---@field is_armor fun(arg1: Item): boolean
---@field is_artifact fun(arg1: Item): boolean
---@field is_bandolier fun(arg1: Item): boolean
---@field is_battery fun(arg1: Item): boolean @DEPRECATED: Is this a battery? (spoiler: it isn't)
---@field is_bionic fun(arg1: Item): boolean
---@field is_book fun(arg1: Item): boolean
---@field is_brewable fun(arg1: Item): boolean
---@field is_bucket fun(arg1: Item): boolean
---@field is_bucket_nonempty fun(arg1: Item): boolean
---@field is_comestible fun(arg1: Item): boolean
---@field is_container fun(arg1: Item): boolean
---@field is_container_empty fun(arg1: Item): boolean
---@field is_corpse fun(arg1: Item): boolean
---@field is_craft fun(arg1: Item): boolean
---@field is_dangerous fun(arg1: Item): boolean
---@field is_deployable fun(arg1: Item): boolean
---@field is_emissive fun(arg1: Item): boolean
---@field is_engine fun(arg1: Item): boolean
---@field is_faulty fun(arg1: Item): boolean
---@field is_filthy fun(): boolean @DEPRECATED: Items are no longer filthy
---@field is_firearm fun(arg1: Item): boolean
---@field is_food fun(arg1: Item): boolean
---@field is_food_container fun(arg1: Item): boolean
---@field is_fuel fun(arg1: Item): boolean
---@field is_gun fun(arg1: Item): boolean
---@field is_gunmod fun(arg1: Item): boolean
---@field is_holster fun(arg1: Item): boolean
---@field is_irremovable fun(arg1: Item): boolean
---@field is_made_of fun(arg1: Item, arg2: MaterialTypeId): boolean
---@field is_magazine fun(arg1: Item): boolean @Is this a magazine? (batteries are magazines)
---@field is_map fun(arg1: Item): boolean
---@field is_med_container fun(arg1: Item): boolean
---@field is_medication fun(arg1: Item): boolean
---@field is_melee fun(arg1: Item, arg2: DamageType): boolean @Is this item an effective melee weapon for the given damage type?
---@field is_money fun(arg1: Item): boolean
---@field is_non_resealable_container fun(arg1: Item): boolean
---@field is_null fun(arg1: Item): boolean
---@field is_owned_by fun(arg1: Item, arg2: Character, arg3: boolean): boolean @Checks if this item owned by a character
---@field is_power_armor fun(arg1: Item): boolean
---@field is_relic fun(arg1: Item): boolean
---@field is_reloadable fun(arg1: Item): boolean
---@field is_salvageable fun(arg1: Item, arg2: boolean): boolean
---@field is_seed fun(arg1: Item): boolean
---@field is_sided fun(arg1: Item): boolean
---@field is_silent fun(arg1: Item): boolean
---@field is_soft fun(arg1: Item): boolean
---@field is_stackable fun(arg1: Item): boolean
---@field is_tainted fun(arg1: Item): boolean
---@field is_tool fun(arg1: Item): boolean
---@field is_toolmod fun(arg1: Item): boolean
---@field is_transformable fun(arg1: Item): boolean
---@field is_unarmed_weapon fun(arg1: Item): boolean
---@field is_upgrade fun(arg1: Item): boolean
---@field is_watertight_container fun(arg1: Item): boolean
---@field is_wheel fun(arg1: Item): boolean
---@field made_of fun(arg1: Item): any
---@field mod_charges fun(arg1: Item, arg2: integer)
---@field price fun(arg1: Item, arg2: boolean): number @Cents of the item. `bool` is whether it is a post-cataclysm value.
---@field remaining_capacity_for_id fun(arg1: Item, arg2: ItypeId, arg3: boolean): integer @Gets the remaining space available for a type of liquid
---@field remove_technique fun(arg1: Item, arg2: MartialArtsTechniqueId) @Removes the additional technique. Doesn't affect originial techniques.
---@field set_flag fun(arg1: Item, arg2: JsonFlagId)
---@field set_flag_recursive fun(arg1: Item, arg2: JsonFlagId)
---@field set_owner fun(arg1: Item, arg2: Character) @Sets the ownership of this item to a character
---@field set_owner fun(arg1: Item, arg2: FactionId) @Sets the ownership of this item to a faction
---@field set_var_num fun(arg1: Item, arg2: string, arg3: number)
---@field set_var_str fun(arg1: Item, arg2: string, arg3: string)
---@field set_var_tri fun(arg1: Item, arg2: string, arg3: Tripoint)
---@field stamina_cost fun(arg1: Item): integer
---@field tname fun(arg1: Item, arg2: integer, arg3: boolean, arg4: integer): string @Translated item name with prefixes
---@field total_capacity fun(arg1: Item): Volume @Gets maximum volume this item can hold (liquids, ammo, etc)
---@field unset_flag fun(arg1: Item, arg2: JsonFlagId)
---@field unset_flags fun(arg1: Item)
---@field volume fun(arg1: Item, arg2: bool?): Volume @Volume of the item. `bool` is whether it is `integral_volume`.
---@field weight fun(arg1: Item, arg2: bool?, arg3: bool?): Mass @Weight of the item. The first `bool` is whether including contents, second `bool` is whether it is `integral_weight`.
Item = {}
---@return Item
function Item.new() end

--- Iterate over this using pairs()
---@class ItemStack
---@field __pairs fun(arg1: ItemStack): any
ItemStack = {}
---@return ItemStack
function ItemStack.new() end

---@class ItypeId
---@field NULL_ID fun(): ItypeId
---@field implements_int_id fun(): boolean
---@field is_null fun(arg1: ItypeId): boolean
---@field is_valid fun(arg1: ItypeId): boolean
---@field obj fun(arg1: ItypeId): ItypeRaw
---@field str fun(arg1: ItypeId): string
---@field serialize fun(arg1: ItypeId)
---@field deserialize fun(arg1: ItypeId)
---@field __tostring fun(arg1: ItypeId): string
ItypeId = {}
---@return ItypeId
---@overload fun(arg1: ItypeId): ItypeId
---@overload fun(arg1: string): ItypeId
function ItypeId.new() end

---@class JsonFlagId
---@field NULL_ID fun(): JsonFlagId
---@field implements_int_id fun(): boolean
---@field is_null fun(arg1: JsonFlagId): boolean
---@field is_valid fun(arg1: JsonFlagId): boolean
---@field obj fun(arg1: JsonFlagId): JsonFlagRaw
---@field str fun(arg1: JsonFlagId): string
---@field serialize fun(arg1: JsonFlagId)
---@field deserialize fun(arg1: JsonFlagId)
---@field __tostring fun(arg1: JsonFlagId): string
JsonFlagId = {}
---@return JsonFlagId
---@overload fun(arg1: JsonFlagId): JsonFlagId
---@overload fun(arg1: string): JsonFlagId
function JsonFlagId.new() end

---@class JsonTraitFlagId
---@field NULL_ID fun(): JsonTraitFlagId
---@field implements_int_id fun(): boolean
---@field is_null fun(arg1: JsonTraitFlagId): boolean
---@field is_valid fun(arg1: JsonTraitFlagId): boolean
---@field obj fun(arg1: JsonTraitFlagId): JsonTraitFlagRaw
---@field str fun(arg1: JsonTraitFlagId): string
---@field serialize fun(arg1: JsonTraitFlagId)
---@field deserialize fun(arg1: JsonTraitFlagId)
---@field __tostring fun(arg1: JsonTraitFlagId): string
JsonTraitFlagId = {}
---@return JsonTraitFlagId
---@overload fun(arg1: JsonTraitFlagId): JsonTraitFlagId
---@overload fun(arg1: string): JsonTraitFlagId
function JsonTraitFlagId.new() end

---@class Map
---@field add_field_at fun(arg1: Map, arg2: Tripoint, arg3: FieldTypeIntId, arg4: integer, arg5: TimeDuration): boolean
---@field clear_items_at fun(arg1: Map, arg2: Tripoint)
---@field create_corpse_at fun(arg1: Map, arg2: Tripoint, arg3: MtypeId?, arg4: TimePoint?, arg5: string?, arg6: int?) @Creates a new corpse at a position on the map. You can skip `Opt` ones by omitting them or passing `nil`. `MtypeId` specifies which monster's body it is, `TimePoint` indicates when it died, `string` gives it a custom name, and `int` determines the revival time if the monster has the `REVIVES` flag.
---@field create_item_at fun(arg1: Map, arg2: Tripoint, arg3: ItypeId, arg4: integer) @Creates a new item(s) at a position on the map.
---@field disarm_trap_at fun(arg1: Map, arg2: Tripoint) @Disarms a trap using your skills and stats, with consequences depending on success or failure.
---@field get_abs_ms fun(arg1: Map, arg2: Tripoint): Tripoint @Convert local ms -> absolute ms
---@field get_field_age_at fun(arg1: Map, arg2: Tripoint, arg3: FieldTypeIntId): TimeDuration
---@field get_field_int_at fun(arg1: Map, arg2: Tripoint, arg3: FieldTypeIntId): integer
---@field get_furn_at fun(arg1: Map, arg2: Tripoint): FurnIntId
---@field get_items_at fun(arg1: Map, arg2: Tripoint): any
---@field get_local_ms fun(arg1: Map, arg2: Tripoint): Tripoint @Convert absolute ms -> local ms
---@field get_map_size fun(arg1: Map): integer @In map squares
---@field get_map_size_in_submaps fun(arg1: Map): integer
---@field get_ter_at fun(arg1: Map, arg2: Tripoint): TerIntId
---@field get_trap_at fun(arg1: Map, arg2: Tripoint): TrapIntId
---@field has_field_at fun(arg1: Map, arg2: Tripoint, arg3: FieldTypeIntId): boolean
---@field has_items_at fun(arg1: Map, arg2: Tripoint): boolean
---@field mod_field_age_at fun(arg1: Map, arg2: Tripoint, arg3: FieldTypeIntId, arg4: TimeDuration): TimeDuration
---@field mod_field_int_at fun(arg1: Map, arg2: Tripoint, arg3: FieldTypeIntId, arg4: integer): integer
---@field remove_field_at fun(arg1: Map, arg2: Tripoint, arg3: FieldTypeIntId)
---@field remove_item_at fun(arg1: Map, arg2: Tripoint, arg3: Item)
---@field remove_trap_at fun(arg1: Map, arg2: Tripoint) @Simpler version of `set_trap_at` with `trap_null`.
---@field set_field_age_at fun(arg1: Map, arg2: Tripoint, arg3: FieldTypeIntId, arg4: TimeDuration, arg5: boolean): TimeDuration
---@field set_field_int_at fun(arg1: Map, arg2: Tripoint, arg3: FieldTypeIntId, arg4: integer, arg5: boolean): integer
---@field set_furn_at fun(arg1: Map, arg2: Tripoint, arg3: FurnIntId)
---@field set_ter_at fun(arg1: Map, arg2: Tripoint, arg3: TerIntId): boolean
---@field set_trap_at fun(arg1: Map, arg2: Tripoint, arg3: TrapIntId) @Set a trap at a position on the map. It can also replace existing trap, even with `trap_null`.
Map = {}
---@return Map
function Map.new() end

---@class MapStack : ItemStack
---@field as_item_stack fun(arg1: MapStack): ItemStack
MapStack = {}
---@return MapStack
function MapStack.new() end

---@class MartialArtsBuffId
---@field NULL_ID fun(): MartialArtsBuffId
---@field implements_int_id fun(): boolean
---@field is_null fun(arg1: MartialArtsBuffId): boolean
---@field is_valid fun(arg1: MartialArtsBuffId): boolean
---@field obj fun(arg1: MartialArtsBuffId): MartialArtsBuffRaw
---@field str fun(arg1: MartialArtsBuffId): string
---@field serialize fun(arg1: MartialArtsBuffId)
---@field deserialize fun(arg1: MartialArtsBuffId)
---@field __tostring fun(arg1: MartialArtsBuffId): string
MartialArtsBuffId = {}
---@return MartialArtsBuffId
---@overload fun(arg1: MartialArtsBuffId): MartialArtsBuffId
---@overload fun(arg1: string): MartialArtsBuffId
function MartialArtsBuffId.new() end

---@class MartialArtsTechniqueId
---@field NULL_ID fun(): MartialArtsTechniqueId
---@field implements_int_id fun(): boolean
---@field is_null fun(arg1: MartialArtsTechniqueId): boolean
---@field is_valid fun(arg1: MartialArtsTechniqueId): boolean
---@field obj fun(arg1: MartialArtsTechniqueId): MartialArtsTechniqueRaw
---@field str fun(arg1: MartialArtsTechniqueId): string
---@field serialize fun(arg1: MartialArtsTechniqueId)
---@field deserialize fun(arg1: MartialArtsTechniqueId)
---@field __tostring fun(arg1: MartialArtsTechniqueId): string
MartialArtsTechniqueId = {}
---@return MartialArtsTechniqueId
---@overload fun(arg1: MartialArtsTechniqueId): MartialArtsTechniqueId
---@overload fun(arg1: string): MartialArtsTechniqueId
function MartialArtsTechniqueId.new() end

---@class Mass
---@field from_gram fun(arg1: integer): Mass
---@field from_kilogram fun(arg1: integer): Mass
---@field from_milligram fun(arg1: integer): Mass
---@field from_newton fun(arg1: integer): Mass
---@field to_gram fun(arg1: Mass): integer
---@field to_kilogram fun(arg1: Mass): integer
---@field to_milligram fun(arg1: Mass): integer
---@field to_newton fun(arg1: Mass): integer
---@field __eq fun(arg1: Mass, arg2: Mass): boolean
---@field __le fun(arg1: Mass, arg2: Mass): boolean
---@field __lt fun(arg1: Mass, arg2: Mass): boolean
Mass = {}
---@return Mass
function Mass.new() end

---@class MaterialTypeId
---@field NULL_ID fun(): MaterialTypeId
---@field implements_int_id fun(): boolean
---@field is_null fun(arg1: MaterialTypeId): boolean
---@field is_valid fun(arg1: MaterialTypeId): boolean
---@field obj fun(arg1: MaterialTypeId): MaterialTypeRaw
---@field str fun(arg1: MaterialTypeId): string
---@field serialize fun(arg1: MaterialTypeId)
---@field deserialize fun(arg1: MaterialTypeId)
---@field __tostring fun(arg1: MaterialTypeId): string
MaterialTypeId = {}
---@return MaterialTypeId
---@overload fun(arg1: MaterialTypeId): MaterialTypeId
---@overload fun(arg1: string): MaterialTypeId
function MaterialTypeId.new() end

---@class MaterialTypeRaw
---@field name fun(arg1: MaterialTypeRaw): string
---@field str_id fun(arg1: MaterialTypeRaw): MaterialTypeId
MaterialTypeRaw = {}
---@return MaterialTypeRaw
function MaterialTypeRaw.new() end

---@class Monster : Creature
---@field anger integer
---@field death_drops boolean
---@field faction MonsterFactionIntId
---@field friendly integer
---@field morale integer
---@field unique_name string
---@field attitude fun(arg1: Monster, arg2: Character): MonsterAttitude
---@field can_climb fun(arg1: Monster): boolean
---@field can_dig fun(arg1: Monster): boolean
---@field can_drown fun(arg1: Monster): boolean
---@field can_hear fun(arg1: Monster): boolean
---@field can_see fun(arg1: Monster): boolean
---@field can_submerge fun(arg1: Monster): boolean
---@field can_upgrade fun(arg1: Monster): boolean
---@field climbs fun(arg1: Monster): boolean
---@field digs fun(arg1: Monster): boolean
---@field flies fun(arg1: Monster): boolean
---@field get_type fun(arg1: Monster): MtypeId
---@field get_upgrade_time fun(arg1: Monster): integer
---@field hasten_upgrade fun(arg1: Monster)
---@field heal fun(arg1: Monster, arg2: integer, arg3: boolean): integer
---@field is_wandering fun(arg1: Monster): boolean
---@field make_ally fun(arg1: Monster, arg2: Monster)
---@field make_friendly fun(arg1: Monster)
---@field make_fungus fun(arg1: Monster): boolean
---@field move_target fun(arg1: Monster): Tripoint
---@field move_to fun(arg1: Monster, arg2: Tripoint, arg3: boolean, arg4: boolean, arg5: number): boolean
---@field name fun(arg1: Monster, arg2: integer): string
---@field name_with_armor fun(arg1: Monster): string
---@field refill_udders fun(arg1: Monster)
---@field set_hp fun(arg1: Monster, arg2: integer)
---@field spawn fun(arg1: Monster, arg2: Tripoint)
---@field swims fun(arg1: Monster): boolean
---@field try_reproduce fun(arg1: Monster)
---@field try_upgrade fun(arg1: Monster, arg2: boolean)
---@field wander_to fun(arg1: Monster, arg2: Tripoint, arg3: integer)
Monster = {}
---@return Monster
function Monster.new() end

---@class MonsterFactionId
---@field NULL_ID fun(): MonsterFactionId
---@field implements_int_id fun(): boolean
---@field int_id fun(arg1: MonsterFactionId): MonsterFactionIntId
---@field is_null fun(arg1: MonsterFactionId): boolean
---@field is_valid fun(arg1: MonsterFactionId): boolean
---@field obj fun(arg1: MonsterFactionId): MonsterFactionRaw
---@field str fun(arg1: MonsterFactionId): string
---@field serialize fun(arg1: MonsterFactionId)
---@field deserialize fun(arg1: MonsterFactionId)
---@field __tostring fun(arg1: MonsterFactionId): string
MonsterFactionId = {}
---@return MonsterFactionId
---@overload fun(arg1: MonsterFactionId): MonsterFactionId
---@overload fun(arg1: MonsterFactionIntId): MonsterFactionId
---@overload fun(arg1: string): MonsterFactionId
function MonsterFactionId.new() end

---@class MonsterFactionIntId
---@field is_valid fun(arg1: MonsterFactionIntId): boolean
---@field obj fun(arg1: MonsterFactionIntId): MonsterFactionRaw
---@field str_id fun(arg1: MonsterFactionIntId): MonsterFactionId
---@field __tostring fun(arg1: MonsterFactionIntId): string
MonsterFactionIntId = {}
---@return MonsterFactionIntId
---@overload fun(arg1: MonsterFactionIntId): MonsterFactionIntId
---@overload fun(arg1: MonsterFactionId): MonsterFactionIntId
function MonsterFactionIntId.new() end

---@class MoraleTypeDataId
---@field NULL_ID fun(): MoraleTypeDataId
---@field implements_int_id fun(): boolean
---@field is_null fun(arg1: MoraleTypeDataId): boolean
---@field is_valid fun(arg1: MoraleTypeDataId): boolean
---@field obj fun(arg1: MoraleTypeDataId): MoraleTypeDataRaw
---@field str fun(arg1: MoraleTypeDataId): string
---@field serialize fun(arg1: MoraleTypeDataId)
---@field deserialize fun(arg1: MoraleTypeDataId)
---@field __tostring fun(arg1: MoraleTypeDataId): string
MoraleTypeDataId = {}
---@return MoraleTypeDataId
---@overload fun(arg1: MoraleTypeDataId): MoraleTypeDataId
---@overload fun(arg1: string): MoraleTypeDataId
function MoraleTypeDataId.new() end

---@class MtypeId
---@field NULL_ID fun(): MtypeId
---@field implements_int_id fun(): boolean
---@field is_null fun(arg1: MtypeId): boolean
---@field is_valid fun(arg1: MtypeId): boolean
---@field obj fun(arg1: MtypeId): MtypeRaw
---@field str fun(arg1: MtypeId): string
---@field serialize fun(arg1: MtypeId)
---@field deserialize fun(arg1: MtypeId)
---@field __tostring fun(arg1: MtypeId): string
MtypeId = {}
---@return MtypeId
---@overload fun(arg1: MtypeId): MtypeId
---@overload fun(arg1: string): MtypeId
function MtypeId.new() end

---@class MutationBranchId
---@field NULL_ID fun(): MutationBranchId
---@field implements_int_id fun(): boolean
---@field is_null fun(arg1: MutationBranchId): boolean
---@field is_valid fun(arg1: MutationBranchId): boolean
---@field obj fun(arg1: MutationBranchId): MutationBranchRaw
---@field str fun(arg1: MutationBranchId): string
---@field serialize fun(arg1: MutationBranchId)
---@field deserialize fun(arg1: MutationBranchId)
---@field __tostring fun(arg1: MutationBranchId): string
MutationBranchId = {}
---@return MutationBranchId
---@overload fun(arg1: MutationBranchId): MutationBranchId
---@overload fun(arg1: string): MutationBranchId
function MutationBranchId.new() end

---@class MutationBranchRaw
---@field activated boolean @Whether this mutation can be activated at will.
---@field allow_soft_gear boolean @Mutation allows soft gear to be worn over otherwise-restricted parts.
---@field attackcost_modifier number
---@field bleed_resist number
---@field bodytemp_max_btu integer
---@field bodytemp_min_btu integer
---@field bodytemp_sleep_btu integer
---@field cooldown integer @Costs are incurred every 'cooldown' turns.
---@field cost integer
---@field debug boolean @Whether or not this mutation is limited to debug use.
---@field dodge_modifier number
---@field falling_damage_multiplier number
---@field fatigue boolean @Mutation causes fatigue when used.
---@field fatigue_modifier number
---@field fatigue_regen_modifier number
---@field healing_awake number @Healing per turn from mutation.
---@field healing_resting number @Healing per turn from mutation, while asleep.
---@field healthy_rate number @How quickly health (not HP) trends toward healthy_mod.
---@field hearing_modifier number
---@field hp_adjustment number @Flat adjustment to HP.
---@field hp_modifier number @Bonus HP multiplier. 1.0 doubles HP; -0.5 halves it.
---@field hp_modifier_secondary number @Secondary HP multiplier; stacks with the other one. 1.0 doubles HP; -0.5 halves it.
---@field hunger boolean @Mutation deducts calories when used.
---@field id MutationBranchId
---@field max_stamina_modifier number
---@field mending_modifier number @Multiplier applied to broken limb regeneration. Normally 0.25; clamped to 0.25..1.0.
---@field metabolism_modifier number
---@field mixed_effect boolean @Whether this mutation has positive /and/ negative effects.
---@field movecost_flatground_modifier number
---@field movecost_modifier number
---@field movecost_obstacle_modifier number
---@field movecost_swim_modifier number
---@field night_vision_range number
---@field noise_modifier number
---@field overmap_multiplier number
---@field overmap_sight number
---@field pain_recovery number @Pain recovery per turn from mutation.
---@field player_display boolean @Whether or not this mutation shows up in the status (`@`) menu.
---@field points integer @Point cost in character creation(?).
---@field profession boolean @Whether this trait is ONLY gained through professional training/experience (and/or quests).
---@field purifiable boolean @Whether this mutation is possible to remove through Purifier. False for 'special' mutations.
---@field reading_speed_multiplier number
---@field scent_modifier number
---@field skill_rust_multiplier number
---@field speed_modifier number
---@field stamina_regen_modifier number
---@field starting_trait boolean @Whether this trait can normally be taken during character generation.
---@field starts_active boolean @Whether a mutation activates when granted.
---@field stealth_modifier number
---@field str_modifier number @Adjustment to Strength that doesn't affect HP.
---@field temperature_speed_modifier number
---@field thirst boolean @Mutation dehydrates when used.
---@field thirst_modifier number
---@field threshold boolean @Whether this is a Threshold mutation, and thus especially difficult to mutate. One per character.
---@field ugliness integer @How physically unappealing the mutation is. Can be negative.
---@field valid boolean @Whether this mutation is available through generic mutagen.
---@field visibility integer @How visible the mutation is to others.
---@field weight_capacity_modifier number
---@field addition_mutations fun(arg1: MutationBranchRaw): MutationBranchId[]
---@field categories fun(arg1: MutationBranchRaw): MutationCategoryTraitId[] @Lists the categories this mutation belongs to.
---@field conflicts_with fun(arg1: MutationBranchRaw): MutationBranchId[] @Lists conflicting mutations.
---@field desc fun(arg1: MutationBranchRaw): string
---@field get_all fun(): any @Returns a (long) list of every mutation in the game.
---@field mutation_types fun(arg1: MutationBranchRaw): string[] @Lists the type(s) of this mutation. Mutations of a given type are mutually exclusive.
---@field name fun(arg1: MutationBranchRaw): string
---@field other_prerequisites fun(arg1: MutationBranchRaw): MutationBranchId[] @Lists the secondary mutation(s) needed to gain this mutation.
---@field prerequisites fun(arg1: MutationBranchRaw): MutationBranchId[] @Lists the primary mutation(s) needed to gain this mutation.
---@field replaced_by fun(arg1: MutationBranchRaw): MutationBranchId[] @Lists mutations that replace (e.g. evolve from) this one.
---@field thresh_requirements fun(arg1: MutationBranchRaw): MutationBranchId[] @Lists the threshold mutation(s) required to gain this mutation.
---@field __tostring fun(arg1: MutationBranchRaw): string
MutationBranchRaw = {}
---@return MutationBranchRaw
function MutationBranchRaw.new() end

---@class MutationCategoryTraitId
---@field NULL_ID fun(): MutationCategoryTraitId
---@field implements_int_id fun(): boolean
---@field is_null fun(arg1: MutationCategoryTraitId): boolean
---@field is_valid fun(arg1: MutationCategoryTraitId): boolean
---@field obj fun(arg1: MutationCategoryTraitId): MutationCategoryTraitRaw
---@field str fun(arg1: MutationCategoryTraitId): string
---@field serialize fun(arg1: MutationCategoryTraitId)
---@field deserialize fun(arg1: MutationCategoryTraitId)
---@field __tostring fun(arg1: MutationCategoryTraitId): string
MutationCategoryTraitId = {}
---@return MutationCategoryTraitId
---@overload fun(arg1: MutationCategoryTraitId): MutationCategoryTraitId
---@overload fun(arg1: string): MutationCategoryTraitId
function MutationCategoryTraitId.new() end

---@class Npc : Player, Character, Creature
---@field current_activity_id ActivityTypeId
---@field hit_by_player boolean
---@field marked_for_death boolean
---@field needs NpcNeed[]
---@field op_of_u NpcOpinion
---@field patience integer
---@field personality NpcPersonality
---@field can_move_to fun(arg1: Npc, arg2: Tripoint, arg3: boolean): boolean
---@field can_open_door fun(arg1: Npc, arg2: Tripoint, arg3: boolean): boolean
---@field complain fun(arg1: Npc): boolean
---@field complain_about fun(arg1: Npc, arg2: string, arg3: TimeDuration, arg4: string, arg5: bool?): boolean
---@field current_ally fun(arg1: Npc): Creature
---@field current_target fun(arg1: Npc): Creature
---@field danger_assessment fun(arg1: Npc): number
---@field evaluate_enemy fun(arg1: Npc, arg2: Creature): number
---@field follow_distance fun(arg1: Npc): integer
---@field get_attitude fun(arg1: Npc): NpcAttitude
---@field get_monster_faction fun(arg1: Npc): MonsterFactionIntId
---@field guaranteed_hostile fun(arg1: Npc): boolean
---@field has_activity fun(arg1: Npc): boolean
---@field has_omt_destination fun(arg1: Npc): boolean
---@field has_player_activity fun(arg1: Npc): boolean
---@field hostile_anger_level fun(arg1: Npc): integer
---@field is_ally fun(arg1: Npc, arg2: Character): boolean
---@field is_enemy fun(arg1: Npc): boolean
---@field is_following fun(arg1: Npc): boolean
---@field is_friendly fun(arg1: Npc, arg2: Character): boolean
---@field is_guarding fun(arg1: Npc): boolean
---@field is_leader fun(arg1: Npc): boolean
---@field is_minion fun(arg1: Npc): boolean
---@field is_obeying fun(arg1: Npc, arg2: Character): boolean
---@field is_patrolling fun(arg1: Npc): boolean
---@field is_player_ally fun(arg1: Npc): boolean
---@field is_stationary fun(arg1: Npc, arg2: boolean): boolean
---@field is_travelling fun(arg1: Npc): boolean
---@field is_walking_with fun(arg1: Npc): boolean
---@field make_angry fun(arg1: Npc)
---@field mutiny fun(arg1: Npc)
---@field saw_player_recently fun(arg1: Npc): boolean
---@field say fun(arg1: Npc, arg2: string)
---@field set_attitude fun(arg1: Npc, arg2: NpcAttitude)
---@field set_faction_id fun(arg1: Npc, arg2: FactionId)
---@field smash_ability fun(arg1: Npc): integer
---@field turned_hostile fun(arg1: Npc): boolean
---@field warn_about fun(arg1: Npc, arg2: string, arg3: TimeDuration, arg4: string, arg5: integer, arg6: Tripoint)
Npc = {}
---@return Npc
function Npc.new() end

---@class NpcOpinion
---@field anger integer
---@field fear integer
---@field owed integer
---@field trust integer
---@field value integer
NpcOpinion = {}
---@return NpcOpinion
---@overload fun(arg1: integer, arg2: integer, arg3: integer, arg4: integer, arg5: integer): NpcOpinion
function NpcOpinion.new() end

---@class NpcPersonality
---@field aggression integer
---@field altruism integer
---@field bravery integer
---@field collector integer
NpcPersonality = {}
---@return NpcPersonality
function NpcPersonality.new() end

---@class Player : Character, Creature
Player = {}
---@return Player
function Player.new() end

---@class Point
---@field x integer
---@field y integer
---@field abs fun(arg1: Point): Point
---@field rotate fun(arg1: Point, arg2: integer, arg3: Point): Point
---@field serialize fun(arg1: Point)
---@field deserialize fun(arg1: Point)
---@field __add fun(arg1: Point, arg2: Point): Point
---@field __div fun(arg1: Point, arg2: integer): Point
---@field __eq fun(arg1: Point, arg2: Point): boolean
---@field __idiv fun(arg1: Point, arg2: integer): Point
---@field __lt fun(arg1: Point, arg2: Point): boolean
---@field __mul fun(arg1: Point, arg2: integer): Point
---@field __sub fun(arg1: Point, arg2: Point): Point
---@field __tostring fun(arg1: Point): string
---@field __unm fun(arg1: Point): Point
Point = {}
---@return Point
---@overload fun(arg1: Point): Point
---@overload fun(arg1: integer, arg2: integer): Point
function Point.new() end

---@class PopupInputStr
---@field desc fun(arg1: PopupInputStr, arg2: string) @`desc` is above input field.
---@field query_int fun(arg1: PopupInputStr): integer @Returns your input, but allows numbers only.
---@field query_str fun(arg1: PopupInputStr): string @Returns your input.
---@field title fun(arg1: PopupInputStr, arg2: string) @`title` is on the left of input field.
PopupInputStr = {}
---@return PopupInputStr
function PopupInputStr.new() end

---@class QueryPopup
---@field allow_any_key fun(arg1: QueryPopup, arg2: boolean) @Set whether to allow any key
---@field message fun(arg1: QueryPopup, arg2: any)
---@field message_color fun(arg1: QueryPopup, arg2: Color)
---@field query fun(arg1: QueryPopup): string @Returns selected action
---@field query_yn fun(arg1: QueryPopup): string @Returns `YES` or `NO`. If ESC pressed, returns `NO`.
---@field query_ynq fun(arg1: QueryPopup): string @Returns `YES`, `NO` or `QUIT`. If ESC pressed, returns `QUIT`.
QueryPopup = {}
---@return QueryPopup
function QueryPopup.new() end

---@class RecipeId
---@field NULL_ID fun(): RecipeId
---@field implements_int_id fun(): boolean
---@field is_null fun(arg1: RecipeId): boolean
---@field is_valid fun(arg1: RecipeId): boolean
---@field obj fun(arg1: RecipeId): RecipeRaw
---@field str fun(arg1: RecipeId): string
---@field serialize fun(arg1: RecipeId)
---@field deserialize fun(arg1: RecipeId)
---@field __tostring fun(arg1: RecipeId): string
RecipeId = {}
---@return RecipeId
---@overload fun(arg1: RecipeId): RecipeId
---@overload fun(arg1: string): RecipeId
function RecipeId.new() end

---@class RecipeRaw
---@field booksets table<ItypeId, int>
---@field category string
---@field difficulty integer
---@field learn_by_disassembly table<SkillId, int>
---@field required_skills table<SkillId, int>
---@field skill_used SkillId
---@field subcategory string
---@field time integer
---@field get_all fun(): RecipeRaw[]
---@field get_from_flag fun(arg1: string): RecipeRaw[]
---@field get_from_skill_used fun(arg1: SkillId): RecipeRaw[]
---@field has_flag fun(arg1: RecipeRaw, arg2: string): boolean
---@field ident fun(arg1: RecipeRaw): RecipeId
---@field result fun(arg1: RecipeRaw): ItypeId
---@field result_name fun(arg1: RecipeRaw): string
RecipeRaw = {}
---@return RecipeRaw
function RecipeRaw.new() end

---@class SkillId
---@field NULL_ID fun(): SkillId
---@field implements_int_id fun(): boolean
---@field is_null fun(arg1: SkillId): boolean
---@field is_valid fun(arg1: SkillId): boolean
---@field obj fun(arg1: SkillId): SkillRaw
---@field str fun(arg1: SkillId): string
---@field serialize fun(arg1: SkillId)
---@field deserialize fun(arg1: SkillId)
---@field __tostring fun(arg1: SkillId): string
SkillId = {}
---@return SkillId
---@overload fun(arg1: SkillId): SkillId
---@overload fun(arg1: string): SkillId
function SkillId.new() end

---@class SkillLevel
---@field can_train fun(arg1: SkillLevel): boolean
---@field highest_level fun(arg1: SkillLevel): integer
---@field is_training fun(arg1: SkillLevel): boolean
---@field level fun(arg1: SkillLevel): integer
---@field train fun(arg1: SkillLevel, arg2: integer, arg3: boolean)
SkillLevel = {}
---@return SkillLevel
function SkillLevel.new() end

---@class SkillLevelMap : table<SkillId, SkillLevel>
---@field get_skill_level fun(arg1: SkillLevelMap, arg2: SkillId): integer
---@field get_skill_level_object fun(arg1: SkillLevelMap, arg2: SkillId): SkillLevel
---@field mod_skill_level fun(arg1: SkillLevelMap, arg2: SkillId, arg3: integer)
SkillLevelMap = {}
---@return SkillLevelMap
function SkillLevelMap.new() end

---@class SpeciesTypeId
---@field NULL_ID fun(): SpeciesTypeId
---@field implements_int_id fun(): boolean
---@field is_null fun(arg1: SpeciesTypeId): boolean
---@field is_valid fun(arg1: SpeciesTypeId): boolean
---@field obj fun(arg1: SpeciesTypeId): SpeciesTypeRaw
---@field str fun(arg1: SpeciesTypeId): string
---@field serialize fun(arg1: SpeciesTypeId)
---@field deserialize fun(arg1: SpeciesTypeId)
---@field __tostring fun(arg1: SpeciesTypeId): string
SpeciesTypeId = {}
---@return SpeciesTypeId
---@overload fun(arg1: SpeciesTypeId): SpeciesTypeId
---@overload fun(arg1: string): SpeciesTypeId
function SpeciesTypeId.new() end

--- The class used for spells that *a player* knows, casts, and gains experience for using. If a given spell is not supposed to be directly cast by a player, consider using SpellSimple instead.
---@class Spell
---@field id SpellTypeId
---@field cast fun(arg1: Spell, arg2: Creature, arg3: Tripoint) @Cast this spell, as well as any sub-spells.
---@field cast_single_effect fun(arg1: Spell, arg2: Creature, arg3: Tripoint) @Cast *only* this spell's main effects. Generally, cast() should be used instead.
---@field desc fun(arg1: Spell): string
---@field gain_exp fun(arg1: Spell, arg2: integer)
---@field gain_levels fun(arg1: Spell, arg2: integer)
---@field get_level fun(arg1: Spell): integer
---@field name fun(arg1: Spell): string
---@field set_exp fun(arg1: Spell, arg2: integer)
---@field set_level fun(arg1: Spell, arg2: integer)
---@field xp fun(arg1: Spell): integer
Spell = {}
---@return Spell
---@overload fun(arg1: SpellTypeId, arg2: integer): Spell
function Spell.new() end

--- The type for basic spells. If you don't need to track XP from casting (e.g., if a spell is intended to be cast by anything *other than* a player), this is likely the appropriate type. Otherwise, see the Spell type.
---@class SpellSimple
---@field force_target_source boolean @Whether or not the target point is *locked* to the source's location.
---@field id SpellTypeId
---@field level integer
---@field trigger_once_in integer @Used for enchantments; the spell's *chance* to trigger every turn.
---@field cast fun(arg1: SpellSimple, arg2: Creature, arg3: Tripoint, arg4: int?)
---@field max_level fun(arg1: SpellSimple): integer @Returns the defined maximum level of this SpellSimple instance, if defined. Otherwise, returns 0.
---@field prompt_cast fun(arg1: SpellTypeId, arg2: Tripoint, arg3: int?): SpellSimple @Static function: Creates and immediately casts a SimpleSpell, then returns the new spell for potential reuse. If the given tripoint is the player's location, the spell will be locked to the player. (This does not necessarily cause friendly fire!) If an integer is specified, the spell will be cast at that level.
---@field __tostring fun(arg1: SpellSimple): string
SpellSimple = {}
---@return SpellSimple
---@overload fun(arg1: SpellTypeId, arg2: boolean): SpellSimple
---@overload fun(arg1: SpellTypeId, arg2: boolean, arg3: integer): SpellSimple
function SpellSimple.new() end

---@class SpellTypeId
---@field NULL_ID fun(): SpellTypeId
---@field implements_int_id fun(): boolean
---@field is_null fun(arg1: SpellTypeId): boolean
---@field is_valid fun(arg1: SpellTypeId): boolean
---@field obj fun(arg1: SpellTypeId): SpellTypeRaw
---@field str fun(arg1: SpellTypeId): string
---@field serialize fun(arg1: SpellTypeId)
---@field deserialize fun(arg1: SpellTypeId)
---@field __tostring fun(arg1: SpellTypeId): string
SpellTypeId = {}
---@return SpellTypeId
---@overload fun(arg1: SpellTypeId): SpellTypeId
---@overload fun(arg1: string): SpellTypeId
function SpellTypeId.new() end

--- The 'raw' type for storing the information defining every spell in the game. It's not possible to cast directly from this type; check SpellSimple and Spell.
---@class SpellTypeRaw
---@field aoe_increment number
---@field base_casting_time integer
---@field base_energy_cost integer
---@field casting_time_increment number
---@field damage_increment number
---@field difficulty integer
---@field dot_increment number
---@field duration_increment integer
---@field effect_name string @The name of the primary effect this spell will enact.
---@field effect_str string @Specifics about the effect this spell will enact.
---@field energy_increment number
---@field field_chance integer
---@field field_intensity_increment number
---@field field_intensity_variance number
---@field final_casting_time integer
---@field final_energy_cost integer
---@field id SpellTypeId
---@field max_aoe integer
---@field max_damage integer
---@field max_dot integer
---@field max_duration integer
---@field max_field_intensity integer
---@field max_level integer
---@field max_range integer
---@field min_aoe integer
---@field min_damage integer
---@field min_dot integer
---@field min_duration integer
---@field min_field_intensity integer
---@field min_range integer
---@field range_increment number
---@field additional_spells fun(arg1: SpellTypeRaw): SpellSimple[] @Other spells cast by this spell.
---@field get_all fun(): any @Returns a (long) list of every spell in the game.
---@field __tostring fun(arg1: SpellTypeRaw): string
SpellTypeRaw = {}
---@return SpellTypeRaw
function SpellTypeRaw.new() end

---@class TerId
---@field NULL_ID fun(): TerId
---@field implements_int_id fun(): boolean
---@field int_id fun(arg1: TerId): TerIntId
---@field is_null fun(arg1: TerId): boolean
---@field is_valid fun(arg1: TerId): boolean
---@field obj fun(arg1: TerId): TerRaw
---@field str fun(arg1: TerId): string
---@field serialize fun(arg1: TerId)
---@field deserialize fun(arg1: TerId)
---@field __tostring fun(arg1: TerId): string
TerId = {}
---@return TerId
---@overload fun(arg1: TerId): TerId
---@overload fun(arg1: TerIntId): TerId
---@overload fun(arg1: string): TerId
function TerId.new() end

---@class TerIntId
---@field is_valid fun(arg1: TerIntId): boolean
---@field obj fun(arg1: TerIntId): TerRaw
---@field str_id fun(arg1: TerIntId): TerId
---@field __tostring fun(arg1: TerIntId): string
TerIntId = {}
---@return TerIntId
---@overload fun(arg1: TerIntId): TerIntId
---@overload fun(arg1: TerId): TerIntId
function TerIntId.new() end

---@class TerRaw
---@field close TerId
---@field heat_radiation integer
---@field open TerId
---@field roof TerId
---@field transforms_into TerId
---@field trap_id_str string
---@field get_coverage fun(arg1: TerRaw): integer
---@field get_flags fun(arg1: TerRaw): any
---@field get_light_emitted fun(arg1: TerRaw): integer
---@field get_max_volume fun(arg1: TerRaw): Volume
---@field get_movecost fun(arg1: TerRaw): integer
---@field has_flag fun(arg1: TerRaw, arg2: string): boolean
---@field int_id fun(arg1: TerRaw): TerIntId
---@field name fun(arg1: TerRaw): string
---@field set_coverage fun(arg1: TerRaw, arg2: integer)
---@field set_flag fun(arg1: TerRaw, arg2: string)
---@field set_light_emitted fun(arg1: TerRaw, arg2: integer)
---@field set_max_volume fun(arg1: TerRaw, arg2: Volume)
---@field set_movecost fun(arg1: TerRaw, arg2: integer)
---@field str_id fun(arg1: TerRaw): TerId
TerRaw = {}
---@return TerRaw
function TerRaw.new() end

--- Represent duration between 2 fixed points in time
---@class TimeDuration
---@field from_days fun(arg1: integer): TimeDuration
---@field from_hours fun(arg1: integer): TimeDuration
---@field from_minutes fun(arg1: integer): TimeDuration
---@field from_seconds fun(arg1: integer): TimeDuration
---@field from_turns fun(arg1: integer): TimeDuration
---@field from_weeks fun(arg1: integer): TimeDuration
---@field make_random fun(arg1: TimeDuration, arg2: TimeDuration): TimeDuration
---@field to_days fun(arg1: TimeDuration): integer
---@field to_hours fun(arg1: TimeDuration): integer
---@field to_minutes fun(arg1: TimeDuration): integer
---@field to_seconds fun(arg1: TimeDuration): integer
---@field to_turns fun(arg1: TimeDuration): integer
---@field to_weeks fun(arg1: TimeDuration): integer
---@field serialize fun(arg1: TimeDuration)
---@field deserialize fun(arg1: TimeDuration)
---@field __add fun(arg1: TimeDuration, arg2: TimeDuration): TimeDuration
---@field __div fun(arg1: TimeDuration, arg2: integer): TimeDuration
---@field __mul fun(arg1: TimeDuration, arg2: integer): TimeDuration
---@field __sub fun(arg1: TimeDuration, arg2: TimeDuration): TimeDuration
---@field __tostring fun(arg1: TimeDuration): string
---@field __unm fun(arg1: TimeDuration): TimeDuration
TimeDuration = {}
---@return TimeDuration
function TimeDuration.new() end

--- Represent fixed point in time
---@class TimePoint
---@field from_turn fun(arg1: integer): TimePoint
---@field hour_of_day fun(arg1: TimePoint): integer
---@field is_dawn fun(arg1: TimePoint): boolean
---@field is_day fun(arg1: TimePoint): boolean
---@field is_dusk fun(arg1: TimePoint): boolean
---@field is_night fun(arg1: TimePoint): boolean
---@field minute_of_hour fun(arg1: TimePoint): integer
---@field second_of_minute fun(arg1: TimePoint): integer
---@field to_string_time_of_day fun(arg1: TimePoint): string
---@field to_turn fun(arg1: TimePoint): integer
---@field serialize fun(arg1: TimePoint)
---@field deserialize fun(arg1: TimePoint)
---@field __add fun(arg1: TimePoint, arg2: TimeDuration): TimePoint
---@field __eq fun(arg1: TimePoint, arg2: TimePoint): boolean
---@field __lt fun(arg1: TimePoint, arg2: TimePoint): boolean
---@field __sub fun(arg1: TimePoint, arg2: TimePoint): TimeDuration | fun(arg1: TimePoint, arg2: TimeDuration): TimePoint
---@field __tostring fun(arg1: TimePoint): string
TimePoint = {}
---@return TimePoint
function TimePoint.new() end

---@class Tinymap : Map
Tinymap = {}
---@return Tinymap
function Tinymap.new() end

---@class TrapId
---@field NULL_ID fun(): TrapId
---@field implements_int_id fun(): boolean
---@field int_id fun(arg1: TrapId): TrapIntId
---@field is_null fun(arg1: TrapId): boolean
---@field is_valid fun(arg1: TrapId): boolean
---@field obj fun(arg1: TrapId): TrapRaw
---@field str fun(arg1: TrapId): string
---@field serialize fun(arg1: TrapId)
---@field deserialize fun(arg1: TrapId)
---@field __tostring fun(arg1: TrapId): string
TrapId = {}
---@return TrapId
---@overload fun(arg1: TrapId): TrapId
---@overload fun(arg1: TrapIntId): TrapId
---@overload fun(arg1: string): TrapId
function TrapId.new() end

---@class TrapIntId
---@field is_valid fun(arg1: TrapIntId): boolean
---@field obj fun(arg1: TrapIntId): TrapRaw
---@field str_id fun(arg1: TrapIntId): TrapId
---@field __tostring fun(arg1: TrapIntId): string
TrapIntId = {}
---@return TrapIntId
---@overload fun(arg1: TrapIntId): TrapIntId
---@overload fun(arg1: TrapId): TrapIntId
function TrapIntId.new() end

---@class Tripoint
---@field x integer
---@field y integer
---@field z integer
---@field abs fun(arg1: Tripoint): Tripoint
---@field rotate_2d fun(arg1: Tripoint, arg2: integer, arg3: Point): Tripoint
---@field xy fun(arg1: Tripoint): Point
---@field serialize fun(arg1: Tripoint)
---@field deserialize fun(arg1: Tripoint)
---@field __add fun(arg1: Tripoint, arg2: Tripoint): Tripoint | fun(arg1: Tripoint, arg2: Point): Tripoint
---@field __div fun(arg1: Tripoint, arg2: integer): Tripoint
---@field __eq fun(arg1: Tripoint, arg2: Tripoint): boolean
---@field __idiv fun(arg1: Tripoint, arg2: integer): Tripoint
---@field __lt fun(arg1: Tripoint, arg2: Tripoint): boolean
---@field __mul fun(arg1: Tripoint, arg2: integer): Tripoint
---@field __sub fun(arg1: Tripoint, arg2: Tripoint): Tripoint | fun(arg1: Tripoint, arg2: Point): Tripoint
---@field __tostring fun(arg1: Tripoint): string
---@field __unm fun(arg1: Tripoint): Tripoint
Tripoint = {}
---@return Tripoint
---@overload fun(arg1: Point, arg2: integer): Tripoint
---@overload fun(arg1: Tripoint): Tripoint
---@overload fun(arg1: integer, arg2: integer, arg3: integer): Tripoint
function Tripoint.new() end

---@class UiList
---@field entries UiListEntry[] @Entries from uilist. Remember, in lua, the first element of vector is `entries[1]`, not `entries[0]`.
---@field add fun(arg1: UiList, arg2: integer, arg3: string) @Adds an entry. `string` is its name, and `int` is what it returns. If `int` is `-1`, the number is decided orderly.
---@field add_w_col fun(arg1: UiList, arg2: integer, arg3: string, arg4: string, arg5: string) @Adds an entry with desc and col(third `string`). col is additional text on the right of the entry name.
---@field add_w_desc fun(arg1: UiList, arg2: integer, arg3: string, arg4: string) @Adds an entry with desc(second `string`). `desc_enabled(true)` is required for showing desc.
---@field border_color fun(arg1: UiList, arg2: Color) @Changes the color. Default color is `c_magenta`.
---@field desc_enabled fun(arg1: UiList, arg2: boolean) @Puts a lower box. Footer or entry desc appears on it.
---@field footer fun(arg1: UiList, arg2: string) @Sets footer text which is in lower box. It overwrites descs of entries unless is empty.
---@field hilight_color fun(arg1: UiList, arg2: Color) @Changes the color. Default color is `h_white`.
---@field hotkey_color fun(arg1: UiList, arg2: Color) @Changes the color. Default color is `c_light_green`.
---@field query fun(arg1: UiList): integer @Returns retval for selected entry, or a negative number on fail/cancel
---@field text fun(arg1: UiList, arg2: string) @Sets text which is in upper box.
---@field text_color fun(arg1: UiList, arg2: Color) @Changes the color. Default color is `c_light_gray`.
---@field title fun(arg1: UiList, arg2: string) @Sets title which is on the top line.
---@field title_color fun(arg1: UiList, arg2: Color) @Changes the color. Default color is `c_green`.
UiList = {}
---@return UiList
function UiList.new() end

--- This type came from UiList.
---@class UiListEntry
---@field ctxt string @Entry text of column.
---@field desc string @Entry description
---@field enable boolean @Entry whether it's enabled or not. Default is `true`.
---@field txt string @Entry text
---@field txt_color fun(arg1: UiListEntry, arg2: Color) @Entry text color. Its default color is `c_red_red`, which makes color of the entry same as what `uilist` decides. So if you want to make color different, choose one except `c_red_red`.
UiListEntry = {}
---@return UiListEntry
function UiListEntry.new() end

---@class Volume
---@field from_liter fun(arg1: integer): Volume
---@field from_milliliter fun(arg1: integer): Volume
---@field to_liter fun(arg1: Volume): number
---@field to_milliliter fun(arg1: Volume): integer
---@field __eq fun(arg1: Volume, arg2: Volume): boolean
---@field __le fun(arg1: Volume, arg2: Volume): boolean
---@field __lt fun(arg1: Volume, arg2: Volume): boolean
Volume = {}
---@return Volume
function Volume.new() end

--================---- Libraries ----================

--- Various game constants
---@class const
---@field OM_MS_SIZE integer # value: 4320
---@field OM_OMT_SIZE integer # value: 180
---@field OM_SM_SIZE integer # value: 360
---@field OMT_MS_SIZE integer # value: 24
---@field OMT_SM_SIZE integer # value: 2
---@field SM_MS_SIZE integer # value: 12
const = {}

--- Methods for manipulating coord systems and calculating distance
---@class coords
---@field ms_to_om fun(arg1: Tripoint): (Point,Tripoint)
---@field ms_to_omt fun(arg1: Tripoint): (Tripoint,Point)
---@field ms_to_sm fun(arg1: Tripoint): (Tripoint,Point)
---@field om_to_ms fun(arg1: Point, arg2: Tripoint?): Tripoint
---@field omt_to_ms fun(arg1: Tripoint, arg2: Point?): Tripoint
---@field rl_dist fun(arg1: Tripoint, arg2: Tripoint): integer | fun(arg1: Point, arg2: Point): integer
---@field sm_to_ms fun(arg1: Tripoint, arg2: Point?): Tripoint
---@field square_dist fun(arg1: Tripoint, arg2: Tripoint): integer | fun(arg1: Point, arg2: Point): integer
---@field trig_dist fun(arg1: Tripoint, arg2: Tripoint): number | fun(arg1: Point, arg2: Point): number
coords = {}

--- Global game methods
---@class gapi
---@field add_msg fun(arg1: MsgType, arg2: any) | fun(arg1: any)
---@field add_npc_follower fun(arg1: Npc)
---@field add_on_every_x_hook fun(arg1: TimeDuration, arg2: function)
---@field before_time_starts fun(): TimePoint
---@field choose_adjacent fun(arg1: string, arg2: bool?): Tripoint?
---@field choose_direction fun(arg1: string, arg2: bool?): Tripoint?
---@field create_item fun(arg1: ItypeId, arg2: integer): any
---@field current_turn fun(): TimePoint
---@field get_avatar fun(): Avatar
---@field get_character_at fun(arg1: Tripoint, arg2: bool?): Character
---@field get_creature_at fun(arg1: Tripoint, arg2: bool?): Creature
---@field get_distribution_grid_tracker fun(): DistributionGridTracker
---@field get_map fun(): Map
---@field get_monster_at fun(arg1: Tripoint, arg2: bool?): Monster
---@field get_npc_at fun(arg1: Tripoint, arg2: bool?): Npc
---@field look_around fun(): Tripoint?
---@field place_monster_at fun(arg1: MtypeId, arg2: Tripoint): Monster
---@field place_monster_around fun(arg1: MtypeId, arg2: Tripoint, arg3: integer): Monster @Example: gapi.place_monster_around(MtypeId.new("mon_dog_bcollie"), gapi.get_avatar():get_pos_ms(), 5)
---@field place_player_overmap_at fun(arg1: Tripoint)
---@field play_ambient_variant_sound fun(arg1: string, arg2: string, arg3: integer, arg4: SfxChannel, arg5: integer, arg6: number, arg7: integer)
---@field play_variant_sound fun(arg1: string, arg2: string, arg3: integer) | fun(arg1: string, arg2: string, arg3: integer, arg4: Angle, arg5: number, arg6: number)
---@field remove_npc_follower fun(arg1: Npc)
---@field rng fun(arg1: integer, arg2: integer): integer
---@field turn_zero fun(): TimePoint
gapi = {}

--- Debugging and logging API.
---@class gdebug
---@field clear_lua_log fun()
---@field debugmsg fun(arg1: any)
---@field log_error fun(arg1: any)
---@field log_info fun(arg1: any)
---@field log_warn fun(arg1: any)
---@field reload_lua_code fun()
---@field save_game fun(): boolean
---@field set_log_capacity fun(arg1: integer)
gdebug = {}

--- Documentation for hooks
---@class hooks
---@field on_character_reset_stats fun() @Called when character stat gets reset
---@field on_every_x fun() @Called every in-game period
---@field on_game_load fun() @Called right after game has loaded
---@field on_game_save fun() @Called when game is about to save
---@field on_game_started fun() @Called when game is started the first time
---@field on_mapgen_postprocess fun(arg1: Map, arg2: Tripoint, arg3: TimePoint) @Called right after mapgen has completed. Map argument is the tinymap that represents 24x24 area (2x2 submaps, or 1x1 omt), tripoint is the absolute omt pos, and time_point is the current time (for time-based effects).
---@field on_mon_death fun() @Called when a monster is dead
---@field on_char_death fun() @Called after a character has died
---@field on_creature_dodged fun() @Called after a creature has dodged an attack
---@field on_creature_blocked fun() @Called after a creature has blocked an attack
---@field on_creature_melee_attacked fun() @Called after a creature has attacked in melee
---@field on_creature_performed_technique fun() @Called after a character has performed a combat technique

hooks = {}

--- Localization API.
---@class locale
---@field gettext fun(arg1: string): string @Expects english source string, returns translated string.
---@field pgettext fun(arg1: string, arg2: string): string @First is context string. Second is english source string.
---@field vgettext fun(arg1: string, arg2: string): string @First is english singular string, second is english plural string. Number is amount to translate for.
---@field vpgettext fun(arg1: string, arg2: string, arg3: string): string @First is context string. Second is english singular string. third is english plural. Number is amount to translate for.
locale = {}

--- Library for testing purposes
---@class tests_lib
---@field my_awesome_lambda_1 fun(): integer
---@field my_awesome_lambda_2 fun(): integer
tests_lib = {}

--=================---- Enums ----=================

---@enum AddictionType
AddictionType = {
	NONE = 0,
	CAFFEINE = 1,
	ALCOHOL = 2,
	SLEEP = 3,
	PKILLER = 4,
	SPEED = 5,
	CIG = 6,
	COKE = 7,
	CRACK = 8,
	MUTAGEN = 9,
	DIAZEPAM = 10,
	MARLOSS_R = 11,
	MARLOSS_B = 12,
	MARLOSS_Y = 13
}

---@enum Attitude
Attitude = {
	Hostile = 0,
	Neutral = 1,
	Friendly = 2,
	Any = 3
}

---@enum BodyPart
BodyPart = {
	TORSO = 0,
	HEAD = 1,
	EYES = 2,
	MOUTH = 3,
	ARM_L = 4,
	ARM_R = 5,
	HAND_L = 6,
	HAND_R = 7,
	LEG_L = 8,
	LEG_R = 9,
	FOOT_L = 10,
	FOOT_R = 11
}

---@enum CharacterMoveMode
CharacterMoveMode = {
	walk = 0,
	run = 1,
	crouch = 2
}

---@enum Color
Color = {
	c_black = 0,
	c_white = 1,
	c_light_gray = 2,
	c_dark_gray = 3,
	c_red = 4,
	c_green = 5,
	c_blue = 6,
	c_cyan = 7,
	c_magenta = 8,
	c_brown = 9,
	c_light_red = 10,
	c_light_green = 11,
	c_light_blue = 12,
	c_light_cyan = 13,
	c_pink = 14,
	c_yellow = 15,
	h_black = 16,
	h_white = 17,
	h_light_gray = 18,
	h_dark_gray = 19,
	h_red = 20,
	h_green = 21,
	h_blue = 22,
	h_cyan = 23,
	h_magenta = 24,
	h_brown = 25,
	h_light_red = 26,
	h_light_green = 27,
	h_light_blue = 28,
	h_light_cyan = 29,
	h_pink = 30,
	h_yellow = 31,
	i_black = 32,
	i_white = 33,
	i_light_gray = 34,
	i_dark_gray = 35,
	i_red = 36,
	i_green = 37,
	i_blue = 38,
	i_cyan = 39,
	i_magenta = 40,
	i_brown = 41,
	i_light_red = 42,
	i_light_green = 43,
	i_light_blue = 44,
	i_light_cyan = 45,
	i_pink = 46,
	i_yellow = 47,
	c_unset = 48,
	c_black_red = 49,
	c_white_red = 50,
	c_light_gray_red = 51,
	c_dark_gray_red = 52,
	c_red_red = 53,
	c_green_red = 54,
	c_blue_red = 55,
	c_cyan_red = 56,
	c_magenta_red = 57,
	c_brown_red = 58,
	c_light_red_red = 59,
	c_light_green_red = 60,
	c_light_blue_red = 61,
	c_light_cyan_red = 62,
	c_pink_red = 63,
	c_yellow_red = 64,
	c_black_white = 65,
	c_dark_gray_white = 66,
	c_light_gray_white = 67,
	c_white_white = 68,
	c_red_white = 69,
	c_light_red_white = 70,
	c_green_white = 71,
	c_light_green_white = 72,
	c_brown_white = 73,
	c_yellow_white = 74,
	c_blue_white = 75,
	c_light_blue_white = 76,
	c_magenta_white = 77,
	c_pink_white = 78,
	c_cyan_white = 79,
	c_light_cyan_white = 80,
	c_black_green = 81,
	c_dark_gray_green = 82,
	c_light_gray_green = 83,
	c_white_green = 84,
	c_red_green = 85,
	c_light_red_green = 86,
	c_green_green = 87,
	c_light_green_green = 88,
	c_brown_green = 89,
	c_yellow_green = 90,
	c_blue_green = 91,
	c_light_blue_green = 92,
	c_magenta_green = 93,
	c_pink_green = 94,
	c_cyan_green = 95,
	c_light_cyan_green = 96,
	c_black_yellow = 97,
	c_dark_gray_yellow = 98,
	c_light_gray_yellow = 99,
	c_white_yellow = 100,
	c_red_yellow = 101,
	c_light_red_yellow = 102,
	c_green_yellow = 103,
	c_light_green_yellow = 104,
	c_brown_yellow = 105,
	c_yellow_yellow = 106,
	c_blue_yellow = 107,
	c_light_blue_yellow = 108,
	c_magenta_yellow = 109,
	c_pink_yellow = 110,
	c_cyan_yellow = 111,
	c_light_cyan_yellow = 112,
	c_black_magenta = 113,
	c_dark_gray_magenta = 114,
	c_light_gray_magenta = 115,
	c_white_magenta = 116,
	c_red_magenta = 117,
	c_light_red_magenta = 118,
	c_green_magenta = 119,
	c_light_green_magenta = 120,
	c_brown_magenta = 121,
	c_yellow_magenta = 122,
	c_blue_magenta = 123,
	c_light_blue_magenta = 124,
	c_magenta_magenta = 125,
	c_pink_magenta = 126,
	c_cyan_magenta = 127,
	c_light_cyan_magenta = 128,
	c_black_cyan = 129,
	c_dark_gray_cyan = 130,
	c_light_gray_cyan = 131,
	c_white_cyan = 132,
	c_red_cyan = 133,
	c_light_red_cyan = 134,
	c_green_cyan = 135,
	c_light_green_cyan = 136,
	c_brown_cyan = 137,
	c_yellow_cyan = 138,
	c_blue_cyan = 139,
	c_light_blue_cyan = 140,
	c_magenta_cyan = 141,
	c_pink_cyan = 142,
	c_cyan_cyan = 143,
	c_light_cyan_cyan = 144
}

---@enum DamageType
DamageType = {
	DT_NULL = 0,
	DT_TRUE = 1,
	DT_BIOLOGICAL = 2,
	DT_BASH = 3,
	DT_CUT = 4,
	DT_ACID = 5,
	DT_STAB = 6,
	DT_HEAT = 7,
	DT_COLD = 8,
	DT_DARK = 9,
	DT_LIGHT = 10,
	DT_PSI = 11,
	DT_ELECTRIC = 12,
	DT_BULLET = 13
}

---@enum MonsterAttitude
MonsterAttitude = {
	MATT_NULL = 0,
	MATT_FRIEND = 1,
	MATT_FPASSIVE = 2,
	MATT_FLEE = 3,
	MATT_IGNORE = 4,
	MATT_FOLLOW = 5,
	MATT_ATTACK = 6,
	MATT_ZLAVE = 7
}

---@enum MonsterFactionAttitude
MonsterFactionAttitude = {
	ByMood = 0,
	Neutral = 1,
	Friendly = 2,
	Hate = 3
}

---@enum MonsterFlag
MonsterFlag = {
	SEES = 0,
	HEARS = 1,
	GOODHEARING = 2,
	SMELLS = 3,
	KEENNOSE = 4,
	STUMBLES = 5,
	WARM = 6,
	NOHEAD = 7,
	HARDTOSHOOT = 8,
	GRABS = 9,
	BASHES = 10,
	DESTROYS = 11,
	BORES = 12,
	POISON = 13,
	VENOM = 14,
	BADVENOM = 15,
	PARALYZEVENOM = 16,
	BLEED = 17,
	WEBWALK = 18,
	DIGS = 19,
	CAN_DIG = 20,
	FLIES = 21,
	AQUATIC = 22,
	SWIMS = 23,
	ATTACKMON = 24,
	ANIMAL = 25,
	PLASTIC = 26,
	SUNDEATH = 27,
	ELECTRIC = 28,
	ACIDPROOF = 29,
	ACIDTRAIL = 30,
	SHORTACIDTRAIL = 31,
	FIREPROOF = 32,
	SLUDGEPROOF = 33,
	SLUDGETRAIL = 34,
	COLDPROOF = 35,
	BIOPROOF = 36,
	DARKPROOF = 37,
	LIGHTPROOF = 38,
	PSIPROOF = 39,
	FIREY = 40,
	QUEEN = 41,
	ELECTRONIC = 42,
	FUR = 43,
	LEATHER = 44,
	WOOL = 45,
	FEATHER = 46,
	BONES = 47,
	FAT = 48,
	CONSOLE_DESPAWN = 49,
	IMMOBILE = 50,
	ID_CARD_DESPAWN = 51,
	RIDEABLE_MECH = 52,
	CARD_OVERRIDE = 53,
	MILITARY_MECH = 54,
	MECH_RECON_VISION = 55,
	MECH_DEFENSIVE = 56,
	HIT_AND_RUN = 57,
	GUILT = 58,
	PAY_BOT = 59,
	HUMAN = 60,
	NO_BREATHE = 61,
	FLAMMABLE = 62,
	REVIVES = 63,
	CHITIN = 64,
	VERMIN = 65,
	NOGIB = 66,
	LARVA = 67,
	ARTHROPOD_BLOOD = 68,
	ACID_BLOOD = 69,
	BILE_BLOOD = 70,
	ABSORBS = 71,
	ABSORBS_SPLITS = 72,
	CBM_CIV = 73,
	CBM_POWER = 74,
	CBM_SCI = 75,
	CBM_OP = 76,
	CBM_TECH = 77,
	CBM_SUBS = 78,
	UNUSED_76 = 79,
	FISHABLE = 80,
	GROUP_BASH = 81,
	SWARMS = 82,
	GROUP_MORALE = 83,
	INTERIOR_AMMO = 84,
	CLIMBS = 85,
	PACIFIST = 86,
	PUSH_MON = 87,
	PUSH_VEH = 88,
	NIGHT_INVISIBILITY = 89,
	REVIVES_HEALTHY = 90,
	NO_NECRO = 91,
	PATH_AVOID_DANGER_1 = 92,
	PATH_AVOID_DANGER_2 = 93,
	PATH_AVOID_FIRE = 94,
	PATH_AVOID_FALL = 95,
	PRIORITIZE_TARGETS = 96,
	NOT_HALLUCINATION = 97,
	CANPLAY = 98,
	PET_MOUNTABLE = 99,
	PET_HARNESSABLE = 100,
	DOGFOOD = 101,
	MILKABLE = 102,
	SHEARABLE = 103,
	NO_BREED = 104,
	NO_FUNG_DMG = 105,
	PET_WONT_FOLLOW = 106,
	DRIPS_NAPALM = 107,
	DRIPS_GASOLINE = 108,
	ELECTRIC_FIELD = 109,
	LOUDMOVES = 110,
	CAN_OPEN_DOORS = 111,
	STUN_IMMUNE = 112,
	DROPS_AMMO = 113,
	CAN_BE_ORDERED = 114,
	SMALL_HEAD = 115,
	TINY_HEAD = 116,
	NO_HEAD_BONUS_CRIT = 117,
	HEAD_BONUS_CRIT_1 = 118,
	HEAD_BONUS_CRIT_2 = 119,
	TORSO_BONUS_CRIT_1 = 120,
	TORSO_BONUS_CRIT_2 = 121,
	PROJECTILE_RESISTANT_1 = 122,
	PROJECTILE_RESISTANT_2 = 123,
	PROJECTILE_RESISTANT_3 = 124,
	PROJECTILE_RESISTANT_4 = 125
}

---@enum MonsterSize
MonsterSize = {
	TINY = 0,
	SMALL = 1,
	MEDIUM = 2,
	LARGE = 3,
	HUGE = 4
}

---@enum MsgType
MsgType = {
	good = 0,
	bad = 1,
	mixed = 2,
	warning = 3,
	info = 4,
	neutral = 5,
	debug = 6,
	headshot = 7,
	critical = 8,
	grazing = 9
}

---@enum NpcAttitude
NpcAttitude = {
	NPCATT_NULL = 0,
	NPCATT_TALK = 1,
	NPCATT_LEGACY_1 = 2,
	NPCATT_FOLLOW = 3,
	NPCATT_LEGACY_2 = 4,
	NPCATT_LEAD = 5,
	NPCATT_WAIT = 6,
	NPCATT_LEGACY_6 = 7,
	NPCATT_MUG = 8,
	NPCATT_WAIT_FOR_LEAVE = 9,
	NPCATT_KILL = 10,
	NPCATT_FLEE = 11,
	NPCATT_LEGACY_3 = 12,
	NPCATT_HEAL = 13,
	NPCATT_LEGACY_4 = 14,
	NPCATT_LEGACY_5 = 15,
	NPCATT_ACTIVITY = 16,
	NPCATT_FLEE_TEMP = 17,
	NPCATT_RECOVER_GOODS = 18
}

---@enum NpcNeed
NpcNeed = {
	need_none = 0,
	need_ammo = 1,
	need_weapon = 2,
	need_gun = 3,
	need_food = 4,
	need_drink = 5,
	need_safety = 6
}

---@enum SfxChannel
SfxChannel = {
	daytime_outdoors_env = 0,
	nighttime_outdoors_env = 1,
	underground_env = 2,
	indoors_env = 3,
	indoors_rain_env = 4,
	outdoors_snow_env = 5,
	outdoors_flurry_env = 6,
	outdoors_thunderstorm_env = 7,
	outdoors_rain_env = 8,
	outdoors_drizzle_env = 9,
	outdoor_blizzard = 10,
	deafness_tone = 11,
	danger_extreme_theme = 12,
	danger_high_theme = 13,
	danger_medium_theme = 14,
	danger_low_theme = 15,
	stamina_75 = 16,
	stamina_50 = 17,
	stamina_35 = 18,
	idle_chainsaw = 19,
	chainsaw_theme = 20,
	player_activities = 21,
	exterior_engine_sound = 22,
	interior_engine_sound = 23,
	radio = 24
}

