Lua API reference
Note
This page is auto-generated from data/raw/generate_docs.lua
and should not be edited directly.
Warning
In Lua, functions can be called with a : and pass the object itself as the first argument, eg:
Members where this behaviour is intended to be used are marked as 🇲 Methods
Their signature documentation hides the first argument to reflect that
- Call 🇫 Function members with a
. - Call 🇲 Method members with a
:
Alternatively, you can still call 🇲 Methods with a ., from the class type or the variable itself
but a value of the given type must be passed as the first parameter (that is hidden)
All of these do the same thing:
-
print(Angle.from_radians(3):to_degrees()) -
print(Angle.to_degrees(Angle.from_radians(3))) -
local a = Angle.from_radians(3) print(a:to_degrees()) -
local a = Angle.from_radians(3) print(a.to_degrees(a)) -
local a = Angle.from_radians(3) print(Angle.to_degrees(a))
ActivityTypeId
Bases
No base classes.
Constructors
- ActivityTypeId.new( )
- ActivityTypeId.new( ActivityTypeId )
- ActivityTypeId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> ActivityTypeId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> ActivityTypeRaw
str
🇲 Method --> ( ) -> string
AmmunitionEffectId
Bases
No base classes.
Constructors
- AmmunitionEffectId.new( )
- AmmunitionEffectId.new( AmmunitionEffectId )
- AmmunitionEffectId.new( AmmunitionEffectIntId )
- AmmunitionEffectId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> AmmunitionEffectId
implements_int_id
🇫 Function --> ( ) -> boolean
int_id
🇲 Method --> ( ) -> AmmunitionEffectIntId
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> AmmunitionEffectRaw
str
🇲 Method --> ( ) -> string
AmmunitionEffectIntId
Bases
No base classes.
Constructors
- AmmunitionEffectIntId.new( )
- AmmunitionEffectIntId.new( AmmunitionEffectIntId )
- AmmunitionEffectIntId.new( AmmunitionEffectId )
Members
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> AmmunitionEffectRaw
str_id
🇲 Method --> ( ) -> AmmunitionEffectId
AmmunitionTypeId
Bases
No base classes.
Constructors
- AmmunitionTypeId.new( )
- AmmunitionTypeId.new( AmmunitionTypeId )
- AmmunitionTypeId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> AmmunitionTypeId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> AmmunitionTypeRaw
str
🇲 Method --> ( ) -> string
Angle
Bases
No base classes.
Constructors
No constructors.
Members
from_arcmin
🇫 Function --> ( number ) -> Angle
from_degrees
🇫 Function --> ( number ) -> Angle
from_radians
🇫 Function --> ( number ) -> Angle
to_arcmin
🇲 Method --> ( ) -> number
to_degrees
🇲 Method --> ( ) -> number
to_radians
🇲 Method --> ( ) -> number
ArmorPortionData
Bases
No base classes.
Constructors
No constructors.
Members
coverage
🇻 Variable --> integer
encumber
🇻 Variable --> integer
max_encumber
🇻 Variable --> integer
get_covered_parts
🇲 Method --> ( ) -> BodyPartTypeIntId[]
Avatar
Bases
PlayerCharacterCreature
Constructors
No constructors.
Members
get_active_missions
🇲 Method --> ( ) -> Mission[]
get_completed_missions
🇲 Method --> ( ) -> Mission[]
get_failed_missions
🇲 Method --> ( ) -> Mission[]
Bionic
Bases
No base classes.
Constructors
No constructors.
Members
ammo_count
🇻 Variable --> integer
charge_timer
🇻 Variable --> integer
energy_stored
🇻 Variable --> Energy
incapacitated_time
🇻 Variable --> TimeDuration
invlet
🇻 Variable --> integer
powered
🇻 Variable --> boolean
show_sprite
🇻 Variable --> boolean
activate
🇲 Method --> ( Character, boolean? ) -> boolean
Activates this bionic on the given character. Optional block_message (default true) suppresses messages.
ammo_loaded
🇲 Method --> ( ) -> string
deactivate
🇲 Method --> ( Character, boolean? ) -> boolean
Deactivates this bionic on the given character. Optional block_message (default true) suppresses messages.
get_auto_start_thresh
🇲 Method --> ( ) -> number
get_quality
🇲 Method --> ( string ) -> integer
has_flag
🇲 Method --> ( string ) -> boolean
id
🇲 Method --> ( ) -> BionicDataId
info
🇲 Method --> ( ) -> BionicDataRaw
Returns the BionicData definition for this bionic.
is_auto_start_keep_full
🇲 Method --> ( ) -> boolean
is_auto_start_on
🇲 Method --> ( ) -> boolean
is_fueled_by
🇲 Method --> ( string ) -> boolean
remove_flag
🇲 Method --> ( string )
set_auto_start_thresh
🇲 Method --> ( number )
set_flag
🇲 Method --> ( string )
toggle_auto_start_mod
🇲 Method --> ( )
toggle_safe_fuel_mod
🇲 Method --> ( )
BionicDataId
Bases
No base classes.
Constructors
- BionicDataId.new( )
- BionicDataId.new( BionicDataId )
- BionicDataId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> BionicDataId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> BionicDataRaw
str
🇲 Method --> ( ) -> string
BionicDataRaw
Bases
No base classes.
Constructors
No constructors.
Members
activated
🇻 Variable --> boolean
can_uninstall
🇻 Variable --> boolean
capacity
🇻 Variable --> Energy
charge_time
🇻 Variable --> integer
exothermic_power_gen
🇻 Variable --> boolean
fuel_capacity
🇻 Variable --> integer
fuel_efficiency
🇻 Variable --> number
fuel_multiplier
🇻 Variable --> integer
included
🇻 Variable --> boolean
is_remote_fueled
🇻 Variable --> boolean
kcal_trigger
🇻 Variable --> integer
no_uninstall_reason
🇻 Variable --> string
passive_fuel_efficiency
🇻 Variable --> number
points
🇻 Variable --> integer
power_activate
🇻 Variable --> Energy
power_deactivate
🇻 Variable --> Energy
power_over_time
🇻 Variable --> Energy
power_trigger
🇻 Variable --> Energy
remote_fuel_draw
🇻 Variable --> Energy
starting_bionic
🇻 Variable --> boolean
weight_capacity_bonus
🇻 Variable --> Mass
weight_capacity_modifier
🇻 Variable --> number
available_upgrades
🇲 Method --> ( ) -> string[]
Available upgrade paths for this bionic.
bash_protec
🇲 Method --> ( ) -> table<string, integer>
Bash protection by body part.
bullet_protec
🇲 Method --> ( ) -> table<string, integer>
Bullet protection by body part.
canceled_mutations
🇲 Method --> ( ) -> string[]
Mutations/traits removed when this bionic is installed.
coverage_power_gen_penalty
🇲 Method --> ( ) -> number?
Returns the coverage power gen penalty, or nil if not set.
cut_protec
🇲 Method --> ( ) -> table<string, integer>
Cut protection by body part.
description
🇲 Method --> ( ) -> string
Returns the translated description of this bionic.
enchantments
🇲 Method --> ( ) -> string[]
Returns enchantment IDs as string values.
encumbrance
🇲 Method --> ( ) -> table<string, integer>
Encumbrance caused by this bionic on each body part.
env_protec
🇲 Method --> ( ) -> table<string, integer>
Environmental protection by body part.
fake_item
🇲 Method --> ( ) -> string
flags
🇲 Method --> ( ) -> string[]
Returns the set of flag IDs on this bionic definition.
fuel_opts
🇲 Method --> ( ) -> string[]
Returns fuel type IDs that can power this bionic.
get_all
🇫 Function --> ( ) -> BionicDataRaw[]
Returns a list of every bionic definition in the game.
has_flag
🇲 Method --> ( string ) -> boolean
Checks whether this bionic has a specific flag.
id
🇲 Method --> ( ) -> BionicDataId
included_bionics
🇲 Method --> ( ) -> string[]
Bionics automatically installed alongside this one.
learned_spells
🇲 Method --> ( ) -> table<string, integer>
Spells learned when this bionic is installed, mapped to level.
name
🇲 Method --> ( ) -> string
Returns the translated name of this bionic.
occupied_bodyparts
🇲 Method --> ( ) -> table<string, integer>
Body parts occupied by this bionic and slot space required.
power_gen_emission
🇲 Method --> ( ) -> string
required_bionics
🇲 Method --> ( ) -> string[]
Other bionics required for this one to be installed.
stat_bonus
🇲 Method --> ( ) -> table<string, integer>
Returns stat bonuses as a table mapping stat name to bonus value.
upgraded_bionic
🇲 Method --> ( ) -> string
BodyPartTypeId
Bases
No base classes.
Constructors
- BodyPartTypeId.new( )
- BodyPartTypeId.new( BodyPartTypeId )
- BodyPartTypeId.new( BodyPartTypeIntId )
- BodyPartTypeId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> BodyPartTypeId
implements_int_id
🇫 Function --> ( ) -> boolean
int_id
🇲 Method --> ( ) -> BodyPartTypeIntId
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> BodyPartTypeRaw
str
🇲 Method --> ( ) -> string
BodyPartTypeIntId
Bases
No base classes.
Constructors
- BodyPartTypeIntId.new( )
- BodyPartTypeIntId.new( BodyPartTypeIntId )
- BodyPartTypeIntId.new( BodyPartTypeId )
Members
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> BodyPartTypeRaw
str_id
🇲 Method --> ( ) -> BodyPartTypeId
BookRecipe
Bases
No base classes.
Constructors
No constructors.
Members
hidden
🇻 Variable --> boolean
name
🇻 Variable --> CppVal<translation>
recipe
🇻 Variable --> RecipeRaw
skill_level
🇻 Variable --> integer
Character
Bases
Creature
Constructors
No constructors.
Members
cash
🇻 Variable --> integer
focus_pool
🇻 Variable --> integer
follower_ids
🇻 Variable --> CharacterId[]
male
🇻 Variable --> boolean
mutation_category_level
🇻 Variable --> table<MutationCategoryTraitId, integer>
name
🇻 Variable --> string
activate_bionic
🇲 Method --> ( BionicDataId, boolean? ) -> boolean
activate_mutation
🇲 Method --> ( MutationBranchId )
activate_mutation_id
🇲 Method --> ( MutationBranchId )
add_addiction
🇲 Method --> ( AddictionType, integer )
add_bionic
🇲 Method --> ( BionicDataId )
add_item
🇲 Method --> ( Detached<Item> )
Adds a detached item to the player inventory
add_known_trap
🇲 Method --> ( TripointBubMs, TrapRaw )
Characterlearns that the given trap is on the given tripoint. If the trap is null, the character learns that there is no trap there.
add_known_trap
🇲 Method --> ( TripointBubMs, TrapIntId )
add_morale
🇲 Method --> ( MoraleTypeDataId, integer, integer, TimeDuration, TimeDuration, boolean, ItypeRaw )
addiction_level
🇲 Method --> ( AddictionType ) -> integer
age
🇲 Method --> ( ) -> integer
all_items
🇲 Method --> ( boolean ) -> Item[]
Gets all items
all_items_with_flag
🇲 Method --> ( JsonFlagId, boolean ) -> Item[]
Gets all items with the given flag
assign_activity
🇲 Method --> ( ActivityTypeId, integer, integer, integer, string )
assign_lua_activity
🇲 Method --> ( table )
Assigns a Lua-backed activity with opts.type, opts.duration, optional opts.on_finish, optional opts.on_turn, optional opts.data, optional opts.pos, optional opts.name, and optional opts.interruptable.
base_age
🇲 Method --> ( ) -> integer
base_height
🇲 Method --> ( ) -> integer
bionic_armor_bonus
🇲 Method --> ( BodyPartTypeIntId, DamageType ) -> number
bionics_weight
🇲 Method --> ( ) -> Mass
blood_loss
🇲 Method --> ( BodyPartTypeIntId ) -> integer
blossoms
🇲 Method --> ( )
bodypart_exposure
🇲 Method --> ( ) -> table<BodyPartTypeIntId, number>
bodyweight
🇲 Method --> ( ) -> Mass
can_hear
🇲 Method --> ( TripointBubMs, integer ) -> boolean
can_mount
🇲 Method --> ( Monster ) -> boolean
can_pick_volume
🇲 Method --> ( Volume ) -> boolean
can_pick_weight
🇲 Method --> ( Mass, boolean ) -> boolean
can_run
🇲 Method --> ( ) -> boolean
can_takeoff
🇲 Method --> ( Item ) -> boolean
Checks if a given
<code>[Item](#sol::Item)</code>can be taken off.
can_unwield
🇲 Method --> ( Item ) -> boolean
can_wear
🇲 Method --> ( Item, boolean ) -> boolean
Checks if creature can wear a given item. If boolean parameter is true, ignores already worn items
can_wield
🇲 Method --> ( Item ) -> boolean
cancel_activity
🇲 Method --> ( )
check_mount_is_spooked
🇲 Method --> ( ) -> boolean
check_mount_will_move
🇲 Method --> ( TripointBubMs ) -> boolean
clear_bionics
🇲 Method --> ( )
clear_morale
🇲 Method --> ( )
clear_mutations
🇲 Method --> ( )
clear_skills
🇲 Method --> ( )
consume_items
🇲 Method --> ( CppVal<item_comp>[] )
Consumes items from inventory based on item component list
consume_tools
🇲 Method --> ( CppVal<tool_comp>[] )
Consumes tool charges from inventory based on tool component list
cough
🇲 Method --> ( boolean, integer )
crafting_inventory
🇲 Method --> ( ) -> Inventory
Returns the crafting inventory for this character (includes nearby items)
create_item
🇲 Method --> ( ItypeId, integer ) -> Item
Creates and an item with the given id and amount to the player inventory
crossed_threshold
🇲 Method --> ( ) -> boolean
deactivate_bionic
🇲 Method --> ( BionicDataId, boolean? ) -> boolean
deactivate_mutation
🇲 Method --> ( MutationBranchId )
deactivate_mutation_id
🇲 Method --> ( MutationBranchId )
dismount
🇲 Method --> ( )
drench
🇲 Method --> ( integer, BodyPartTypeIntId[], boolean )
drop_all_items
🇲 Method --> ( )
Drops all items (inventory, worn, wielded) at the character's current position.
drop_inv
🇲 Method --> ( integer )
enough_power_for
🇲 Method --> ( BionicDataId ) -> boolean
expose_to_disease
🇲 Method --> ( DiseaseTypeId )
fall_asleep
🇲 Method --> ( )
🇲 Method --> ( TimeDuration )
forced_dismount
🇲 Method --> ( )
getID
🇲 Method --> ( ) -> CharacterId
get_activity
🇲 Method --> ( ) -> PlayerActivity
get_all_skills
🇲 Method --> ( ) -> SkillLevelMap
get_armor_acid
🇲 Method --> ( BodyPartTypeIntId ) -> integer
get_auto_start_thresh
🇲 Method --> ( BionicDataId ) -> number
get_base_traits
🇲 Method --> ( ) -> MutationBranchId[]
get_bionic
🇲 Method --> ( BionicDataId ) -> Bionic
get_bionics
🇲 Method --> ( ) -> BionicDataId[]
get_dependant_worn_items
🇲 Method --> ( Item ) -> Item[]
get_dex
🇲 Method --> ( ) -> integer
get_dex_base
🇲 Method --> ( ) -> integer
get_dex_bonus
🇲 Method --> ( ) -> integer
get_faction_id
🇲 Method --> ( ) -> FactionId
get_fatigue
🇲 Method --> ( ) -> integer
get_free_bionics_slots
🇲 Method --> ( BodyPartTypeIntId ) -> integer
get_healthy
🇲 Method --> ( ) -> number
get_healthy_mod
🇲 Method --> ( ) -> number
get_highest_category
🇲 Method --> ( ) -> MutationCategoryTraitId
get_hostile_creatures
🇲 Method --> ( integer ) -> Creature[]
get_int
🇲 Method --> ( ) -> integer
get_int_base
🇲 Method --> ( ) -> integer
get_int_bonus
🇲 Method --> ( ) -> integer
get_item_with_id
🇲 Method --> ( ItypeId, boolean ) -> Item
Gets the first occurrence of an item with the given id
get_kcal_percent
🇲 Method --> ( ) -> number
get_lowest_hp
🇲 Method --> ( ) -> integer
get_magic
🇲 Method --> ( ) -> KnownMagic
Access the character's spellbook and mana pool.
get_max_power_level
🇲 Method --> ( ) -> Energy
get_melee_stamina_cost
🇲 Method --> ( Item ) -> integer
get_morale
🇲 Method --> ( MoraleTypeDataId ) -> integer
get_morale_level
🇲 Method --> ( ) -> integer
get_movement_mode
🇲 Method --> ( ) -> CharacterMoveMode
get_mutations
🇲 Method --> ( boolean ) -> MutationBranchId[]
get_painkiller
🇲 Method --> ( ) -> integer
get_part_encumbrance
🇲 Method --> ( BodyPartTypeId ) -> integer
get_part_temp_btu
🇲 Method --> ( BodyPartTypeIntId ) -> integer
Gets the current temperature of a specific body part (in Body Temperature Units).
get_per
🇲 Method --> ( ) -> integer
get_per_base
🇲 Method --> ( ) -> integer
get_per_bonus
🇲 Method --> ( ) -> integer
get_power_level
🇲 Method --> ( ) -> Energy
get_rad
🇲 Method --> ( ) -> integer
get_shout_volume
🇲 Method --> ( ) -> integer
get_skill_level
🇲 Method --> ( SkillId ) -> integer
get_skill_level_object
🇲 Method --> ( SkillId ) -> SkillLevel
get_sleep_deprivation
🇲 Method --> ( ) -> integer
get_stamina
🇲 Method --> ( ) -> integer
get_stamina_max
🇲 Method --> ( ) -> integer
get_stim
🇲 Method --> ( ) -> integer
get_stored_kcal
🇲 Method --> ( ) -> integer
get_str
🇲 Method --> ( ) -> integer
get_str_base
🇲 Method --> ( ) -> integer
get_str_bonus
🇲 Method --> ( ) -> integer
get_temp_btu
🇲 Method --> ( ) -> table<BodyPartTypeIntId, integer>
Gets all bodyparts and their associated temperatures (in Body Temperature Units).
get_thirst
🇲 Method --> ( ) -> integer
get_time_died
🇲 Method --> ( ) -> TimePoint
get_total_bionics_slots
🇲 Method --> ( BodyPartTypeIntId ) -> integer
get_used_bionics_slots
🇲 Method --> ( BodyPartTypeIntId ) -> integer
get_visible_creatures
🇲 Method --> ( integer ) -> Creature[]
get_working_arm_count
🇲 Method --> ( ) -> integer
get_working_leg_count
🇲 Method --> ( ) -> integer
get_worn_items
🇲 Method --> ( ) -> Item[]
global_sm_location
🇲 Method --> ( ) -> TripointAbsSm
global_square_location
🇲 Method --> ( ) -> TripointAbsMs
has_active_bionic
🇲 Method --> ( BionicDataId ) -> boolean
has_active_mutation
🇲 Method --> ( MutationBranchId ) -> boolean
has_activity
🇲 Method --> ( ActivityTypeId ) -> boolean
has_addiction
🇲 Method --> ( AddictionType ) -> boolean
has_alarm_clock
🇲 Method --> ( ) -> boolean
has_any_bionic
🇲 Method --> ( ) -> boolean
has_base_trait
🇲 Method --> ( MutationBranchId ) -> boolean
has_bionic
🇲 Method --> ( BionicDataId ) -> boolean
has_bionics
🇲 Method --> ( ) -> boolean
has_child_flag
🇲 Method --> ( MutationBranchId ) -> boolean
has_item_with_flag
🇲 Method --> ( JsonFlagId, boolean ) -> boolean
Checks for an item with the given flag
has_item_with_id
🇲 Method --> ( ItypeId, boolean ) -> boolean
Checks for an item with the given id
has_mabuff
🇲 Method --> ( MartialArtsBuffId ) -> boolean
has_max_power
🇲 Method --> ( ) -> boolean
has_morale
🇲 Method --> ( MoraleTypeDataId ) -> boolean
has_morale_to_craft
🇲 Method --> ( ) -> boolean
has_morale_to_read
🇲 Method --> ( ) -> boolean
has_opposite_trait
🇲 Method --> ( MutationBranchId ) -> boolean
has_power
🇲 Method --> ( ) -> boolean
has_trait_flag
🇲 Method --> ( JsonTraitFlagId ) -> boolean
has_two_arms
🇲 Method --> ( ) -> boolean
has_watch
🇲 Method --> ( ) -> boolean
heal
🇲 Method --> ( BodyPartTypeIntId, integer )
healall
🇲 Method --> ( integer )
healing_rate
🇲 Method --> ( number ) -> number
healing_rate_medicine
🇲 Method --> ( number, BodyPartTypeIntId ) -> number
hearing_ability
🇲 Method --> ( ) -> number
height
🇲 Method --> ( ) -> integer
hitall
🇲 Method --> ( integer, integer, Creature ) -> integer
hurtall
🇲 Method --> ( integer, Creature, boolean )
in_climate_control
🇲 Method --> ( ) -> boolean
invalidate_crafting_inventory
🇲 Method --> ( )
Invalidates the cached crafting inventory
irradiate
🇲 Method --> ( number, boolean ) -> boolean
is_armed
🇲 Method --> ( ) -> boolean
is_auto_start_keep_full
🇲 Method --> ( BionicDataId ) -> boolean
is_auto_start_on
🇲 Method --> ( BionicDataId ) -> boolean
is_blind
🇲 Method --> ( ) -> boolean
is_deaf
🇲 Method --> ( ) -> boolean
is_hauling
🇲 Method --> ( ) -> boolean
is_invisible
🇲 Method --> ( ) -> boolean
is_limb_broken
🇲 Method --> ( BodyPartTypeIntId ) -> boolean
is_limb_disabled
🇲 Method --> ( BodyPartTypeIntId ) -> boolean
is_max_power
🇲 Method --> ( ) -> boolean
is_mounted
🇲 Method --> ( ) -> boolean
is_quiet
🇲 Method --> ( ) -> boolean
is_rad_immune
🇲 Method --> ( ) -> boolean
is_stealthy
🇲 Method --> ( ) -> boolean
is_throw_immune
🇲 Method --> ( ) -> boolean
is_weak_to_water
🇲 Method --> ( ) -> boolean
is_wearing
🇲 Method --> ( Item ) -> boolean
is_wearing_active_optcloak
🇲 Method --> ( ) -> boolean
is_wearing_active_power_armor
🇲 Method --> ( ) -> boolean
is_wearing_helmet
🇲 Method --> ( ) -> boolean
is_wearing_on_bp
🇲 Method --> ( ItypeId, BodyPartTypeIntId ) -> boolean
is_wearing_power_armor
🇲 Method --> ( boolean ) -> boolean
is_wielding
🇲 Method --> ( Item ) -> boolean
is_worn
🇲 Method --> ( Item ) -> boolean
item_worn_with_flag
🇲 Method --> ( JsonFlagId, BodyPartTypeIntId ) -> Item
item_worn_with_id
🇲 Method --> ( ItypeId, BodyPartTypeIntId ) -> Item
items_with
🇲 Method --> ( bool ) -> Item[]
Filters items
knows_recipe
🇲 Method --> ( RecipeId ) -> boolean
knows_trap
🇲 Method --> ( TripointBubMs ) -> boolean
Whether the character knows about the trap at the given tripoint.
learn_recipe
🇲 Method --> ( RecipeId )
mabuff_armor_bonus
🇲 Method --> ( DamageType ) -> integer
mabuff_arpen_bonus
🇲 Method --> ( DamageType ) -> integer
mabuff_attack_cost_mult
🇲 Method --> ( ) -> number
mabuff_attack_cost_penalty
🇲 Method --> ( ) -> integer
mabuff_block_bonus
🇲 Method --> ( ) -> integer
mabuff_damage_bonus
🇲 Method --> ( DamageType ) -> integer
mabuff_damage_mult
🇲 Method --> ( DamageType ) -> number
mabuff_dodge_bonus
🇲 Method --> ( ) -> number
mabuff_speed_bonus
🇲 Method --> ( ) -> integer
mabuff_tohit_bonus
🇲 Method --> ( ) -> number
max_stored_kcal
🇲 Method --> ( ) -> integer
metabolic_rate
🇲 Method --> ( ) -> number
mod_base_age
🇲 Method --> ( integer )
mod_base_height
🇲 Method --> ( integer )
mod_dex_bonus
🇲 Method --> ( integer )
mod_fatigue
🇲 Method --> ( integer )
mod_healthy
🇲 Method --> ( number )
mod_healthy_mod
🇲 Method --> ( number, number )
mod_int_bonus
🇲 Method --> ( integer )
mod_max_power_level
🇲 Method --> ( Energy )
mod_painkiller
🇲 Method --> ( integer )
mod_per_bonus
🇲 Method --> ( integer )
mod_power_level
🇲 Method --> ( Energy )
mod_rad
🇲 Method --> ( integer )
mod_skill_level
🇲 Method --> ( SkillId, integer )
mod_sleep_deprivation
🇲 Method --> ( integer )
mod_speed_bonus
🇲 Method --> ( integer )
mod_stamina
🇲 Method --> ( integer )
mod_stim
🇲 Method --> ( integer )
mod_stored_kcal
🇲 Method --> ( integer )
mod_str_bonus
🇲 Method --> ( integer )
mod_thirst
🇲 Method --> ( integer )
mount_creature
🇲 Method --> ( Monster )
mutate
🇲 Method --> ( )
mutate_category
🇲 Method --> ( MutationCategoryTraitId )
mutate_towards
🇲 Method --> ( MutationBranchId ) -> boolean
mutate_towards
🇲 Method --> ( MutationBranchId[], integer ) -> boolean
mutate_towards
🇲 Method --> ( MutationBranchId[], integer ) -> boolean
🇲 Method --> ( MutationBranchId ) -> boolean
mutation_armor
🇲 Method --> ( BodyPartTypeIntId, DamageType ) -> number
mutation_effect
🇲 Method --> ( MutationBranchId )
mutation_loss_effect
🇲 Method --> ( MutationBranchId )
mutation_ok
🇲 Method --> ( MutationBranchId, boolean, boolean ) -> boolean
mutation_value
🇲 Method --> ( string ) -> number
practice
🇲 Method --> ( SkillId, integer, integer, boolean )
read_speed
🇲 Method --> ( boolean ) -> integer
rem_addiction
🇲 Method --> ( AddictionType )
rem_morale
🇲 Method --> ( MoraleTypeDataId )
remove_bionic
🇲 Method --> ( BionicDataId )
remove_child_flag
🇲 Method --> ( MutationBranchId )
remove_item
🇲 Method --> ( Item ) -> Detached<Item>
Removes given
<code>[Item](#sol::Item)</code>from character's inventory. The<code>[Item](#sol::Item)</code>must be in the inventory, neither wielded nor worn.
remove_mutation
🇲 Method --> ( MutationBranchId, boolean )
remove_worn
🇲 Method --> ( Item ) -> Detached<Item>?
Attempts to remove the worn
<code>[Item](#sol::Item)</code>from character.
reset
🇲 Method --> ( )
reset_encumbrance
🇲 Method --> ( )
rest_quality
🇲 Method --> ( ) -> number
restore_scent
🇲 Method --> ( )
rooted
🇲 Method --> ( )
rust_rate
🇲 Method --> ( ) -> integer
setID
🇲 Method --> ( CharacterId, boolean )
set_auto_start_thresh
🇲 Method --> ( BionicDataId, number )
set_base_age
🇲 Method --> ( integer )
set_base_height
🇲 Method --> ( integer )
set_dex_bonus
🇲 Method --> ( integer )
set_faction_id
🇲 Method --> ( FactionId )
set_fatigue
🇲 Method --> ( integer )
set_healthy
🇲 Method --> ( number )
set_healthy_mod
🇲 Method --> ( number )
set_int_bonus
🇲 Method --> ( integer )
set_max_power_level
🇲 Method --> ( Energy )
set_movement_mode
🇲 Method --> ( CharacterMoveMode )
set_mutation
🇲 Method --> ( MutationBranchId )
set_painkiller
🇲 Method --> ( integer )
set_part_temp_btu
🇲 Method --> ( BodyPartTypeIntId, integer )
Sets a specific body part to a given temperature (in Body Temperature Units).
set_per_bonus
🇲 Method --> ( integer )
set_power_level
🇲 Method --> ( Energy )
set_rad
🇲 Method --> ( integer )
set_skill_level
🇲 Method --> ( SkillId, integer )
set_sleep_deprivation
🇲 Method --> ( integer )
set_speed_bonus
🇲 Method --> ( integer )
set_stamina
🇲 Method --> ( integer )
set_stim
🇲 Method --> ( integer )
set_stored_kcal
🇲 Method --> ( integer )
set_str_bonus
🇲 Method --> ( integer )
set_temp_btu
🇲 Method --> ( integer )
Sets ALL body parts on a creature to the given temperature (in Body Temperature Units).
set_thirst
🇲 Method --> ( integer )
shout
🇲 Method --> ( string, boolean )
sight_impaired
🇲 Method --> ( ) -> boolean
sound_hallu
🇲 Method --> ( )
spores
🇲 Method --> ( )
suffer
🇲 Method --> ( )
takeoff
🇲 Method --> ( Item ) -> boolean
Attempts to take off the worn
<code>[Item](#sol::Item)</code>from character.
toggle_auto_start_mod
🇲 Method --> ( BionicDataId )
toggle_safe_fuel_mod
🇲 Method --> ( BionicDataId )
uncanny_dodge
🇲 Method --> ( ) -> boolean
unset_mutation
🇲 Method --> ( MutationBranchId )
unwield
🇲 Method --> ( ) -> boolean
use_charges
🇲 Method --> ( ItypeId, integer, bool ) -> Detached<Item>[]
use_charges_if_avail
🇲 Method --> ( ItypeId, integer ) -> boolean
volume_capacity
🇲 Method --> ( ) -> Volume
volume_carried
🇲 Method --> ( ) -> Volume
vomit
🇲 Method --> ( )
wake_up
🇲 Method --> ( )
wear
🇲 Method --> ( Item, boolean ) -> boolean
Attempts to wear an item in the creature inventory. If boolean parameter is false, item is worn instantly
wear_detached
🇲 Method --> ( Detached<Item>, boolean ) -> boolean
Attempts to wear an item not in the creature inventory. If boolean parameter is false, item is worn instantly
wearing_something_on
🇲 Method --> ( BodyPartTypeIntId ) -> boolean
weight_carried
🇲 Method --> ( ) -> Mass
wield
🇲 Method --> ( Item ) -> boolean
worn_with_flag
🇲 Method --> ( JsonFlagId, BodyPartTypeIntId ) -> boolean
worn_with_id
🇲 Method --> ( ItypeId, BodyPartTypeIntId ) -> boolean
CharacterId
Bases
No base classes.
Constructors
- CharacterId.new( )
- CharacterId.new( int )
Members
get_value
🇲 Method --> ( ) -> integer
is_valid
🇲 Method --> ( ) -> boolean
Creature
Bases
No base classes.
Constructors
No constructors.
Members
abs_pos
🇲 Method --> ( ) -> TripointAbsMs
add_effect
🇲 Method --> ( EffectTypeId, TimeDuration, BodyPartTypeId?, integer? )
Effecttype, duration, bodypart and intensity
apply_damage
🇲 Method --> ( Creature, BodyPartTypeIntId, integer, boolean )
as_avatar
🇲 Method --> ( ) -> Avatar
as_character
🇲 Method --> ( ) -> Character
as_monster
🇲 Method --> ( ) -> Monster
as_npc
🇲 Method --> ( ) -> Npc
attitude_to
🇲 Method --> ( Creature ) -> Attitude
bub_pos
🇲 Method --> ( ) -> TripointBubMs
clear_effects
🇲 Method --> ( )
deal_damage
🇲 Method --> ( Creature, BodyPartTypeIntId, DamageInstance ) -> DealtDamageInstance
digging
🇲 Method --> ( ) -> boolean
disp_name
🇲 Method --> ( possessive: boolean, capitalize_first: boolean ) -> string
dodge_roll
🇲 Method --> ( ) -> number
erase
🇲 Method --> ( )
Removes this creature from the game without death notifications or a corpse.
get_all_body_parts
🇲 Method --> ( boolean ) -> BodyPartTypeIntId[]
get_armor_bash
🇲 Method --> ( BodyPartTypeIntId ) -> integer
get_armor_bash_base
🇲 Method --> ( BodyPartTypeIntId ) -> integer
get_armor_bash_bonus
🇲 Method --> ( ) -> integer
get_armor_bullet
🇲 Method --> ( BodyPartTypeIntId ) -> integer
get_armor_bullet_base
🇲 Method --> ( BodyPartTypeIntId ) -> integer
get_armor_bullet_bonus
🇲 Method --> ( ) -> integer
get_armor_cut
🇲 Method --> ( BodyPartTypeIntId ) -> integer
get_armor_cut_base
🇲 Method --> ( BodyPartTypeIntId ) -> integer
get_armor_cut_bonus
🇲 Method --> ( ) -> integer
get_armor_type
🇲 Method --> ( DamageType, BodyPartTypeIntId ) -> integer
get_block_bonus
🇲 Method --> ( ) -> integer
get_dodge
🇲 Method --> ( ) -> number
get_dodge_base
🇲 Method --> ( ) -> number
get_dodge_bonus
🇲 Method --> ( ) -> number
get_effect
🇲 Method --> ( EffectTypeId, BodyPartTypeId? ) -> Effect
get_effect_dur
🇲 Method --> ( EffectTypeId, BodyPartTypeId? ) -> TimeDuration
get_effect_int
🇲 Method --> ( EffectTypeId, BodyPartTypeId? ) -> integer
get_env_resist
🇲 Method --> ( BodyPartTypeIntId ) -> integer
get_grammatical_genders
🇲 Method --> ( ) -> string[]
get_hit
🇲 Method --> ( ) -> number
get_hit_base
🇲 Method --> ( ) -> number
get_hit_bonus
🇲 Method --> ( ) -> number
get_hp
🇲 Method --> ( BodyPartTypeIntId? ) -> integer
get_hp_max
🇲 Method --> ( BodyPartTypeIntId? ) -> integer
get_melee
🇲 Method --> ( ) -> number
get_moves
🇲 Method --> ( ) -> integer
get_name
🇲 Method --> ( ) -> string
get_num_blocks
🇲 Method --> ( ) -> integer
get_num_dodges
🇲 Method --> ( ) -> integer
get_pain
🇲 Method --> ( ) -> integer
get_part_healed_total
🇲 Method --> ( BodyPartTypeIntId ) -> integer
get_part_hp_cur
🇲 Method --> ( BodyPartTypeIntId ) -> integer
get_part_hp_max
🇲 Method --> ( BodyPartTypeIntId ) -> integer
get_perceived_pain
🇲 Method --> ( ) -> integer
get_pos_ms
🇲 Method --> ( ) -> TripointBubMs
get_random_body_part
🇲 Method --> ( boolean ) -> BodyPartTypeIntId
get_size
🇲 Method --> ( ) -> MonsterSize
get_speed
🇲 Method --> ( ) -> integer
get_speed_base
🇲 Method --> ( ) -> integer
get_speed_bonus
🇲 Method --> ( ) -> integer
get_speed_mult
🇲 Method --> ( ) -> number
get_value
🇲 Method --> ( string ) -> string
Retrieves an arbitrary entry using the same key format as set_value.
get_weight
🇲 Method --> ( ) -> Mass
get_weight_capacity
🇲 Method --> ( ) -> integer
has_effect
🇲 Method --> ( EffectTypeId, BodyPartTypeId? ) -> boolean
has_effect_with_flag
🇲 Method --> ( JsonFlagId, BodyPartTypeId? ) -> boolean
has_flag
🇲 Method --> ( MonsterFlag ) -> boolean
has_grab_break_tec
🇲 Method --> ( ) -> boolean
has_trait
🇲 Method --> ( MutationBranchId ) -> boolean
has_weapon
🇲 Method --> ( ) -> boolean
hp_percentage
🇲 Method --> ( ) -> integer
in_species
🇲 Method --> ( SpeciesTypeId ) -> boolean
is_avatar
🇲 Method --> ( ) -> boolean
is_dead
🇲 Method --> ( ) -> boolean
is_elec_immune
🇲 Method --> ( ) -> boolean
is_hallucination
🇲 Method --> ( ) -> boolean
is_immune_damage
🇲 Method --> ( DamageType ) -> boolean
is_immune_effect
🇲 Method --> ( EffectTypeId ) -> boolean
is_monster
🇲 Method --> ( ) -> boolean
is_npc
🇲 Method --> ( ) -> boolean
is_on_ground
🇲 Method --> ( ) -> boolean
is_underwater
🇲 Method --> ( ) -> boolean
is_warm
🇲 Method --> ( ) -> boolean
knock_back_to
🇲 Method --> ( TripointBubMs )
mod_all_parts_hp_cur
🇲 Method --> ( integer )
mod_moves
🇲 Method --> ( integer )
mod_pain
🇲 Method --> ( integer )
mod_pain_noresist
🇲 Method --> ( integer )
mod_part_hp_cur
🇲 Method --> ( BodyPartTypeIntId, integer )
mod_part_hp_max
🇲 Method --> ( BodyPartTypeIntId, integer )
power_rating
🇲 Method --> ( ) -> number
ranged_target_size
🇲 Method --> ( ) -> number
remove_effect
🇲 Method --> ( EffectTypeId, BodyPartTypeId? ) -> boolean
remove_value
🇲 Method --> ( string )
Removes an arbitrary entry using the same key format as set_value.
sees
🇲 Method --> ( TripointBubMs ) -> boolean
set_all_parts_hp_cur
🇲 Method --> ( integer )
set_all_parts_hp_to_max
🇲 Method --> ( )
set_armor_bash_bonus
🇲 Method --> ( integer )
set_armor_bullet_bonus
🇲 Method --> ( integer )
set_armor_cut_bonus
🇲 Method --> ( integer )
set_moves
🇲 Method --> ( integer )
set_pain
🇲 Method --> ( integer )
set_part_hp_cur
🇲 Method --> ( BodyPartTypeIntId, integer )
set_part_hp_max
🇲 Method --> ( BodyPartTypeIntId, integer )
set_pos
🇲 Method --> ( TripointAbsMs )
set_pos
🇲 Method --> ( TripointBubMs )
set_pos_ms
🇲 Method --> ( TripointBubMs )
set_underwater
🇲 Method --> ( boolean )
set_value
🇲 Method --> ( string, string )
Sets an arbitrary key : value pair for the creature.NPC dialogue system uses this, with the format("npctalk_var" + "" + type_var + "" + var_context + "_" + var_base_name) used for the key, skipping type or context if empty.
sight_range
🇲 Method --> ( integer ) -> integer
size_melee_penalty
🇲 Method --> ( ) -> integer
skin_name
🇲 Method --> ( ) -> string
speed_rating
🇲 Method --> ( ) -> number
stability_roll
🇲 Method --> ( ) -> number
values_table
🇲 Method --> ( ) -> table
Returns all stored creature vars as a Lua table
DamageInstance
Represents a bunch of damage amounts
Constructors are:
new(damageType, amount, armorPen, remainingArmorMultiplier, damageMultiplier)
Bases
No base classes.
Constructors
- DamageInstance.new( )
- DamageInstance.new( DamageType, double, double, double, double )
Members
damage_units
🇻 Variable --> DamageUnit[]
add
🇲 Method --> ( DamageUnit )
add_damage
🇲 Method --> ( DamageType, number, number, number, number )
clear
🇲 Method --> ( )
empty
🇲 Method --> ( ) -> boolean
mult_damage
🇲 Method --> ( number, boolean )
total_damage
🇲 Method --> ( ) -> number
type_damage
🇲 Method --> ( DamageType ) -> number
DamageUnit
Represents a damage amount
Constructors are:
new()
new(damageType, amount, armorPen, remainingArmorMultiplier, damageMultiplier)
Bases
No base classes.
Constructors
- DamageUnit.new( DamageType, double, double, double, double )
Members
amount
🇻 Variable --> number
damage_multiplier
🇻 Variable --> number
res_mult
🇻 Variable --> number
res_pen
🇻 Variable --> number
type
🇻 Variable --> DamageType
DealtDamageInstance
Represents the final dealt damage
Bases
No base classes.
Constructors
No constructors.
Members
bp_hit
🇻 Variable --> BodyPartTypeId
dealt_dams
🇻 Variable --> integer[]
total_damage
🇲 Method --> ( ) -> integer
type_damage
🇲 Method --> ( DamageType ) -> integer
DiseaseTypeId
Bases
No base classes.
Constructors
- DiseaseTypeId.new( )
- DiseaseTypeId.new( DiseaseTypeId )
- DiseaseTypeId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> DiseaseTypeId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> DiseaseTypeRaw
str
🇲 Method --> ( ) -> string
DistributionGrid
A grid that organizes producers, storage and consumers of a resource like electricity
Bases
No base classes.
Constructors
No constructors.
Members
empty
🇲 Method --> ( ) -> boolean
Check if grid is empty
get_contents
🇲 Method --> ( ) -> TripointAbsMs[]
Get current resource amount. Boolean argument (optional) controls recursive behavior (default true) Get vector of absolute map square coordinates of grid contents
get_power_stat
🇲 Method --> ( ) -> PowerStat
Get power generation and consumption statistics for the grid
get_resource
🇲 Method --> ( boolean? ) -> integer
Modify resource amount. First argument is amount, second (optional) controls recursive behavior (default true)
is_valid
🇲 Method --> ( ) -> boolean
Check if grid is valid
mod_resource
🇲 Method --> ( integer, boolean? ) -> integer
update
🇲 Method --> ( TimePoint )
Update the grid to the given time point
DistributionGridTracker
Manages all active distribution grids
Bases
No base classes.
Constructors
No constructors.
Members
debug_grid_id
🇲 Method --> ( TripointAbsOmt ) -> integer
Get unique identifier for grid at given overmap tile (for debug purposes, returns 0 if no grid)
grid_at
🇲 Method --> ( TripointAbsMs ) -> DistributionGrid
🇲 Method --> ( TripointAbsMs ) -> DistributionGrid
Get grid at absolute map square position
on_changed
🇲 Method --> ( TripointAbsMs )
Notify tracker that a tile at the given position has changed
on_options_changed
🇲 Method --> ( )
Notify tracker that game options have changed
update
🇲 Method --> ( TimePoint )
Update all grids to the given time point
Effect
Bases
No base classes.
Constructors
No constructors.
Members
activated
🇲 Method --> ( TimePoint, string, integer, boolean, number ) -> boolean
decay
🇲 Method --> ( TimePoint, boolean ) -> boolean
disp_desc
🇲 Method --> ( boolean ) -> string
disp_name
🇲 Method --> ( ) -> string
disp_short_desc
🇲 Method --> ( boolean ) -> string
get_addict_mod
🇲 Method --> ( string, integer ) -> number
get_amount
🇲 Method --> ( string, boolean ) -> integer
get_avg_mod
🇲 Method --> ( string, boolean ) -> integer
get_blocks_effects
🇲 Method --> ( ) -> EffectTypeId[]
get_bp
🇲 Method --> ( ) -> BodyPartTypeId
get_dur_add_perc
🇲 Method --> ( ) -> integer
get_duration
🇲 Method --> ( ) -> TimeDuration
get_harmful_cough
🇲 Method --> ( ) -> boolean
get_id
🇲 Method --> ( ) -> EffectTypeId
get_int_add_val
🇲 Method --> ( ) -> integer
get_int_dur_factor
🇲 Method --> ( ) -> TimeDuration
get_intensity
🇲 Method --> ( ) -> integer
get_max_duration
🇲 Method --> ( ) -> TimeDuration
get_max_intensity
🇲 Method --> ( ) -> integer
get_max_val
🇲 Method --> ( string, boolean ) -> integer
get_min_val
🇲 Method --> ( string, boolean ) -> integer
get_mod
🇲 Method --> ( string, boolean ) -> integer
get_percentage
🇲 Method --> ( string, integer, boolean ) -> number
get_removes_effects
🇲 Method --> ( ) -> EffectTypeId[]
get_resist_effects
🇲 Method --> ( ) -> EffectTypeId[]
get_resist_traits
🇲 Method --> ( ) -> MutationBranchId[]
get_sizing
🇲 Method --> ( string ) -> boolean
get_start_time
🇲 Method --> ( ) -> TimePoint
get_type
🇲 Method --> ( ) -> EffectTypeRaw
has_flag
🇲 Method --> ( JsonFlagId ) -> boolean
is_permanent
🇲 Method --> ( ) -> boolean
mod_duration
🇲 Method --> ( TimeDuration, boolean )
mod_intensity
🇲 Method --> ( integer, boolean ) -> integer
mult_duration
🇲 Method --> ( number, boolean )
set_duration
🇲 Method --> ( TimeDuration, boolean )
set_intensity
🇲 Method --> ( integer, boolean ) -> integer
set_permanent
🇲 Method --> ( )
use_part_descs
🇲 Method --> ( ) -> boolean
EffectTypeId
Bases
No base classes.
Constructors
- EffectTypeId.new( )
- EffectTypeId.new( EffectTypeId )
- EffectTypeId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> EffectTypeId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> EffectTypeRaw
str
🇲 Method --> ( ) -> string
Energy
Bases
No base classes.
Constructors
No constructors.
Members
from_joule
🇫 Function --> ( integer ) -> Energy
from_kilojoule
🇫 Function --> ( integer ) -> Energy
to_joule
🇲 Method --> ( ) -> integer
to_kilojoule
🇲 Method --> ( ) -> integer
ExplosionData
Bases
No base classes.
Constructors
No constructors.
Members
damage
🇻 Variable --> integer
Damage dealt by the explosion
fire
🇻 Variable --> boolean
Whether the explosion creates fire
radius
🇻 Variable --> number
Radius of the explosion
safe_range
🇲 Method --> ( ) -> integer
Returns the safe range of the explosion
FactionId
Bases
No base classes.
Constructors
- FactionId.new( )
- FactionId.new( FactionId )
- FactionId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> FactionId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> FactionRaw
str
🇲 Method --> ( ) -> string
FactionRaw
Bases
No base classes.
Constructors
No constructors.
Members
str_id
🇲 Method --> ( ) -> FactionId
FaultId
Bases
No base classes.
Constructors
- FaultId.new( )
- FaultId.new( FaultId )
- FaultId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> FaultId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> FaultRaw
str
🇲 Method --> ( ) -> string
FieldEmitId
Bases
No base classes.
Constructors
- FieldEmitId.new( )
- FieldEmitId.new( FieldEmitId )
- FieldEmitId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> FieldEmitId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> FieldEmitRaw
str
🇲 Method --> ( ) -> string
FieldTypeId
Bases
No base classes.
Constructors
- FieldTypeId.new( )
- FieldTypeId.new( FieldTypeId )
- FieldTypeId.new( FieldTypeIntId )
- FieldTypeId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> FieldTypeId
implements_int_id
🇫 Function --> ( ) -> boolean
int_id
🇲 Method --> ( ) -> FieldTypeIntId
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> FieldTypeRaw
str
🇲 Method --> ( ) -> string
FieldTypeIntId
Bases
No base classes.
Constructors
- FieldTypeIntId.new( )
- FieldTypeIntId.new( FieldTypeIntId )
- FieldTypeIntId.new( FieldTypeId )
Members
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> FieldTypeRaw
str_id
🇲 Method --> ( ) -> FieldTypeId
FurnId
Bases
No base classes.
Constructors
Members
NULL_ID
🇫 Function --> ( ) -> FurnId
implements_int_id
🇫 Function --> ( ) -> boolean
int_id
🇲 Method --> ( ) -> FurnIntId
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> FurnRaw
str
🇲 Method --> ( ) -> string
FurnIntId
Bases
No base classes.
Constructors
Members
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> FurnRaw
str_id
🇲 Method --> ( ) -> FurnId
FurnRaw
Bases
No base classes.
Constructors
No constructors.
Members
close
🇻 Variable --> FurnId
open
🇻 Variable --> FurnId
transforms_into
🇻 Variable --> FurnId
get_coverage
🇲 Method --> ( ) -> integer
get_flags
🇲 Method --> ( ) -> string[]
get_light_emitted
🇲 Method --> ( ) -> integer
get_max_volume
🇲 Method --> ( ) -> Volume
get_movecost
🇲 Method --> ( ) -> integer
has_flag
🇲 Method --> ( string ) -> boolean
int_id
🇲 Method --> ( ) -> FurnIntId
name
🇲 Method --> ( ) -> string
set_coverage
🇲 Method --> ( integer )
set_flag
🇲 Method --> ( string )
set_light_emitted
🇲 Method --> ( integer )
set_max_volume
🇲 Method --> ( Volume )
set_movecost
🇲 Method --> ( integer )
str_id
🇲 Method --> ( ) -> FurnId
Inventory
Look up requirement_data by ID string. Returns nil if not found.
Represents a character's inventory
Bases
No base classes.
Constructors
- Inventory.new( )
Members
clear
🇲 Method --> ( )
Clear all items from the inventory
count_item
🇲 Method --> ( ItypeId ) -> integer
Count items of a specific type
find_item
🇲 Method --> ( integer ) -> Item
Find item at position
has_charges
🇲 Method --> ( ItypeId, integer ) -> boolean
Check if inventory has the specified charges
has_components
🇲 Method --> ( ItypeId, integer ) -> boolean
Check if inventory has the specified components
has_tools
🇲 Method --> ( ItypeId, integer ) -> boolean
Check if inventory has the specified tool
position_by_type
🇲 Method --> ( ItypeId ) -> integer
Get item position by type
size
🇲 Method --> ( ) -> integer
Get the number of item stacks in the inventory
volume
🇲 Method --> ( ) -> Volume
Get the total volume of the inventory
weight
🇲 Method --> ( ) -> Mass
Get the total weight of the inventory
IslotAmmo
Bases
RangedData
Constructors
No constructors.
Members
ammo_effects
🇻 Variable --> AmmunitionEffectId[]
ammo_id
🇻 Variable --> AmmunitionTypeId
Ammo type, basically the "form" of the ammo that fits into the gun/tool
casing_id
🇻 Variable --> ItypeId?
Type id of casings, if any
cookoff
🇻 Variable --> boolean
Should this ammo explode in fire?
def_charges
🇻 Variable --> integer
Default charges
dont_recover_one_in
🇻 Variable --> integer
Chance to fail to recover the ammo used.
drop
🇻 Variable --> ItypeId
drop_active
🇻 Variable --> boolean
drop_count
🇻 Variable --> integer
force_stat_display
🇻 Variable --> boolean?
loudness
🇻 Variable --> integer
Base loudness of ammo (possibly modified by gun/gunmods)
recoil
🇻 Variable --> integer
Recoil (per shot), roughly equivalent to kinetic energy (in Joules)
special_cookoff
🇻 Variable --> boolean
Should this ammo apply a special explosion effect when in fire?
IslotArmor
Bases
No base classes.
Constructors
No constructors.
Members
env_resist
🇻 Variable --> integer
Resistance to environmental effects
env_resist_w_filter
🇻 Variable --> integer
Environmental protection of a gas mask with installed filter
layer_data
🇻 Variable --> ArmorPortionData[]
Layer, encumbrance and coverage information
resistance
🇻 Variable --> Resistances
Damage negated by this armor. Usually calculated from materials+thickness
sided
🇻 Variable --> boolean
Whether this item can be worn on either side of the body
storage
🇻 Variable --> Volume
How much storage this items provides when worn
thickness
🇻 Variable --> integer
Multiplier on resistances provided by armor's materials. Damaged armors have lower effective thickness, low capped at 1. Note: 1 thickness means item retains full resistance when damaged.
valid_mods
🇻 Variable --> string[]
Whitelisted clothing mods. Restricted clothing mods must be listed here by id to be compatible.
warmth
🇻 Variable --> integer
How much warmth this item provides
weight_capacity_bonus
🇻 Variable --> Mass
Bonus to weight capacity
weight_capacity_modifier
🇻 Variable --> number
Factor modifying weight capacity
IslotArtifact
Bases
No base classes.
Constructors
No constructors.
Members
charge_req
🇻 Variable --> ArtifactChargeReq
charge_type
🇻 Variable --> ArtifactCharge
dream_freq_met
🇻 Variable --> integer
dream_freq_unmet
🇻 Variable --> integer
dream_msg_met
🇻 Variable --> string[]
dream_msg_unmet
🇻 Variable --> string[]
effects_activated
🇻 Variable --> ArtifactEffectPassive[]
effects_carried
🇻 Variable --> ArtifactEffectActive[]
effects_wielded
🇻 Variable --> ArtifactEffectActive[]
effects_worn
🇻 Variable --> ArtifactEffectActive[]
charge_req_description
🇲 Method --> ( ) -> string
charge_type_description
🇲 Method --> ( ) -> string
effects_activated_descriptions
🇲 Method --> ( ) -> string[]
effects_activated_names
🇲 Method --> ( ) -> string[]
effects_carried_descriptions
🇲 Method --> ( ) -> string[]
effects_carried_names
🇲 Method --> ( ) -> string[]
effects_wielded_descriptions
🇲 Method --> ( ) -> string[]
effects_wielded_names
🇲 Method --> ( ) -> string[]
effects_worn_descriptions
🇲 Method --> ( ) -> string[]
effects_worn_names
🇲 Method --> ( ) -> string[]
IslotBattery
Bases
No base classes.
Constructors
No constructors.
Members
max_capacity
🇻 Variable --> Energy
Maximum energy the battery can store
IslotBionic
Bases
No base classes.
Constructors
No constructors.
Members
bionic_id
🇻 Variable --> BionicDataId
Id of the bionic
difficulty
🇻 Variable --> integer
Arbitrary difficulty scale
installation_data
🇻 Variable --> ItypeId
Itemwith installation data that can be used to provide almost guaranteed successful install of corresponding bionic
is_upgrade
🇻 Variable --> boolean
Whether this CBM is an upgrade of another
IslotBook
Bases
No base classes.
Constructors
No constructors.
Members
chapters
🇻 Variable --> integer
Fun books have chapters; after all are read, the book is less fun.
fun
🇻 Variable --> integer
How fun reading this is, can be negative
intelligence
🇻 Variable --> integer
Intelligence required to read it
martial_art
🇻 Variable --> MartialArtsId
Which martial art it teaches. Can be
MartialArtsId.NULL_ID
recipes
🇻 Variable --> BookRecipe[]
Recipes contained in this book
skill
🇻 Variable --> SkillId
Which skill it upgrades, if any. Can be
SkillId.NULL_ID
skill_max
🇻 Variable --> integer
The skill level the book provides
skill_min
🇻 Variable --> integer
The skill level required to understand it
time
🇻 Variable --> integer
How long in minutes it takes to read. "To read" means getting 1 skill point, not all of them.
IslotBrewable
Bases
No base classes.
Constructors
No constructors.
Members
results
🇻 Variable --> ItypeId[]
What are the results of fermenting this item
time
🇻 Variable --> TimeDuration
How long for this brew to ferment
IslotComestible
Bases
No base classes.
Constructors
No constructors.
Members
addict_type
🇻 Variable --> AddictionType
effects of addiction
addict_value
🇻 Variable --> integer
addiction potential
comest_type
🇻 Variable --> string
comestible subtype - eg. FOOD, DRINK, MED
contamination
🇻 Variable --> table<DiseaseTypeId, integer>
List of diseases carried by this comestible and their associated probability
cooks_like
🇻 Variable --> ItypeId
Reference to other item that replaces this one as a component in recipe results
def_charges
🇻 Variable --> integer
Defaults # of charges (drugs, loaf of bread? etc)
fatigue_mod
🇻 Variable --> integer
fatigue altering effect
freeze_point
🇻 Variable --> integer
freezing point in degrees Fahrenheit, below this temperature item can freeze
healthy
🇻 Variable --> integer
latent_heat
🇻 Variable --> number
monotony_penalty
🇻 Variable --> integer
A penalty applied to fun for every time this food has been eaten in the last 48 hours
parasites
🇻 Variable --> integer
chance (odds) of becoming parasitised when eating (zero if never occurs)
petfood
🇻 Variable --> string[]
pet food category
quench
🇻 Variable --> integer
effect on character thirst (may be negative)
radiation
🇻 Variable --> integer
Amount of radiation you get from this comestible
rot_spawn
🇻 Variable --> MonsterGroupId
The monster group that is drawn from when the item rots away
rot_spawn_chance
🇻 Variable --> integer
Chance the above monster group spawns
smoking_result
🇻 Variable --> ItypeId
Reference to item that will be received after smoking current item
specific_heat_liquid
🇻 Variable --> number
specific heats in J/(g K) and latent heat in J/g
specific_heat_solid
🇻 Variable --> number
spoils
🇻 Variable --> TimeDuration
Time until becomes rotten at standard temperature, or zero if never spoils
stimulant_type
🇻 Variable --> integer
stimulant effect
tool
🇻 Variable --> ItypeId
tool needed to consume (e.g. lighter for cigarettes)
get_default_nutr
🇲 Method --> ( ) -> integer
get_default_nutrition
🇲 Method --> ( ) -> table<VitaminId, integer>
Nutrition values to use for this type when they aren't calculated from components
has_calories
🇲 Method --> ( ) -> boolean
IslotContainer
Bases
No base classes.
Constructors
No constructors.
Members
contains
🇻 Variable --> Volume
Inner volume of the container
preserves
🇻 Variable --> boolean
Contents do not spoil
seals
🇻 Variable --> boolean
Can be resealed
unseals_into
🇻 Variable --> ItypeId
If this is set to anything but "null", changing this container's contents in any way will turn this item into that type
watertight
🇻 Variable --> boolean
Can hold liquids
IslotEngine
Bases
No base classes.
Constructors
No constructors.
Members
displacement
🇻 Variable --> integer
For combustion engines, the displacement
IslotFuel
Bases
No base classes.
Constructors
No constructors.
Members
energy
🇻 Variable --> number
Energyof the fuel (kilojoules per charge)
explosion_data
🇻 Variable --> CppVal<fuel_explosion>
has_explosion_data
🇻 Variable --> boolean
pump_terrain
🇻 Variable --> TerIntId
IslotGun
Bases
RangedData
Constructors
No constructors.
Members
ammo
🇻 Variable --> AmmunitionTypeId[]
What type of ammo this gun uses
ammo_effects
🇻 Variable --> AmmunitionEffectId[]
Effects that are applied to the ammo when fired
ammo_to_fire
🇻 Variable --> integer
How much ammo is consumed per shot
barrel_volume
🇻 Variable --> Volume
Volumeof material removed by sawing down the barrel, if left unspecified barrel can't be sawed down
blackpowder_tolerance
🇻 Variable --> integer
One in X chance for gun to require major cleanup after firing blackpowder shot
built_in_mods
🇻 Variable --> ItypeId[]
Built in mods. string is id of mod. These mods will get the IRREMOVABLE flag set
burst
🇻 Variable --> integer
Burst size for AUTO mode (legacy field for items not migrated to specify modes )
clip
🇻 Variable --> integer
For guns with an integral magazine what is the capacity?
default_mods
🇻 Variable --> ItypeId[]
Default mods, string is id of mod. These mods are removable but are default on the weapon
durability
🇻 Variable --> integer
Gun durability, affects gun being damaged during shooting
handling
🇻 Variable --> integer
How easy is control of recoil? If unset value automatically derived from weapon type
loudness
🇻 Variable --> integer
Modifies base loudness as provided by the currently loaded ammo
min_cycle_recoil
🇻 Variable --> integer
Minimum ammo recoil for gun to be able to fire more than once per attack
recoil
🇻 Variable --> integer
Additional recoil applied per shot before effects of handling are considered, useful for adding recoil effect to guns which otherwise consume no ammo
reload_noise
🇻 Variable --> string
Noise displayed when reloading the weapon
reload_noise_volume
🇻 Variable --> integer
Volumeof the noise made when reloading this weapon
reload_time
🇻 Variable --> integer
Reload time, in moves
sight_dispersion
🇻 Variable --> integer
Maximum aim achievable using base weapon sights
skill_used
🇻 Variable --> SkillId
What skill this gun uses
ups_charges
🇻 Variable --> integer
If this uses UPS charges, how many (per shoot), 0 for no UPS charges at all
get_gunmod_locations
🇲 Method --> ( ) -> table<string, integer>
Location for gun mods. Key is the location (untranslated!), value is the number of mods that the location can have. The value should be > 0
get_modes
🇲 Method --> ( ) -> string[]
Firing modes are supported by the gun. Always contains at least DEFAULT mode
IslotGunmod
Bases
RangedData
Constructors
No constructors.
Members
aim_speed
🇻 Variable --> integer
For sights (see @ref sight_dispersion), this value affects time cost of aiming. Higher is better. In case of multiple usable sights, the one with highest aim speed is used.
ammo_effects
🇻 Variable --> AmmunitionEffectId[]
ammo_to_fire_modifier
🇻 Variable --> integer
Increases base gun ammo to fire by this value per shot
ammo_to_fire_multiplier
🇻 Variable --> number
Increases base gun ammo to fire by this many times per shot
consume_chance
🇻 Variable --> integer
Percentage value change to the gun's loading time. Higher is less likely
consume_divisor
🇻 Variable --> integer
Divsor to scale back gunmod consumption damage. lower is more damaging. Affected by ammo loudness and recoil, see ranged.cpp for how much.
exclusion
🇻 Variable --> CppVal<std_unordered_set<string_id<itype>>>
What kind of weapons this gunmod can't be used with
exclusion_category
🇻 Variable --> CppVal<std_unordered_set<string_id<weapon_category>>>[]
What category of weapons this gunmod can't be used with
handling
🇻 Variable --> integer
Relative adjustment to base gun handling
install_time
🇻 Variable --> integer
How many moves does this gunmod take to install?
loudness
🇻 Variable --> integer
Modifies base loudness as provided by the currently loaded ammo
min_str_required_mod
🇻 Variable --> integer
Modifies base strength required
reload_modifier
🇻 Variable --> integer
Percentage value change to the gun's loading time. Higher is slower
sight_dispersion
🇻 Variable --> integer
If this value is set (non-negative), this gunmod functions as a sight. A sight is only usable to aim by a character whose current
Character::recoil is at or below this value.
ups_charges_modifier
🇻 Variable --> integer
Increases base gun UPS consumption by this value per shot
ups_charges_multiplier
🇻 Variable --> number
Increases base gun UPS consumption by this many times per shot
usable
🇻 Variable --> CppVal<std_unordered_set<string_id<itype>>>
What kind of weapons this gunmod can be used with
usable_category
🇻 Variable --> CppVal<std_unordered_set<string_id<weapon_category>>>[]
What category of weapons this gunmod can be used with
weight_multiplier
🇻 Variable --> number
Increases gun weight by this many times
get_added_slots
🇲 Method --> ( ) -> table<string, integer>
Additional gunmod slots to add to the gun
get_location
🇲 Method --> ( ) -> string
Where is this gunmod installed (e.g. "stock", "rail")?
get_mod_blacklist
🇲 Method --> ( ) -> string[]
Not compatible on weapons that have this mod slot
get_mode_modifiers
🇲 Method --> ( ) -> string[]
Firing modes added to or replacing those of the base gun
IslotMagazine
Bases
No base classes.
Constructors
No constructors.
Members
ammo_type
🇻 Variable --> AmmunitionTypeId[]
What type of ammo this magazine can be loaded with
capacity
🇻 Variable --> integer
Capacity of magazine (in equivalent units to ammo charges)
count
🇻 Variable --> integer
Default amount of ammo contained by a magazine (often set for ammo belts)
default_ammo
🇻 Variable --> ItypeId
Default type of ammo contained by a magazine (often set for ammo belts)
linkage
🇻 Variable --> ItypeId?
For ammo belts one linkage (of given type) is dropped for each unit of ammo consumed
protects_contents
🇻 Variable --> boolean
If false, ammo will cook off if this mag is affected by fire
reliability
🇻 Variable --> integer
How reliable this magazine on a range of 0 to 10?
reload_time
🇻 Variable --> integer
How long it takes to load each unit of ammo into the magazine
IslotMilling
Bases
No base classes.
Constructors
No constructors.
Members
conversion_rate
🇻 Variable --> integer
converts_into
🇻 Variable --> ItypeId
IslotMod
Bases
No base classes.
Constructors
No constructors.
Members
acceptable_ammo
🇻 Variable --> AmmunitionTypeId[]
If non-empty restrict mod to items with those base (before modifiers) ammo types
ammo_modifier
🇻 Variable --> AmmunitionTypeId[]
If set modifies parent ammo to this type
capacity_multiplier
🇻 Variable --> number
Proportional adjustment of parent item ammo capacity
magazine_adaptor
🇻 Variable --> table<AmmunitionTypeId, ItypeId[]>
If non-empty replaces the compatible magazines for the parent item
IslotPetArmor
Bases
No base classes.
Constructors
No constructors.
Members
bodytype
🇻 Variable --> string
What animal bodytype can wear this armor
env_resist
🇻 Variable --> integer
Resistance to environmental effects
env_resist_w_filter
🇻 Variable --> integer
Environmental protection of a gas mask with installed filter
max_vol
🇻 Variable --> Volume
The maximum volume a pet can be and wear this armor
min_vol
🇻 Variable --> Volume
The minimum volume a pet can be and wear this armor
storage
🇻 Variable --> Volume
How much storage this items provides when worn
thickness
🇻 Variable --> integer
Multiplier on resistances provided by this armor
IslotSeed
Bases
No base classes.
Constructors
No constructors.
Members
byproducts
🇻 Variable --> ItypeId[]
Additionally items (a list of their item ids) that will spawn when harvesting the plant.
fruit_div
🇻 Variable --> integer
Amount of harvested charges of fruits is divided by this number.
fruit_id
🇻 Variable --> ItypeId
Type id of the fruit item.
grow
🇻 Variable --> TimeDuration
Time it takes for a seed to grow (based of off a season length of 91 days).
get_plant_name
🇲 Method --> ( integer ) -> string
Name of the plant.
IslotTool
Bases
No base classes.
Constructors
No constructors.
Members
ammo_id
🇻 Variable --> AmmunitionTypeId[]
charge_factor
🇻 Variable --> integer
charges_per_use
🇻 Variable --> integer
def_charges
🇻 Variable --> integer
default_ammo
🇻 Variable --> ItypeId
max_charges
🇻 Variable --> integer
power_draw
🇻 Variable --> integer
rand_charges
🇻 Variable --> integer[]
revert_msg
🇻 Variable --> string
revert_to
🇻 Variable --> ItypeId?
subtype
🇻 Variable --> ItypeId
turns_active
🇻 Variable --> integer
turns_per_charge
🇻 Variable --> integer
ups_eff_mult
🇻 Variable --> integer
ups_recharge_rate
🇻 Variable --> integer
IslotWheel
Bases
No base classes.
Constructors
No constructors.
Members
diameter
🇻 Variable --> integer
Diameter of wheel in millimeters. Integer JSON values are legacy inches.
width
🇻 Variable --> integer
Width of wheel in millimeters. Integer JSON values are legacy inches.
Item
Bases
No base classes.
Constructors
No constructors.
Members
charges
🇻 Variable --> integer
activate
🇲 Method --> ( )
add_item_with_id
🇲 Method --> ( ItypeId, integer )
Adds an item(s) to contents
add_technique
🇲 Method --> ( MartialArtsTechniqueId )
Adds the technique. It isn't treated original, but additional.
ammo_capacity
🇲 Method --> ( boolean ) -> integer
Gets the maximum capacity of a magazine
ammo_consume
🇲 Method --> ( integer, TripointBubMs ) -> integer
ammo_current
🇲 Method --> ( ) -> ItypeId
ammo_data
🇲 Method --> ( ) -> ItypeRaw
ammo_remaining
🇲 Method --> ( ) -> integer
Get remaining ammo, works with batteries & stuff too
ammo_required
🇲 Method --> ( ) -> integer
ammo_set
🇲 Method --> ( ItypeId, integer )
ammo_unset
🇲 Method --> ( )
attack_cost
🇲 Method --> ( ) -> integer
can_contain
🇲 Method --> ( Item ) -> boolean
Checks if this item can contain another
clear_vars
🇲 Method --> ( )
Erase all variables
conductive
🇲 Method --> ( ) -> boolean
convert
🇲 Method --> ( ItypeId )
Converts the item as given
<code>[ItypeId](#sol::ItypeId)</code>.
covers
🇲 Method --> ( BodyPartTypeIntId ) -> boolean
Checks if the item covers a bodypart
current_magazine
🇲 Method --> ( ) -> Item
Gets the current magazine
deactivate
🇲 Method --> ( )
display_name
🇲 Method --> ( integer ) -> string
Display name with all bells and whistles like ammo and prefixes
energy_remaining
🇲 Method --> ( ) -> Energy
erase_var
🇲 Method --> ( string )
Erase variable
get_category_id
🇲 Method --> ( ) -> string
Gets the category id this item is in
get_comestible_fun
🇲 Method --> ( ) -> integer
get_counter
🇲 Method --> ( ) -> integer
get_damage
🇲 Method --> ( ) -> integer
Get current item damage value (durability). Higher values mean more damaged. Default range is -1000 (min) to 4000 (max), configurable via 'damage_states' in JSON.
get_damage_level
🇲 Method --> ( ) -> integer
🇲 Method --> ( integer ) -> integer
Get item damage as a level from 0 to max. Used for UI display and damage thresholds.
get_dispersion_bonus
🇲 Method --> ( ) -> integer
get_kcal
🇲 Method --> ( ) -> integer
get_max_damage
🇲 Method --> ( ) -> integer
Get maximum possible damage value before item is destroyed. Default is 4000, configurable via 'damage_states' in JSON.
get_melee_damage_bonus
🇲 Method --> ( ) -> DamageInstance
get_melee_hit_bonus
🇲 Method --> ( ) -> integer
get_min_damage
🇲 Method --> ( ) -> integer
Get minimum possible damage value (can be negative for reinforced items). Default is -1000, configurable via 'damage_states' in JSON.
get_mtype
🇲 Method --> ( ) -> MonsterTypeId
Almost for a corpse.
get_owner
🇲 Method --> ( ) -> FactionId
Gets the faction id that owns this item
get_owner_name
🇲 Method --> ( ) -> string
get_quench
🇲 Method --> ( ) -> integer
get_range_bonus
🇲 Method --> ( ) -> integer
get_ranged_damage_bonus
🇲 Method --> ( ) -> DamageInstance
get_recoil_bonus
🇲 Method --> ( ) -> integer
get_relative_health
🇲 Method --> ( ) -> number
Get relative health as ratio 0.0-1.0, where 1.0 is undamaged and 0.0 is destroyed
get_reload_time
🇲 Method --> ( ) -> integer
get_rot
🇲 Method --> ( ) -> TimeDuration
Gets the
TimeDurationuntil this item rots
get_techniques
🇲 Method --> ( ) -> MartialArtsTechniqueId[]
Gets all techniques. Including original techniques.
get_type
🇲 Method --> ( ) -> ItypeId
get_var_num
🇲 Method --> ( string, number ) -> number
Get variable as float number
get_var_str
🇲 Method --> ( string, string ) -> string
Get variable as string
get_var_tri
🇲 Method --> ( string, Tripoint ) -> Tripoint
Get variable as tripoint
has_flag
🇲 Method --> ( JsonFlagId ) -> boolean
has_infinite_charges
🇲 Method --> ( ) -> boolean
has_item_with_id
🇲 Method --> ( ItypeId ) -> boolean
Checks item contents for a given item id
has_own_flag
🇲 Method --> ( JsonFlagId ) -> boolean
has_technique
🇲 Method --> ( MartialArtsTechniqueId ) -> boolean
Checks if this item has the technique as an addition. Doesn't check original techniques.
has_var
🇲 Method --> ( string ) -> boolean
Check for variable of any type
invoke_at
🇲 Method --> ( TripointBubMs ) -> integer
Immediately invokes this item's use action at the given map-square position. Returns the charges consumed by the use action.
is_active
🇲 Method --> ( ) -> boolean
is_ammo
🇲 Method --> ( ) -> boolean
is_ammo_belt
🇲 Method --> ( ) -> boolean
is_ammo_container
🇲 Method --> ( ) -> boolean
is_armor
🇲 Method --> ( ) -> boolean
is_artifact
🇲 Method --> ( ) -> boolean
is_bandolier
🇲 Method --> ( ) -> boolean
is_bionic
🇲 Method --> ( ) -> boolean
is_book
🇲 Method --> ( ) -> boolean
is_brewable
🇲 Method --> ( ) -> boolean
is_bucket
🇲 Method --> ( ) -> boolean
is_bucket_nonempty
🇲 Method --> ( ) -> boolean
is_comestible
🇲 Method --> ( ) -> boolean
is_container
🇲 Method --> ( ) -> boolean
is_container_empty
🇲 Method --> ( ) -> boolean
is_corpse
🇲 Method --> ( ) -> boolean
is_craft
🇲 Method --> ( ) -> boolean
is_dangerous
🇲 Method --> ( ) -> boolean
is_deployable
🇲 Method --> ( ) -> boolean
is_emissive
🇲 Method --> ( ) -> boolean
is_engine
🇲 Method --> ( ) -> boolean
is_faulty
🇲 Method --> ( ) -> boolean
is_firearm
🇲 Method --> ( ) -> boolean
is_food
🇲 Method --> ( ) -> boolean
is_food_container
🇲 Method --> ( ) -> boolean
is_fuel
🇲 Method --> ( ) -> boolean
is_gun
🇲 Method --> ( ) -> boolean
is_gunmod
🇲 Method --> ( ) -> boolean
is_holster
🇲 Method --> ( ) -> boolean
is_irremovable
🇲 Method --> ( ) -> boolean
is_made_of
🇲 Method --> ( MaterialTypeId ) -> boolean
is_magazine
🇲 Method --> ( ) -> boolean
Is this a magazine? (batteries are magazines)
is_map
🇲 Method --> ( ) -> boolean
is_med_container
🇲 Method --> ( ) -> boolean
is_medication
🇲 Method --> ( ) -> boolean
is_melee
🇲 Method --> ( DamageType ) -> boolean
Is this item an effective melee weapon for the given damage type?
is_money
🇲 Method --> ( ) -> boolean
is_non_resealable_container
🇲 Method --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_owned_by
🇲 Method --> ( Character, boolean ) -> boolean
Checks if this item owned by a character
is_power_armor
🇲 Method --> ( ) -> boolean
is_relic
🇲 Method --> ( ) -> boolean
is_reloadable
🇲 Method --> ( ) -> boolean
is_salvageable
🇲 Method --> ( boolean ) -> boolean
is_seed
🇲 Method --> ( ) -> boolean
is_sided
🇲 Method --> ( ) -> boolean
is_silent
🇲 Method --> ( ) -> boolean
is_soft
🇲 Method --> ( ) -> boolean
is_stackable
🇲 Method --> ( ) -> boolean
is_tainted
🇲 Method --> ( ) -> boolean
is_tool
🇲 Method --> ( ) -> boolean
is_toolmod
🇲 Method --> ( ) -> boolean
is_transformable
🇲 Method --> ( ) -> boolean
is_unarmed_weapon
🇲 Method --> ( ) -> boolean
is_upgrade
🇲 Method --> ( ) -> boolean
is_watertight_container
🇲 Method --> ( ) -> boolean
is_wheel
🇲 Method --> ( ) -> boolean
made_of
🇲 Method --> ( ) -> MaterialTypeId[]
mod_charges
🇲 Method --> ( integer )
mod_damage
🇲 Method --> ( integer ) -> boolean
🇲 Method --> ( integer, DamageType ) -> boolean
Modify item damage by given amount. Returns true if item should be destroyed.
price
🇲 Method --> ( boolean ) -> number
Cents of the item.
boolis whether it is a post-cataclysm value.
remaining_capacity_for_id
🇲 Method --> ( ItypeId, boolean ) -> integer
Gets the remaining space available for a type of liquid
remove_technique
🇲 Method --> ( MartialArtsTechniqueId )
Removes the additional technique. Doesn't affect originial techniques.
set_charges
🇲 Method --> ( integer )
set_counter
🇲 Method --> ( integer )
set_damage
🇲 Method --> ( integer )
Set item damage to specified value. Clamped between min_damage and max_damage.
set_dispersion_bonus
🇲 Method --> ( integer )
set_flag
🇲 Method --> ( JsonFlagId )
set_flag_recursive
🇲 Method --> ( JsonFlagId )
set_melee_damage_bonus
🇲 Method --> ( DamageInstance )
set_melee_hit_bonus
🇲 Method --> ( integer )
set_owner
🇲 Method --> ( FactionId )
Sets the ownership of this item to a faction
set_owner
🇲 Method --> ( Character )
Sets the ownership of this item to a character
set_range_bonus
🇲 Method --> ( integer )
set_ranged_damage_bonus
🇲 Method --> ( DamageInstance )
set_recoil_bonus
🇲 Method --> ( integer )
set_var_num
🇲 Method --> ( string, number )
set_var_str
🇲 Method --> ( string, string )
set_var_tri
🇲 Method --> ( string, Tripoint )
spawn
🇫 Function --> ( ItypeId, integer ) -> Detached<Item>
Spawns a new item. Same as gapi.create_item
stamina_cost
🇲 Method --> ( ) -> integer
tname
🇲 Method --> ( integer, boolean, integer ) -> string
Translated item name with prefixes
total_capacity
🇲 Method --> ( ) -> Volume
Gets maximum volume this item can hold (liquids, ammo, etc)
unset_flag
🇲 Method --> ( JsonFlagId )
unset_flags
🇲 Method --> ( )
vars_table
🇲 Method --> ( ) -> table
Returns all stored item vars as a table
volume
🇲 Method --> ( boolean? ) -> Volume
Volumeof the item.boolis whether it isintegral_volume.
weight
🇲 Method --> ( boolean?, boolean? ) -> Mass
Weight of the item. The first
boolis whether including contents, secondboolis whether it isintegral_weight.
ItemStack
Iterate over this using pairs() for reading. Can also be indexed.
Bases
No base classes.
Constructors
No constructors.
Members
amount_can_fit
🇲 Method --> ( Item ) -> integer
clear
🇲 Method --> ( ) -> Detached<Item>[]
count
🇲 Method --> ( ) -> integer
count_limit
🇲 Method --> ( ) -> integer
free_volume
🇲 Method --> ( ) -> Volume
insert
🇲 Method --> ( Detached<Item> )
items
🇲 Method --> ( ) -> Item[]
Modifying the stack while iterating may cause problems. This returns a frozen copy of the items in the stack for safe modification of the stack (eg. removing items while iterating).
max_volume
🇲 Method --> ( ) -> Volume
move_all_to
🇲 Method --> ( ItemStack )
only_item
🇲 Method --> ( ) -> Item
remove
🇲 Method --> ( Item ) -> Detached<Item>
stacks_with
stored_volume
🇲 Method --> ( ) -> Volume
ItypeId
Bases
No base classes.
Constructors
- ItypeId.new( )
- ItypeId.new( ItypeId )
- ItypeId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> ItypeId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> ItypeRaw
str
🇲 Method --> ( ) -> string
ItypeRaw
Slots for various item type properties. Each slot may contain a valid value or nil
Bases
No base classes.
Constructors
No constructors.
Members
attacks
🇻 Variable --> table<string, CppVal<attack_statblock>>
countdown_destroy
🇻 Variable --> boolean
countdown_interval
🇻 Variable --> integer
default_container
🇻 Variable --> ItypeId?
emits
🇻 Variable --> FieldEmitId[]
explode_in_fire
🇻 Variable --> boolean
explosion_data
🇻 Variable --> ExplosionData
faults
🇻 Variable --> FaultId[]
integral_volume
🇻 Variable --> Volume
integral_weight
🇻 Variable --> Mass
item_tags
🇻 Variable --> JsonFlagId[]
layer
🇻 Variable --> CppVal<layer_level>
light_emission
🇻 Variable --> integer
looks_like
🇻 Variable --> ItypeId
materials
🇻 Variable --> MaterialTypeId[]
melee_to_hit
🇻 Variable --> integer
min_dex
🇻 Variable --> integer
min_int
🇻 Variable --> integer
min_per
🇻 Variable --> integer
min_skills
🇻 Variable --> table<SkillId, integer>
min_str
🇻 Variable --> integer
phase
🇻 Variable --> Phase
properties
🇻 Variable --> table<string, string>
qualities
🇻 Variable --> table<QualityId, integer>
recipes
🇻 Variable --> RecipeId[]
repair
🇻 Variable --> ItypeId[]
repairs_like
🇻 Variable --> ItypeId
rigid
🇻 Variable --> boolean
stack_size
🇻 Variable --> integer
techniques
🇻 Variable --> MartialArtsTechniqueId[]
thrown_damage
🇻 Variable --> DamageInstance
volume
🇻 Variable --> Volume
weapon_category
🇻 Variable --> WeaponCategoryId[]
weight
🇻 Variable --> Mass
can_have_charges
🇲 Method --> ( ) -> boolean
can_use
🇲 Method --> ( string ) -> boolean
charge_factor
🇲 Method --> ( ) -> integer
charges_default
🇲 Method --> ( ) -> integer
charges_per_volume
🇲 Method --> ( Volume ) -> integer
charges_to_use
🇲 Method --> ( ) -> integer
damage_max
🇲 Method --> ( ) -> integer
damage_min
🇲 Method --> ( ) -> integer
get_countdown_action
🇲 Method --> ( ) -> string
get_description
🇲 Method --> ( integer ) -> string
get_drop_action
🇲 Method --> ( ) -> string
get_flags
🇲 Method --> ( ) -> JsonFlagId[]
get_name
🇲 Method --> ( integer ) -> string
get_uses
🇲 Method --> ( ) -> string[]
has_flag
🇲 Method --> ( JsonFlagId ) -> boolean
has_use
🇲 Method --> ( ) -> boolean
is_stackable
🇲 Method --> ( ) -> boolean
maximum_charges
🇲 Method --> ( ) -> integer
price
🇲 Method --> ( ) -> integer
price_post
🇲 Method --> ( ) -> integer
slot_ammo
🇲 Method --> ( ) -> IslotAmmo
slot_armor
🇲 Method --> ( ) -> IslotArmor
slot_artifact
🇲 Method --> ( ) -> IslotArtifact
slot_battery
🇲 Method --> ( ) -> IslotBattery
slot_bionic
🇲 Method --> ( ) -> IslotBionic
slot_book
🇲 Method --> ( ) -> IslotBook
slot_brewable
🇲 Method --> ( ) -> IslotBrewable
slot_comestible
🇲 Method --> ( ) -> IslotComestible
slot_container
🇲 Method --> ( ) -> IslotContainer
slot_engine
🇲 Method --> ( ) -> IslotEngine
slot_fuel
🇲 Method --> ( ) -> IslotFuel
slot_gun
🇲 Method --> ( ) -> IslotGun
slot_gunmod
🇲 Method --> ( ) -> IslotGunmod
slot_magazine
🇲 Method --> ( ) -> IslotMagazine
slot_milling
🇲 Method --> ( ) -> IslotMilling
slot_mod
🇲 Method --> ( ) -> IslotMod
slot_pet_armor
🇲 Method --> ( ) -> IslotPetArmor
slot_relic
🇲 Method --> ( ) -> Relic
slot_seed
🇲 Method --> ( ) -> IslotSeed
slot_tool
🇲 Method --> ( ) -> IslotTool
slot_wheel
🇲 Method --> ( ) -> IslotWheel
source_mod
🇲 Method --> ( ) -> ModInfoId[]
type_id
🇲 Method --> ( ) -> ItypeId
JsonFlagId
Bases
No base classes.
Constructors
- JsonFlagId.new( )
- JsonFlagId.new( JsonFlagId )
- JsonFlagId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> JsonFlagId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> JsonFlagRaw
str
🇲 Method --> ( ) -> string
JsonTraitFlagId
Bases
No base classes.
Constructors
- JsonTraitFlagId.new( )
- JsonTraitFlagId.new( JsonTraitFlagId )
- JsonTraitFlagId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> JsonTraitFlagId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> JsonTraitFlagRaw
str
🇲 Method --> ( ) -> string
KnownMagic
Represents a character's spellbook and mana pool. Manages all spells known by a character, their mana, and spell learning/forgetting.
Bases
No base classes.
Constructors
No constructors.
Members
casting_ignore
🇻 Variable --> boolean
Whether casting ignores all distractions. Can be read and written.
available_mana
🇲 Method --> ( ) -> integer
Get the current available mana.
can_learn_spell
🇲 Method --> ( Character, SpellTypeId ) -> boolean
Check if the character can learn a specific spell, considering traits and other restrictions.
forget_spell
🇲 Method --> ( SpellTypeId )
Forget a known spell by spell_id.
get_spell
🇲 Method --> ( SpellTypeId ) -> Spell
Get a reference to a known spell for editing. Returns the spell associated with the given spell_id.
get_spells
🇲 Method --> ( ) -> Spell[]
Get all known spells as a vector of spell pointers.
has_enough_energy
🇲 Method --> ( Character, Spell ) -> boolean
Check if the character has enough energy (of the appropriate type) to cast the given spell.
knows_spell
🇲 Method --> ( SpellTypeId ) -> boolean
🇲 Method --> ( ) -> boolean
Check if the character knows a specific spell by spell_id.
learn_spell
🇲 Method --> ( SpellTypeId, Character, boolean? )
Learn a new spell. Requires a
Characterreference and spell_id. Optional force(boolean) parameter bypasses restrictions.
mana_regen_rate
🇲 Method --> ( Character ) -> number
Get the mana regeneration rate in units per turn for the given character.
max_mana
🇲 Method --> ( Character ) -> integer
Get the maximum mana for the given character.
mod_mana
🇲 Method --> ( Character, integer )
Modify the current mana by adding or subtracting an amount.
set_mana
🇲 Method --> ( integer )
Set the current mana to a specific value.
spells
🇲 Method --> ( ) -> SpellTypeId[]
Get a vector of all known spell IDs.
time_to_learn_spell
🇲 Method --> ( Character, SpellTypeId ) -> integer
Calculate the time in moves required for the character to memorize/learn a spell.
Map
Bases
No base classes.
Constructors
No constructors.
Members
abs_to_bub
🇲 Method --> ( TripointAbsMs ) -> TripointBubMs
🇲 Method --> ( TripointAbsSm ) -> TripointBubSm
Convert absolute coordinates to bubble coordinates.
add_field_at
🇲 Method --> ( TripointBubMs, FieldTypeIntId, integer, TimeDuration ) -> boolean
add_item
🇲 Method --> ( TripointBubMs, Detached<Item> ) -> Detached<Item>
🇲 Method --> ( Tripoint, Detached<Item> ) -> Detached<Item>
Places a detached item onto the map. Returns nil on success (item now owned by map), or returns the item back if placement failed.
ambient_light_at
🇲 Method --> ( TripointBubMs ) -> number
bub_to_abs
🇲 Method --> ( TripointBubMs ) -> TripointAbsMs
🇲 Method --> ( TripointBubSm ) -> TripointAbsSm
Convert bubble coordinates to absolute coordinates.
clear_items_at
🇲 Method --> ( TripointBubMs )
🇲 Method --> ( Tripoint )
create_corpse_at
🇲 Method --> ( TripointBubMs, MonsterTypeId?, TimePoint?, string?, integer? )
Creates a new corpse at a position on the map. You can skip
Optones by omitting them or passingnil.MtypeIdspecifies which monster's body it is,<code>[TimePoint](#sol::TimePoint)</code>indicates when it died,stringgives it a custom name, andintdetermines the revival time if the monster has theREVIVESflag.
create_item_at
🇲 Method --> ( TripointBubMs, ItypeId, integer )
Creates a new item(s) at a position on the map. Returns nil. Use gapi.create_item and
Map:add_item to modify before placement.
destroy
🇲 Method --> ( TripointBubMs )
detach_item_at
🇲 Method --> ( TripointBubMs, Item ) -> Detached<Item>
🇲 Method --> ( Tripoint, Item ) -> Detached<Item>
Removes an item from the map and returns it as a detached_ptr. The item is now owned by Lua - store it in a table to keep it alive, or let it be GC'd to destroy it. Use add_item to place it back on a map.
disarm_trap_at
🇲 Method --> ( TripointBubMs )
Disarms a trap using your skills and stats, with consequences depending on success or failure.
drain_vehicle_fuel_at
🇲 Method --> ( TripointBubMs, string, ItypeId, integer ) -> integer
Drains fuel charges from the vehicle when the position has a part with the given feature. Returns the charges drained.
draw_fill_background
🇲 Method --> ( string )
get_field_age_at
🇲 Method --> ( TripointBubMs, FieldTypeIntId ) -> TimeDuration
get_field_int_at
🇲 Method --> ( TripointBubMs, FieldTypeIntId ) -> integer
get_field_name_at
🇲 Method --> ( TripointBubMs, FieldTypeIntId ) -> string
get_furn_at
🇲 Method --> ( TripointBubMs ) -> FurnIntId
get_items_at
🇲 Method --> ( TripointBubMs ) -> MapStack
🇲 Method --> ( Tripoint ) -> MapStack
get_items_in_radius
🇲 Method --> ( TripointBubMs, integer ) -> MapStack[]
get_map_size
🇲 Method --> ( ) -> integer
In map squares
get_map_size_in_submaps
🇲 Method --> ( ) -> integer
get_temperature_c
🇲 Method --> ( TripointBubMs ) -> number
Get the local ambient temperature in degrees Celsius at a map-square position.
get_ter_at
🇲 Method --> ( TripointBubMs ) -> TerIntId
get_trap_at
🇲 Method --> ( TripointBubMs ) -> TrapIntId
get_vehicle_fuel_left_at
🇲 Method --> ( TripointBubMs, string, ItypeId, boolean? ) -> integer
Returns the vehicle's available fuel charges when the position has a part with the given feature.
get_vehicles
🇲 Method --> ( ) -> WrappedVehicle[]
Returns every vehicle currently on the map.
has_field_at
🇲 Method --> ( TripointBubMs, FieldTypeIntId ) -> boolean
has_flag_at
🇲 Method --> ( string, TripointBubMs ) -> boolean
has_furn_flag_at
🇲 Method --> ( string, TripointBubMs ) -> boolean
has_items_at
🇲 Method --> ( TripointBubMs ) -> boolean
🇲 Method --> ( Tripoint ) -> boolean
has_ter_flag_at
🇲 Method --> ( string, TripointBubMs ) -> boolean
has_vehicle_part_with_feature_at
🇲 Method --> ( TripointBubMs, string, boolean? ) -> boolean
Returns whether a vehicle at this position has an available part with the given feature.
is_in_sunlight
🇲 Method --> ( TripointBubMs ) -> boolean
is_ot_match
🇫 Function --> ( string, OterIntId, OtMatchType ) -> boolean
is_outside
🇲 Method --> ( TripointBubMs ) -> boolean
is_sheltered
🇲 Method --> ( TripointBubMs ) -> boolean
make_rubble
🇲 Method --> ( TripointBubMs, FurnIntId, TerIntId )
mod_field_age_at
🇲 Method --> ( TripointBubMs, FieldTypeIntId, TimeDuration ) -> TimeDuration
mod_field_int_at
🇲 Method --> ( TripointBubMs, FieldTypeIntId, integer ) -> integer
move_item_to
🇲 Method --> ( TripointBubMs, Item, TripointBubMs )
Moves an item from one position to another, preserving all item state including contents.
place_items
🇲 Method --> ( string, integer, PointBubMs, PointBubMs, boolean )
place_npc
🇲 Method --> ( PointBubMs, string ) -> Npc
Forcibly places an npc using a template at a position on the map. Returns the npc.
place_spawns
🇲 Method --> ( string, integer, PointBubMs, PointBubMs, number, boolean )
points_in_radius
🇲 Method --> ( TripointBubMs, integer, integer? ) -> TripointBubMs[]
Returns all points within a radius from the center point.
radiuszdefaults to 0.
remove_field_at
🇲 Method --> ( TripointBubMs, FieldTypeIntId )
remove_item_at
🇲 Method --> ( TripointBubMs, Item )
🇲 Method --> ( Tripoint, Item )
remove_trap_at
🇲 Method --> ( TripointBubMs )
Simpler version of
set_trap_atwithtrap_null.
replace_vehicle
🇲 Method --> ( WrappedVehicle, string, table? ) -> boolean
🇲 Method --> ( TripointBubMs, string, table? ) -> boolean
Replaces a specific vehicle with a different prototype, preserving origin tile by default. Pass an optional table with
orientation(Angleor degrees),status, andlocksto override spawn settings.
rotate
🇲 Method --> ( integer )
set_field_age_at
🇲 Method --> ( TripointBubMs, FieldTypeIntId, TimeDuration, boolean ) -> TimeDuration
set_field_int_at
🇲 Method --> ( TripointBubMs, FieldTypeIntId, integer, boolean ) -> integer
set_furn_at
🇲 Method --> ( TripointBubMs, FurnIntId )
set_temperature
🇲 Method --> ( TripointBubMs, integer )
set_ter_at
🇲 Method --> ( TripointBubMs, TerIntId ) -> boolean
set_trap_at
🇲 Method --> ( TripointBubMs, TrapIntId )
Set a trap at a position on the map. It can also replace existing trap, even with
trap_null.
spawn_artifact_at
🇲 Method --> ( TripointBubMs )
Spawns a random artifact at a position on the map.
spawn_natural_artifact_at
🇲 Method --> ( TripointBubMs, string? )
Spawns a natural artifact at a position on the map. Omit
propertyto choose one at random.
MapStack
Bases
ItemStack
Constructors
No constructors.
Members
as_item_stack
🇲 Method --> ( ) -> ItemStack
MapgenData
Bases
No base classes.
Constructors
No constructors.
Members
above
🇲 Method --> ( ) -> OterIntId
Gets the oter id to the above.
below
🇲 Method --> ( ) -> OterIntId
Gets the oter id to the below.
east
🇲 Method --> ( ) -> OterIntId
Gets the oter id to the east.
fill_groundcover
🇲 Method --> ( )
Fills the ground with default terrain.
generate
🇲 Method --> ( string )
Generates Normal Mapgen
get_nesw
🇲 Method --> ( integer ) -> OterIntId
Returns t_nesw at index i
get_rot_suffix
🇲 Method --> ( ) -> string
Gets rotation string
get_rotation
🇲 Method --> ( ) -> integer
Gets rotation
id
🇲 Method --> ( ) -> OterIntId
Gets it's oter id.
neast
🇲 Method --> ( ) -> OterIntId
Gets the oter id to the neast.
nest
🇲 Method --> ( string, PointRelMs )
Generates Nested Mapgen
north
🇲 Method --> ( ) -> OterIntId
Gets the oter id to the north.
nwest
🇲 Method --> ( ) -> OterIntId
Gets the oter id to the nwest.
seast
🇲 Method --> ( ) -> OterIntId
Gets the oter id to the seast.
set_dir
🇲 Method --> ( integer, integer )
Sets the direction of the mapgen.
south
🇲 Method --> ( ) -> OterIntId
Gets the oter id to the south.
swest
🇲 Method --> ( ) -> OterIntId
Gets the oter id to the swest.
west
🇲 Method --> ( ) -> OterIntId
Gets the oter id to the west.
zlevel
🇲 Method --> ( ) -> integer
Gets the z-level that it is generated at.
MartialArtsBuffId
Bases
No base classes.
Constructors
- MartialArtsBuffId.new( )
- MartialArtsBuffId.new( MartialArtsBuffId )
- MartialArtsBuffId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> MartialArtsBuffId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> MartialArtsBuffRaw
str
🇲 Method --> ( ) -> string
MartialArtsId
Bases
No base classes.
Constructors
- MartialArtsId.new( )
- MartialArtsId.new( MartialArtsId )
- MartialArtsId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> MartialArtsId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> MartialArtsRaw
str
🇲 Method --> ( ) -> string
MartialArtsTechniqueId
Bases
No base classes.
Constructors
- MartialArtsTechniqueId.new( )
- MartialArtsTechniqueId.new( MartialArtsTechniqueId )
- MartialArtsTechniqueId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> MartialArtsTechniqueId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> MartialArtsTechniqueRaw
str
🇲 Method --> ( ) -> string
MartialArtsTechniqueRaw
Bases
No base classes.
Constructors
No constructors.
Members
avatar_message
🇻 Variable --> string
block_counter
🇻 Variable --> boolean
crit_ok
🇻 Variable --> boolean
crit_tec
🇻 Variable --> boolean
defensive
🇻 Variable --> boolean
disarms
🇻 Variable --> boolean
dodge_counter
🇻 Variable --> boolean
down_dur
🇻 Variable --> integer
force_unarmed
🇻 Variable --> boolean
grab_break
🇻 Variable --> boolean
knockback_dist
🇻 Variable --> integer
knockback_follow
🇻 Variable --> boolean
knockback_spread
🇻 Variable --> number
miss_recovery
🇻 Variable --> boolean
name
🇻 Variable --> string
npc_message
🇻 Variable --> string
powerful_knockback
🇻 Variable --> boolean
side_switch
🇻 Variable --> boolean
stun_dur
🇻 Variable --> integer
take_weapon
🇻 Variable --> boolean
get_description
🇲 Method --> ( ) -> string
Mass
Bases
No base classes.
Constructors
No constructors.
Members
from_gram
🇫 Function --> ( integer ) -> Mass
from_kilogram
🇫 Function --> ( integer ) -> Mass
from_milligram
🇫 Function --> ( integer ) -> Mass
from_newton
🇫 Function --> ( integer ) -> Mass
to_gram
🇲 Method --> ( ) -> integer
to_kilogram
🇲 Method --> ( ) -> integer
to_milligram
🇲 Method --> ( ) -> integer
to_newton
🇲 Method --> ( ) -> integer
MaterialTypeId
Bases
No base classes.
Constructors
- MaterialTypeId.new( )
- MaterialTypeId.new( MaterialTypeId )
- MaterialTypeId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> MaterialTypeId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> MaterialTypeRaw
str
🇲 Method --> ( ) -> string
MaterialTypeRaw
Bases
No base classes.
Constructors
No constructors.
Members
name
🇲 Method --> ( ) -> string
str_id
🇲 Method --> ( ) -> MaterialTypeId
Mission
Bases
No base classes.
Constructors
- Mission.new( )
Members
assign
🇲 Method --> ( Avatar )
Assigns this mission to the given avatar.
fail
🇲 Method --> ( )
Fails the mission.
get_deadline
🇲 Method --> ( ) -> TimePoint
Returns the mission's deadline as a time_point.
get_description
🇲 Method --> ( ) -> string
Returns the mission description.
get_follow_up
🇲 Method --> ( ) -> MissionTypeIdRaw
Returns the follow-up mission type ID.
get_id
🇲 Method --> ( ) -> integer
Returns the mission's unique ID.
get_item_id
🇲 Method --> ( ) -> ItypeId
Returns the item ID associated with the mission.
get_likely_rewards
🇲 Method --> ( ) -> (integer, ItypeId)[]
Returns the likely rewards of the mission (vector of (int chance, itype_id) pairs).
get_npc_id
🇲 Method --> ( ) -> CharacterId
Returns the NPC character ID associated with the mission.
get_target_point
🇲 Method --> ( ) -> TripointAbsOmt
Returns the target of the mission as absolute overmap terrain coordinates.
get_type
🇲 Method --> ( ) -> MissionType
Returns the mission type of the target (pointer to mission_type).
get_value
🇲 Method --> ( ) -> integer
Returns the mission's value as an integer.
has_deadline
🇲 Method --> ( ) -> boolean
Returns true if the mission has a deadline.
has_failed
🇲 Method --> ( ) -> boolean
Returns true if the mission has failed.
has_follow_up
🇲 Method --> ( ) -> boolean
Returns true if the mission has a follow-up mission.
has_generic_rewards
🇲 Method --> ( ) -> boolean
Returns true if the mission has generic rewards.
has_target
🇲 Method --> ( ) -> boolean
Returns true if the mission has a target.
in_progress
🇲 Method --> ( ) -> boolean
Returns true if the mission is currently in progress.
is_assigned
🇲 Method --> ( ) -> boolean
Returns true if the mission is currently assigned.
is_complete
🇲 Method --> ( CharacterId? ) -> boolean
Returns true if the mission goal has been completed (optionally checked against given NPC ID).
mission_id
🇲 Method --> ( ) -> MissionTypeIdRaw
Returns the mission type ID of this mission.
name
🇲 Method --> ( ) -> string
Returns the mission's name as a string.
reserve_new
🇫 Function --> ( MissionTypeIdRaw, CharacterId ) -> Mission
Reserves a new mission of the given type for the specified NPC. Returns the new mission.
reserve_random
🇫 Function --> ( MissionOrigin, TripointAbsOmt, CharacterId ) -> Mission
Reserves a random mission at the specified origin and position for the given NPC. Returns the new mission.
step_complete
🇲 Method --> ( integer )
Marks a mission step as complete, taking an integer step index.
wrap_up
🇲 Method --> ( )
Wraps up the mission successfully.
MissionType
Bases
No base classes.
Constructors
- MissionType.new( )
Members
deadline_high
🇻 Variable --> TimeDuration
Returns the maximum allowed deadline for the mission.
deadline_low
🇻 Variable --> TimeDuration
Returns the minimum allowed deadline for the mission.
description
🇻 Variable --> CppVal<translation>
Returns the mission's description as a string.
dialogue
🇻 Variable --> table<string, CppVal<translation>>
Returns any associated dialogue for the mission.
difficulty
🇻 Variable --> integer
Returns the mission's difficulty as an integer.
empty_container
🇻 Variable --> ItypeId
Returns true if the mission requires the container to be empty.
follow_up
🇻 Variable --> MissionTypeIdRaw
Returns any follow-up mission type ID.
goal
🇻 Variable --> MissionGoal
Returns the mission's goal text.
has_generic_rewards
🇻 Variable --> boolean
Returns true if the mission has generic rewards.
item_count
🇻 Variable --> integer
Returns the count of items involved in the mission.
item_id
🇻 Variable --> ItypeId
Returns the ID of the mission's main item target, if applicable.
likely_rewards
🇻 Variable --> (integer, ItypeId)[]
Returns a vector of likely rewards (chance, itype_id pairs).
monster_kill_goal
🇻 Variable --> integer
Returns the number of monsters required to kill for this mission.
monster_type
🇻 Variable --> MonsterTypeId
Returns the monster type associated with the mission, if any.
origins
🇻 Variable --> MissionOrigin[]
Returns a list of origins from which this mission can be generated.
remove_container
🇻 Variable --> boolean
Returns true if the mission requires removing a container.
target_npc_id
🇻 Variable --> CharacterId
Returns the ID of the target NPC for the mission, if any.
urgent
🇻 Variable --> boolean
Returns true if the mission is marked as urgent.
value
🇻 Variable --> integer
Returns the mission's reward value as an integer.
get_all
🇫 Function --> ( ) -> MissionType[]
Returns all available missions.
get_random_mission_id
🇫 Function --> ( MissionOrigin, TripointAbsOmt ) -> MissionTypeIdRaw
Returns a random mission type ID at the specified origin and overmap tile position.
tname
🇲 Method --> ( ) -> string
MissionTypeIdRaw
Bases
No base classes.
Constructors
- MissionTypeIdRaw.new( string )
Members
No members.
ModInfoId
Bases
No base classes.
Constructors
- ModInfoId.new( )
- ModInfoId.new( ModInfoId )
- ModInfoId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> ModInfoId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> ModInfoRaw
str
🇲 Method --> ( ) -> string
Mongroup
Bases
No base classes.
Constructors
No constructors.
Members
diffuse
🇻 Variable --> boolean
horde
🇻 Variable --> boolean
horde_behaviour
🇻 Variable --> string
interest
🇻 Variable --> integer
population
🇻 Variable --> integer
radius
🇻 Variable --> integer
type
🇻 Variable --> MonsterGroupId
abs_pos
🇲 Method --> ( ) -> TripointAbsSm
Get the group position in absolute submap coordinates.
avg_speed
🇲 Method --> ( ) -> number
Average movement speed of monsters in the group.
clear
🇲 Method --> ( )
Remove all monsters and clear population.
dec_interest
🇲 Method --> ( integer )
Decrease horde interest by the given amount (clamped 15..100).
inc_interest
🇲 Method --> ( integer )
Increase horde interest by the given amount (clamped 15..100).
is_empty
🇲 Method --> ( ) -> boolean
Check if the group has no members or population.
is_safe
🇲 Method --> ( ) -> boolean
Check if the group is safe.
monsters
🇲 Method --> ( ) -> Monster[]
Get individual monster instances tracked inside the horde (if any).
nemesis_target
🇲 Method --> ( ) -> TripointAbsSm
Get the nemesis target for this group.
set_interest
🇲 Method --> ( integer )
Set horde interest directly (clamped 15..100).
set_nemesis_target
🇲 Method --> ( TripointAbsSm )
Set the nemesis target for this group using absolute submap coordinates.
set_pos
🇲 Method --> ( TripointAbsSm )
Set the group position in absolute submap coordinates.
set_target
🇲 Method --> ( TripointAbsSm )
Set the current target in absolute submap coordinates.
target
🇲 Method --> ( ) -> TripointAbsSm
Get the current target in absolute submap coordinates.
Monster
Bases
Creature
Constructors
No constructors.
Members
anger
🇻 Variable --> integer
death_drops
🇻 Variable --> boolean
faction
🇻 Variable --> MonsterFactionIntId
friendly
🇻 Variable --> integer
morale
🇻 Variable --> integer
unique_name
🇻 Variable --> string
add_detached_item
🇲 Method --> ( Detached<Item> )
add_faction_anger
🇲 Method --> ( string, integer )
add_item
🇲 Method --> ( Item )
attitude
🇲 Method --> ( Character ) -> MonsterAttitude
bash_at
🇲 Method --> ( TripointBubMs ) -> boolean
🇲 Method --> ( Tripoint ) -> boolean
can_climb
🇲 Method --> ( ) -> boolean
can_dig
🇲 Method --> ( ) -> boolean
can_drown
🇲 Method --> ( ) -> boolean
can_hear
🇲 Method --> ( ) -> boolean
can_see
🇲 Method --> ( ) -> boolean
can_submerge
🇲 Method --> ( ) -> boolean
can_upgrade
🇲 Method --> ( ) -> boolean
clear_items
🇲 Method --> ( ) -> Detached<Item>[]
clear_move_target
🇲 Method --> ( )
climbs
🇲 Method --> ( ) -> boolean
digs
🇲 Method --> ( ) -> boolean
drop_items
🇲 Method --> ( TripointBubMs )
drop_items_here
🇲 Method --> ( )
flies
🇲 Method --> ( ) -> boolean
get_faction_anger
🇲 Method --> ( string ) -> integer
get_items
🇲 Method --> ( ) -> Item[]
get_type
🇲 Method --> ( ) -> MonsterTypeId
get_upgrade_time
🇲 Method --> ( ) -> integer
hasten_upgrade
🇲 Method --> ( )
heal
🇲 Method --> ( integer, boolean ) -> integer
is_wandering
🇲 Method --> ( ) -> boolean
make_ally
🇲 Method --> ( Monster )
make_friendly
🇲 Method --> ( )
make_fungus
🇲 Method --> ( ) -> boolean
make_pet
🇲 Method --> ( )
move_target
🇲 Method --> ( ) -> TripointBubMs
move_to
🇲 Method --> ( TripointBubMs, boolean, boolean, number ) -> boolean
🇲 Method --> ( Tripoint, boolean, boolean, number ) -> boolean
name
🇲 Method --> ( integer ) -> string
name_with_armor
🇲 Method --> ( ) -> string
refill_udders
🇲 Method --> ( )
remove_item
🇲 Method --> ( Item ) -> Detached<Item>
run_normal_ai_turn
🇲 Method --> ( )
set_attitude
🇲 Method --> ( MonsterAttitude )
set_hp
🇲 Method --> ( integer )
set_move_target
🇲 Method --> ( TripointBubMs )
🇲 Method --> ( Tripoint )
set_target
🇲 Method --> ( Creature )
spawn
🇲 Method --> ( TripointBubMs )
swims
🇲 Method --> ( ) -> boolean
try_reproduce
🇲 Method --> ( )
try_upgrade
🇲 Method --> ( boolean )
wander_to
🇲 Method --> ( TripointBubMs, integer )
MonsterFactionId
Bases
No base classes.
Constructors
- MonsterFactionId.new( )
- MonsterFactionId.new( MonsterFactionId )
- MonsterFactionId.new( MonsterFactionIntId )
- MonsterFactionId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> MonsterFactionId
implements_int_id
🇫 Function --> ( ) -> boolean
int_id
🇲 Method --> ( ) -> MonsterFactionIntId
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> MonsterFactionRaw
str
🇲 Method --> ( ) -> string
MonsterFactionIntId
Bases
No base classes.
Constructors
- MonsterFactionIntId.new( )
- MonsterFactionIntId.new( MonsterFactionIntId )
- MonsterFactionIntId.new( MonsterFactionId )
Members
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> MonsterFactionRaw
str_id
🇲 Method --> ( ) -> MonsterFactionId
MonsterGroupEntry
Bases
No base classes.
Constructors
No constructors.
Members
conditions
🇻 Variable --> string[]
cost_multiplier
🇻 Variable --> integer
ends
🇻 Variable --> TimeDuration
frequency
🇻 Variable --> integer
name
🇻 Variable --> MonsterTypeId
pack_maximum
🇻 Variable --> integer
pack_minimum
🇻 Variable --> integer
starts
🇻 Variable --> TimeDuration
lasts_forever
🇲 Method --> ( ) -> boolean
MonsterGroupId
Bases
No base classes.
Constructors
- MonsterGroupId.new( )
- MonsterGroupId.new( MonsterGroupId )
- MonsterGroupId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> MonsterGroupId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> MonsterGroupRaw
str
🇲 Method --> ( ) -> string
MonsterGroupRaw
Bases
No base classes.
Constructors
No constructors.
Members
defaultMonster
🇻 Variable --> MonsterTypeId
freq_total
🇻 Variable --> integer
is_animal
🇻 Variable --> boolean
is_safe
🇻 Variable --> boolean
monster_group_time
🇻 Variable --> TimeDuration
monsters
🇻 Variable --> MonsterGroupEntry[]
name
🇻 Variable --> MonsterGroupId
new_monster_group
🇻 Variable --> MonsterGroupId
replace_monster_group
🇻 Variable --> boolean
contains
🇲 Method --> ( MonsterTypeId ) -> boolean
Check if a monster type appears in this group.
MonsterTypeId
Bases
No base classes.
Constructors
- MonsterTypeId.new( )
- MonsterTypeId.new( MonsterTypeId )
- MonsterTypeId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> MonsterTypeId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> MonsterTypeRaw
str
🇲 Method --> ( ) -> string
MonsterTypeRaw
Bases
No base classes.
Constructors
No constructors.
Members
difficulty
🇻 Variable --> integer
difficulty_base
🇻 Variable --> integer
id
🇻 Variable --> MonsterTypeId
nname
🇲 Method --> ( integer ) -> string
MoraleTypeDataId
Bases
No base classes.
Constructors
- MoraleTypeDataId.new( )
- MoraleTypeDataId.new( MoraleTypeDataId )
- MoraleTypeDataId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> MoraleTypeDataId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> MoraleTypeDataRaw
str
🇲 Method --> ( ) -> string
MutationBranchId
Bases
No base classes.
Constructors
- MutationBranchId.new( )
- MutationBranchId.new( MutationBranchId )
- MutationBranchId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> MutationBranchId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> MutationBranchRaw
str
🇲 Method --> ( ) -> string
MutationBranchRaw
Bases
No base classes.
Constructors
No constructors.
Members
activated
🇻 Variable --> boolean
Whether this mutation can be activated at will.
allow_soft_gear
🇻 Variable --> boolean
Mutation allows soft gear to be worn over otherwise-restricted parts.
attackcost_modifier
🇻 Variable --> number
bleed_resist
🇻 Variable --> number
bodytemp_max_btu
🇻 Variable --> integer
bodytemp_min_btu
🇻 Variable --> integer
bodytemp_sleep_btu
🇻 Variable --> integer
construction_speed_modifier
🇻 Variable --> number
Construction speed multiplier. 2.0 doubles construction speed; 0.5 halves it.
cooldown
🇻 Variable --> integer
Costs are incurred every 'cooldown' turns.
cost
🇻 Variable --> integer
crafting_speed_modifier
🇻 Variable --> number
Crafting speed multiplier. 2.0 doubles crafting speed; 0.5 halves it.
debug
🇻 Variable --> boolean
Whether or not this mutation is limited to debug use.
dodge_modifier
🇻 Variable --> number
falling_damage_multiplier
🇻 Variable --> number
fatigue
🇻 Variable --> boolean
Mutation causes fatigue when used.
fatigue_modifier
🇻 Variable --> number
fatigue_regen_modifier
🇻 Variable --> number
healing_awake
🇻 Variable --> number
Healing per turn from mutation.
healing_resting
🇻 Variable --> number
Healing per turn from mutation, while asleep.
healthy_rate
🇻 Variable --> number
How quickly health (not HP) trends toward healthy_mod.
hearing_modifier
🇻 Variable --> number
hp_adjustment
🇻 Variable --> number
Flat adjustment to HP.
hp_modifier
🇻 Variable --> number
Bonus HP multiplier. 1.0 doubles HP; -0.5 halves it.
hp_modifier_secondary
🇻 Variable --> number
Secondary HP multiplier; stacks with the other one. 1.0 doubles HP; -0.5 halves it.
hunger
🇻 Variable --> boolean
Mutation deducts calories when used.
id
🇻 Variable --> MutationBranchId
local_detail_sight
🇻 Variable --> number
max_stamina_modifier
🇻 Variable --> number
mending_modifier
🇻 Variable --> number
Multiplier applied to broken limb regeneration. Normally 0.25; clamped to 0.25..1.0.
metabolism_modifier
🇻 Variable --> number
mixed_effect
🇻 Variable --> boolean
Whether this mutation has positive /and/ negative effects.
movecost_flatground_modifier
🇻 Variable --> number
movecost_modifier
🇻 Variable --> number
movecost_obstacle_modifier
🇻 Variable --> number
movecost_swim_modifier
🇻 Variable --> number
night_vision_range
🇻 Variable --> number
noise_modifier
🇻 Variable --> number
overmap_multiplier
🇻 Variable --> number
overmap_sight
🇻 Variable --> number
packmule_modifier
🇻 Variable --> number
Packmule multiplier. 2.0 doubles backpack/container volume; 0.5 halves it.
pain_recovery
🇻 Variable --> number
Pain recovery per turn from mutation.
player_display
🇻 Variable --> boolean
Whether or not this mutation shows up in the status (
@) menu.
points
🇻 Variable --> integer
Pointcost in character creation(?).
profession
🇻 Variable --> boolean
Whether this trait is ONLY gained through professional training/experience (and/or quests).
purifiable
🇻 Variable --> boolean
Whether this mutation is possible to remove through Purifier. False for 'special' mutations.
reading_speed_multiplier
🇻 Variable --> number
scent_modifier
🇻 Variable --> number
skill_rust_multiplier
🇻 Variable --> number
speed_modifier
🇻 Variable --> number
stamina_regen_modifier
🇻 Variable --> number
starting_trait
🇻 Variable --> boolean
Whether this trait can normally be taken during character generation.
starts_active
🇻 Variable --> boolean
Whether a mutation activates when granted.
stealth_modifier
🇻 Variable --> number
str_modifier
🇻 Variable --> number
Adjustment to Strength that doesn't affect HP.
temperature_speed_modifier
🇻 Variable --> number
thirst
🇻 Variable --> boolean
Mutation dehydrates when used.
thirst_modifier
🇻 Variable --> number
threshold
🇻 Variable --> boolean
Whether this is a Threshold mutation, and thus especially difficult to mutate. One per character.
ugliness
🇻 Variable --> integer
How physically unappealing the mutation is. Can be negative.
valid
🇻 Variable --> boolean
Whether this mutation is available through generic mutagen.
visibility
🇻 Variable --> integer
How visible the mutation is to others.
weight_capacity_modifier
🇻 Variable --> number
addition_mutations
🇲 Method --> ( ) -> MutationBranchId[]
categories
🇲 Method --> ( ) -> MutationCategoryTraitId[]
Lists the categories this mutation belongs to.
conflicts_with
🇲 Method --> ( ) -> MutationBranchId[]
Lists conflicting mutations.
desc
🇲 Method --> ( ) -> string
get_all
🇫 Function --> ( ) -> MutationBranchRaw[]
Returns a (long) list of every mutation in the game.
mutation_types
🇲 Method --> ( ) -> string[]
Lists the type(s) of this mutation. Mutations of a given type are mutually exclusive.
name
🇲 Method --> ( ) -> string
other_prerequisites
🇲 Method --> ( ) -> MutationBranchId[]
Lists the secondary mutation(s) needed to gain this mutation.
prerequisites
🇲 Method --> ( ) -> MutationBranchId[]
Lists the primary mutation(s) needed to gain this mutation.
replaced_by
🇲 Method --> ( ) -> MutationBranchId[]
Lists mutations that replace (e.g. evolve from) this one.
thresh_requirements
🇲 Method --> ( ) -> MutationBranchId[]
Lists the threshold mutation(s) required to gain this mutation.
MutationCategoryTraitId
Bases
No base classes.
Constructors
- MutationCategoryTraitId.new( )
- MutationCategoryTraitId.new( MutationCategoryTraitId )
- MutationCategoryTraitId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> MutationCategoryTraitId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> MutationCategoryTraitRaw
str
🇲 Method --> ( ) -> string
Npc
Bases
PlayerCharacterCreature
Constructors
No constructors.
Members
current_activity_id
🇻 Variable --> ActivityTypeId
hit_by_player
🇻 Variable --> boolean
marked_for_death
🇻 Variable --> boolean
needs
🇻 Variable --> NpcNeed[]
op_of_u
🇻 Variable --> NpcOpinion
patience
🇻 Variable --> integer
personality
🇻 Variable --> NpcPersonality
can_move_to
🇲 Method --> ( TripointBubMs, boolean ) -> boolean
can_open_door
🇲 Method --> ( TripointBubMs, boolean ) -> boolean
complain
🇲 Method --> ( ) -> boolean
Finds something to complain about and complains. Returns if complained.
complain_about
🇲 Method --> ( string, TimeDuration, string, boolean? ) -> boolean
Complain about an issue if enough time has passed. The first string is the issue identifier, with the second being the complaint text. The optional bool allows you to force a complaint without concern for the input time.
current_ally
🇲 Method --> ( ) -> Creature
Returns the npc's current ally, if it has one.
current_target
🇲 Method --> ( ) -> Creature
Returns the npc's current target as a creature, if it has one.
danger_assessment
🇲 Method --> ( ) -> number
Gets a value based on the npc's perspective of the area's danger.
evaluate_enemy
🇲 Method --> ( Creature ) -> number
Rates how dangerous a target is from 0 (harmless) to 1 (max danger).
follow_distance
🇲 Method --> ( ) -> integer
Gets the npc's follow distance. This can only be a few values, and is determined by npc rules.
get_attitude
🇲 Method --> ( ) -> NpcAttitude
get_first_topic
🇲 Method --> ( ) -> string
Returns the first topic of the npc's chatbin.
get_monster_faction
🇲 Method --> ( ) -> MonsterFactionIntId
Returns the npc's faction id. If it's part of a monster faction, it returns the id of the monster faction.
guaranteed_hostile
🇲 Method --> ( ) -> boolean
Returns true if the npc would be hostile to the player on sight regardless of their current attitude.
has_activity
🇲 Method --> ( ) -> boolean
has_omt_destination
🇲 Method --> ( ) -> boolean
has_player_activity
🇲 Method --> ( ) -> boolean
hostile_anger_level
🇲 Method --> ( ) -> integer
is_ally
🇲 Method --> ( Character ) -> boolean
is_enemy
🇲 Method --> ( ) -> boolean
is_following
🇲 Method --> ( ) -> boolean
is_friendly
🇲 Method --> ( Character ) -> boolean
is_guarding
🇲 Method --> ( ) -> boolean
is_leader
🇲 Method --> ( ) -> boolean
is_minion
🇲 Method --> ( ) -> boolean
Returns true if the npc is a player ally and their op_of_u.trust is >= 5.
is_obeying
🇲 Method --> ( Character ) -> boolean
is_patrolling
🇲 Method --> ( ) -> boolean
is_player_ally
🇲 Method --> ( ) -> boolean
is_simulated
🇲 Method --> ( ) -> boolean
True if this NPC is in a simulated (fully loaded, AI-eligible) submap.
is_stationary
🇲 Method --> ( boolean ) -> boolean
is_travelling
🇲 Method --> ( ) -> boolean
Returns true if the npc has the 'NPC_MISSION_TRAVELLING' mission.
is_walking_with
🇲 Method --> ( ) -> boolean
make_angry
🇲 Method --> ( )
move_to
🇲 Method --> ( TripointBubMs, boolean? )
Attempts to move the NPC to an adjacent map square.
mutiny
🇲 Method --> ( )
Causes the npc to leave your faction, incur various negative opinion maluses, and say explatives to the player.
npc_menu
🇲 Method --> ( boolean? )
Triggers the npc menu to open.
saw_player_recently
🇲 Method --> ( ) -> boolean
say
🇲 Method --> ( string )
Has the npc say the given string in the sidebar.
set_attitude
🇲 Method --> ( NpcAttitude )
set_faction_id
🇲 Method --> ( FactionId )
set_first_topic
🇲 Method --> ( string )
Sets the first topic of the npc's chatbin. Note that some circumstances may cause this to not be the first topic used, such as player allies.
set_move_target
🇲 Method --> ( TripointBubMs, boolean?, boolean? ) -> boolean
🇲 Method --> ( Tripoint, boolean?, boolean? ) -> boolean
smash_ability
🇲 Method --> ( ) -> integer
Gets the npc's blunt damage with their currently equipped weapon.
talk_to_u
🇲 Method --> ( string?, boolean? )
Causes the npc to talk to you. Passing a topic will force that topic to be used in place of all others, including code enforced topics such as 'TALK_STOLE_ITEM'.
turned_hostile
🇲 Method --> ( ) -> boolean
warn_about
🇲 Method --> ( string, TimeDuration, string, integer, TripointBubMs )
Wrapper for complain_about that warns about a specific type of threat, with different warnings for hostile or friendly NPCs and hostile NPCs always complaining.
NpcOpinion
Bases
No base classes.
Constructors
- NpcOpinion.new( )
- NpcOpinion.new( int, int, int, int, int )
Members
anger
🇻 Variable --> integer
fear
🇻 Variable --> integer
owed
🇻 Variable --> integer
trust
🇻 Variable --> integer
value
🇻 Variable --> integer
NpcPersonality
Bases
No base classes.
Constructors
- NpcPersonality.new( )
Members
aggression
🇻 Variable --> integer
altruism
🇻 Variable --> integer
bravery
🇻 Variable --> integer
collector
🇻 Variable --> integer
OmtFindParams
Bases
No base classes.
Constructors
- OmtFindParams.new( )
Members
exclude_types
🇻 Variable --> (string, OtMatchType)[]
Vector of (terrain_type, match_type) pairs to exclude from search.
existing_only
🇻 Variable --> boolean
If true, restricts search to existing overmaps only.
explored
🇻 Variable --> boolean?
If set, filters by terrain explored status (true = explored only, false = unexplored only).
max_results
🇻 Variable --> integer?
If set, limits the number of results returned.
seen
🇻 Variable --> boolean?
If set, filters by terrain seen status (true = seen only, false = unseen only).
types
🇻 Variable --> (string, OtMatchType)[]
Vector of (terrain_type, match_type) pairs to search for.
add_exclude_type
🇲 Method --> ( string, OtMatchType )
Helper method to add a terrain type to exclude from search.
add_type
🇲 Method --> ( string, OtMatchType )
Helper method to add a terrain type to search for.
set_search_layers
🇲 Method --> ( integer, integer )
Set the search layer range (z-levels).
set_search_range
🇲 Method --> ( integer, integer )
Set the search range in overmap tiles (min, max).
OterId
Bases
No base classes.
Constructors
Members
NULL_ID
🇫 Function --> ( ) -> OterId
implements_int_id
🇫 Function --> ( ) -> boolean
int_id
🇲 Method --> ( ) -> OterIntId
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> OterRaw
str
🇲 Method --> ( ) -> string
OterIntId
Bases
No base classes.
Constructors
Members
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> OterRaw
str_id
🇲 Method --> ( ) -> OterId
OvermapBuffer
Global overmap buffer that manages all overmap data
Bases
No base classes.
Constructors
No constructors.
Members
add_grid_connection
🇲 Method --> ( TripointAbsOmt, TripointAbsOmt ) -> boolean
Add an electric grid connection between two positions
electric_grid_at
🇲 Method --> ( TripointAbsOmt ) -> TripointAbsOmt[]
Get all overmap tiles belonging to the electric grid at the given position
electric_grid_connectivity_at
🇲 Method --> ( TripointAbsOmt ) -> TripointRelOmt[]
Get all electric grid connections from the given position
remove_grid_connection
🇲 Method --> ( TripointAbsOmt, TripointAbsOmt ) -> boolean
Remove an electric grid connection between two positions
Player
Bases
CharacterCreature
Constructors
No constructors.
Members
No members.
PlayerActivity
Bases
No base classes.
Constructors
No constructors.
Members
coords
🇻 Variable --> TripointAbsMs[]
interruptable_with_kb
🇻 Variable --> boolean
moves_left
🇻 Variable --> integer
moves_total
🇻 Variable --> integer
name
🇻 Variable --> string
id
🇲 Method --> ( ) -> ActivityTypeId
id_str
🇲 Method --> ( ) -> string
Point
Bases
No base classes.
Constructors
- Point.new( )
- Point.new( Point )
- Point.new( int, int )
Members
x
🇻 Variable --> integer
y
🇻 Variable --> integer
abs
🇲 Method --> ( ) -> Point
reinterpret_as
🇲 Method --> ( origin: string, scale: string ) -> PointCoord
Reinterpret this raw point as a typed point coordinate without changing x or y.
rotate
🇲 Method --> ( integer, Point ) -> Point
PointCoord
A typed two-dimensional coordinate. Its origin and scale describe how to interpret x and y, and coordinate operations only combine compatible coordinate spaces.
Bases
No base classes.
Constructors
No constructors.
Members
x
🇻 Variable --> integer
y
🇻 Variable --> integer
origin
🇲 Method --> ( ) -> string
project_combine
🇲 Method --> ( fine: any ) -> nil | PointCoord | TripointCoord
Combines this coarse point with a remainder from project_remain. Returns
PointCoordorTripointCoorddepending on the inputs, or nil if the pair is incompatible.
project_remain
🇲 Method --> ( scale: string ) -> (PointCoord?, PointCoord?)
Splits this point into a coarse
PointCoordat the requested scale and aPointCoordremainder at this point's original scale. Returns nil, nil if the split is not valid.
project_remain_mmr
🇲 Method --> ( ) -> (PointCoord?, PointCoord?)
Shortcut for
project_remain("mmr").
project_remain_om
🇲 Method --> ( ) -> (PointCoord?, PointCoord?)
Shortcut for
project_remain("om").
project_remain_omt
🇲 Method --> ( ) -> (PointCoord?, PointCoord?)
Shortcut for
project_remain("omt").
project_remain_seg
🇲 Method --> ( ) -> (PointCoord?, PointCoord?)
Shortcut for
project_remain("seg").
project_remain_sm
🇲 Method --> ( ) -> (PointCoord?, PointCoord?)
Shortcut for
project_remain("sm").
raw
🇲 Method --> ( ) -> Point
reinterpret_as
🇲 Method --> ( origin: string, scale: string ) -> PointCoord
Reinterpret this coordinate as another point coordinate kind without changing x or y.
rl_dist
🇲 Method --> ( other: PointCoord ) -> integer?
Rectilinear distance to another
PointCoordwith matching origin and scale. Returns nil if the argument is incompatible.
rotate
🇲 Method --> ( integer, Point ) -> PointCoord
scale
🇲 Method --> ( ) -> string
square_dist
🇲 Method --> ( other: PointCoord ) -> integer?
Chebyshev distance to another
PointCoordwith matching origin and scale. Returns nil if the argument is incompatible.
to
🇲 Method --> ( scale: string ) -> PointCoord?
Projects this coordinate to another scale, preserving its origin and point dimension. Returns nil if the conversion is not valid.
to_mmr
🇲 Method --> ( ) -> PointCoord?
Shortcut for
to("mmr").
to_ms
🇲 Method --> ( ) -> PointCoord?
Shortcut for
to("ms").
to_om
🇲 Method --> ( ) -> PointCoord?
Shortcut for
to("om").
to_omt
🇲 Method --> ( ) -> PointCoord?
Shortcut for
to("omt").
to_seg
🇲 Method --> ( ) -> PointCoord?
Shortcut for
to("seg").
to_sm
🇲 Method --> ( ) -> PointCoord?
Shortcut for
to("sm").
to_veh
🇲 Method --> ( ) -> PointCoord?
Shortcut for
to("veh").
trig_dist
🇲 Method --> ( other: PointCoord ) -> number?
Euclidean distance to another
PointCoordwith matching origin and scale. Returns nil if the argument is incompatible.
type
🇲 Method --> ( ) -> string
PopupInputStr
Bases
No base classes.
Constructors
- PopupInputStr.new( )
Members
desc
🇲 Method --> ( string )
descis above input field.
query_int
🇲 Method --> ( ) -> integer
Returns your input, but allows numbers only.
query_str
🇲 Method --> ( ) -> string
Returns your input.
title
🇲 Method --> ( string )
titleis on the left of input field.
PowerStat
Power generation and consumption statistics for a grid
Bases
No base classes.
Constructors
No constructors.
Members
gen_w
🇻 Variable --> integer
Power generation in watts
use_w
🇻 Variable --> integer
Power consumption in watts
net_w
🇲 Method --> ( ) -> integer
Net power (generation - consumption) in watts
QualityId
Bases
No base classes.
Constructors
- QualityId.new( )
- QualityId.new( QualityId )
- QualityId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> QualityId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> QualityRaw
str
🇲 Method --> ( ) -> string
QueryPopup
Bases
No base classes.
Constructors
- QueryPopup.new( )
Members
allow_any_key
🇲 Method --> ( boolean )
Set whether to allow any key
message
🇲 Method --> ( any )
message_color
🇲 Method --> ( Color )
query
🇲 Method --> ( ) -> string
Returns selected action
query_yn
🇲 Method --> ( ) -> string
Returns
YESorNO. If ESC pressed, returnsNO.
query_ynq
🇲 Method --> ( ) -> string
Returns
YES,NOorQUIT. If ESC pressed, returnsQUIT.
RangedData
Bases
No base classes.
Constructors
No constructors.
Members
aimed_crit_bonus
🇻 Variable --> number
aimed_crit_max_bonus
🇻 Variable --> number
damage
🇻 Variable --> DamageInstance
dispersion
🇻 Variable --> integer
range
🇻 Variable --> integer
speed
🇻 Variable --> integer
RecipeId
Bases
No base classes.
Constructors
- RecipeId.new( )
- RecipeId.new( RecipeId )
- RecipeId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> RecipeId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> RecipeRaw
str
🇲 Method --> ( ) -> string
RecipeRaw
Bases
No base classes.
Constructors
No constructors.
Members
booksets
🇻 Variable --> table<ItypeId, integer>
category
🇻 Variable --> string
difficulty
🇻 Variable --> integer
learn_by_disassembly
🇻 Variable --> table<SkillId, integer>
required_skills
🇻 Variable --> table<SkillId, integer>
skill_used
🇻 Variable --> SkillId
subcategory
🇻 Variable --> string
time
🇻 Variable --> integer
get_all
🇫 Function --> ( ) -> RecipeRaw[]
get_from_flag
🇫 Function --> ( string ) -> RecipeRaw[]
get_from_skill_used
🇫 Function --> ( SkillId ) -> RecipeRaw[]
has_flag
🇲 Method --> ( string ) -> boolean
recipe_id
🇲 Method --> ( ) -> RecipeId
result
🇲 Method --> ( ) -> ItypeId
result_name
🇲 Method --> ( boolean ) -> string
Relic
Bases
No base classes.
Constructors
No constructors.
Members
get_enchantments
🇲 Method --> ( ) -> CppVal<enchantment>[]
get_recharge_scheme
🇲 Method --> ( ) -> CppVal<relic_recharge>[]
get_spells
🇲 Method --> ( ) -> SpellSimple[]
name
🇲 Method --> ( ) -> string
RequirementData
Represents crafting requirements (tools, components, qualities)
Bases
No base classes.
Constructors
No constructors.
Members
can_make_with_inventory
🇲 Method --> ( Inventory ) -> boolean
Check if requirements can be made with given inventory
get_components
🇲 Method --> ( ) -> CppVal<item_comp>[][]
Get list of all required components
get_qualities
🇲 Method --> ( ) -> CppVal<quality_requirement>[][]
Get list of all required qualities
get_tools
🇲 Method --> ( ) -> CppVal<tool_comp>[][]
Get list of all required tools
id
🇲 Method --> ( ) -> string
Get the requirement ID as string
is_blacklisted
🇲 Method --> ( ) -> boolean
Check if this requirement is blacklisted
is_empty
🇲 Method --> ( ) -> boolean
Check if this requirement is empty
is_null
🇲 Method --> ( ) -> boolean
Check if this is a null requirement
list_all
🇲 Method --> ( ) -> string
Get a formatted list of all requirements
list_missing
🇲 Method --> ( ) -> string
Get a formatted list of missing requirements
Resistances
Bases
No base classes.
Constructors
No constructors.
Members
get_all_resist
🇲 Method --> ( ) -> table<DamageType, number>
get_effective_resist
🇲 Method --> ( DamageUnit ) -> number
get_resist
🇲 Method --> ( DamageType ) -> number
SkillId
Bases
No base classes.
Constructors
- SkillId.new( )
- SkillId.new( SkillId )
- SkillId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> SkillId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> SkillRaw
str
🇲 Method --> ( ) -> string
SkillLevel
Bases
No base classes.
Constructors
No constructors.
Members
can_train
🇲 Method --> ( ) -> boolean
highest_level
🇲 Method --> ( ) -> integer
is_training
🇲 Method --> ( ) -> boolean
level
🇲 Method --> ( ) -> integer
train
🇲 Method --> ( integer, boolean )
SkillLevelMap
Bases
Dict( SkillId, SkillLevel )
Constructors
No constructors.
Members
get_skill_level
🇲 Method --> ( SkillId ) -> integer
get_skill_level_object
🇲 Method --> ( SkillId ) -> SkillLevel
mod_skill_level
🇲 Method --> ( SkillId, integer )
SpeciesTypeId
Bases
No base classes.
Constructors
- SpeciesTypeId.new( )
- SpeciesTypeId.new( SpeciesTypeId )
- SpeciesTypeId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> SpeciesTypeId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> SpeciesTypeRaw
str
🇲 Method --> ( ) -> string
Spell
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
SpellSimpleinstead.
Bases
No base classes.
Constructors
- Spell.new( SpellTypeId, int )
Members
id
🇻 Variable --> SpellTypeId
cast
🇲 Method --> ( Creature, TripointBubMs )
Cast this spell, as well as any sub-spells.
cast_single_effect
🇲 Method --> ( Creature, TripointBubMs )
Cast only this spell's main effects. Generally, cast() should be used instead.
desc
🇲 Method --> ( ) -> string
gain_exp
🇲 Method --> ( integer )
gain_levels
🇲 Method --> ( integer )
get_level
🇲 Method --> ( ) -> integer
name
🇲 Method --> ( ) -> string
set_exp
🇲 Method --> ( integer )
set_level
🇲 Method --> ( integer )
xp
🇲 Method --> ( ) -> integer
SpellSimple
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
Spelltype.
Bases
No base classes.
Constructors
- SpellSimple.new( SpellTypeId, bool )
- SpellSimple.new( SpellTypeId, bool, int )
Members
force_target_source
🇻 Variable --> boolean
Whether or not the target point is locked to the source's location.
id
🇻 Variable --> SpellTypeId
level
🇻 Variable --> integer
trigger_once_in
🇻 Variable --> integer
Used for enchantments; the spell's chance to trigger every turn.
cast
🇲 Method --> ( Creature, TripointBubMs, integer? )
max_level
🇲 Method --> ( ) -> integer
Returns the defined maximum level of this
SpellSimpleinstance, if defined. Otherwise, returns 0.
prompt_cast
🇫 Function --> ( SpellTypeId, TripointBubMs, integer? ) -> 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.
SpellTypeId
Bases
No base classes.
Constructors
- SpellTypeId.new( )
- SpellTypeId.new( SpellTypeId )
- SpellTypeId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> SpellTypeId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> SpellTypeRaw
str
🇲 Method --> ( ) -> string
SpellTypeRaw
The 'raw' type for storing the information defining every spell in the game. It's not possible to cast directly from this type; check
SpellSimpleandSpell.
Bases
No base classes.
Constructors
No constructors.
Members
aoe_increment
🇻 Variable --> number
base_casting_time
🇻 Variable --> integer
base_energy_cost
🇻 Variable --> integer
casting_time_increment
🇻 Variable --> number
damage_increment
🇻 Variable --> number
difficulty
🇻 Variable --> integer
dot_increment
🇻 Variable --> number
duration_increment
🇻 Variable --> integer
effect_name
🇻 Variable --> string
The name of the primary effect this spell will enact.
effect_str
🇻 Variable --> string
Specifics about the effect this spell will enact.
energy_increment
🇻 Variable --> number
field_chance
🇻 Variable --> integer
field_intensity_increment
🇻 Variable --> number
field_intensity_variance
🇻 Variable --> number
final_casting_time
🇻 Variable --> integer
final_energy_cost
🇻 Variable --> integer
id
🇻 Variable --> SpellTypeId
max_aoe
🇻 Variable --> integer
max_damage
🇻 Variable --> integer
max_dot
🇻 Variable --> integer
max_duration
🇻 Variable --> integer
max_field_intensity
🇻 Variable --> integer
max_level
🇻 Variable --> integer
max_range
🇻 Variable --> integer
min_aoe
🇻 Variable --> integer
min_damage
🇻 Variable --> integer
min_dot
🇻 Variable --> integer
min_duration
🇻 Variable --> integer
min_field_intensity
🇻 Variable --> integer
min_range
🇻 Variable --> integer
range_increment
🇻 Variable --> number
additional_spells
🇲 Method --> ( ) -> SpellSimple[]
Other spells cast by this spell.
get_all
🇫 Function --> ( ) -> SpellTypeRaw[]
Returns a (long) list of every spell in the game.
TerId
Bases
No base classes.
Constructors
Members
NULL_ID
🇫 Function --> ( ) -> TerId
implements_int_id
🇫 Function --> ( ) -> boolean
int_id
🇲 Method --> ( ) -> TerIntId
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> TerRaw
str
🇲 Method --> ( ) -> string
TerIntId
Bases
No base classes.
Constructors
Members
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> TerRaw
str_id
🇲 Method --> ( ) -> TerId
TerRaw
Bases
No base classes.
Constructors
No constructors.
Members
close
🇻 Variable --> TerId
heat_radiation
🇻 Variable --> integer
open
🇻 Variable --> TerId
roof
🇻 Variable --> TerId
transforms_into
🇻 Variable --> TerId
trap_id_str
🇻 Variable --> string
get_coverage
🇲 Method --> ( ) -> integer
get_flags
🇲 Method --> ( ) -> string[]
get_light_emitted
🇲 Method --> ( ) -> integer
get_max_volume
🇲 Method --> ( ) -> Volume
get_movecost
🇲 Method --> ( ) -> integer
has_flag
🇲 Method --> ( string ) -> boolean
int_id
🇲 Method --> ( ) -> TerIntId
name
🇲 Method --> ( ) -> string
set_coverage
🇲 Method --> ( integer )
set_flag
🇲 Method --> ( string )
set_light_emitted
🇲 Method --> ( integer )
set_max_volume
🇲 Method --> ( Volume )
set_movecost
🇲 Method --> ( integer )
str_id
🇲 Method --> ( ) -> TerId
TimeDuration
Represent duration between 2 fixed points in time
Bases
No base classes.
Constructors
- TimeDuration.new( )
Members
from_days
🇫 Function --> ( integer ) -> TimeDuration
from_hours
🇫 Function --> ( integer ) -> TimeDuration
from_minutes
🇫 Function --> ( integer ) -> TimeDuration
from_seconds
🇫 Function --> ( integer ) -> TimeDuration
from_turns
🇫 Function --> ( integer ) -> TimeDuration
from_weeks
🇫 Function --> ( integer ) -> TimeDuration
make_random
🇲 Method --> ( TimeDuration ) -> TimeDuration
to_days
🇲 Method --> ( ) -> integer
to_hours
🇲 Method --> ( ) -> integer
to_minutes
🇲 Method --> ( ) -> integer
to_seconds
🇲 Method --> ( ) -> integer
to_turns
🇲 Method --> ( ) -> integer
to_weeks
🇲 Method --> ( ) -> integer
TimePoint
Library for dealing with time primitives.
Represent fixed point in time
Bases
No base classes.
Constructors
- TimePoint.new( )
Members
from_turn
🇫 Function --> ( integer ) -> TimePoint
hour_of_day
🇲 Method --> ( ) -> integer
is_dawn
🇲 Method --> ( ) -> boolean
is_day
🇲 Method --> ( ) -> boolean
is_dusk
🇲 Method --> ( ) -> boolean
is_night
🇲 Method --> ( ) -> boolean
minute_of_hour
🇲 Method --> ( ) -> integer
moon_phase
🇲 Method --> ( ) -> MoonPhase
season
🇲 Method --> ( ) -> string
second_of_minute
🇲 Method --> ( ) -> integer
sunrise
🇲 Method --> ( ) -> TimePoint
sunset
🇲 Method --> ( ) -> TimePoint
to_string_time_of_day
🇲 Method --> ( ) -> string
to_turn
🇲 Method --> ( ) -> integer
Tinymap
Bases
Map
Constructors
No constructors.
Members
No members.
TrapId
Bases
No base classes.
Constructors
Members
NULL_ID
🇫 Function --> ( ) -> TrapId
implements_int_id
🇫 Function --> ( ) -> boolean
int_id
🇲 Method --> ( ) -> TrapIntId
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> TrapRaw
str
🇲 Method --> ( ) -> string
TrapIntId
Bases
No base classes.
Constructors
Members
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> TrapRaw
str_id
🇲 Method --> ( ) -> TrapId
Tripoint
Bases
No base classes.
Constructors
Members
x
🇻 Variable --> integer
y
🇻 Variable --> integer
z
🇻 Variable --> integer
abs
🇲 Method --> ( ) -> Tripoint
reinterpret_as
🇲 Method --> ( origin: string, scale: string ) -> TripointCoord
Reinterpret this raw tripoint as a typed tripoint coordinate without changing x, y, or z.
rotate_2d
🇲 Method --> ( integer, Point ) -> Tripoint
xy
🇲 Method --> ( ) -> Point
TripointCoord
A typed three-dimensional coordinate. Its origin and scale describe how to interpret x, y, and z, and coordinate operations only combine compatible coordinate spaces.
Bases
No base classes.
Constructors
No constructors.
Members
x
🇻 Variable --> integer
y
🇻 Variable --> integer
z
🇻 Variable --> integer
origin
🇲 Method --> ( ) -> string
project_combine
🇲 Method --> ( fine: any ) -> nil | PointCoord | TripointCoord
Combines this coarse tripoint with a remainder from project_remain. Returns
TripointCoord, or nil if the pair is incompatible.
project_remain
🇲 Method --> ( scale: string ) -> (TripointCoord?, PointCoord?)
Splits this tripoint into a coarse
TripointCoordat the requested scale and aPointCoordremainder at this tripoint's original scale. The z value stays on the coarse tripoint. Returns nil, nil if the split is not valid.
project_remain_mmr
🇲 Method --> ( ) -> (TripointCoord?, PointCoord?)
Shortcut for
project_remain("mmr").
project_remain_om
🇲 Method --> ( ) -> (TripointCoord?, PointCoord?)
Shortcut for
project_remain("om").
project_remain_omt
🇲 Method --> ( ) -> (TripointCoord?, PointCoord?)
Shortcut for
project_remain("omt").
project_remain_seg
🇲 Method --> ( ) -> (TripointCoord?, PointCoord?)
Shortcut for
project_remain("seg").
project_remain_sm
🇲 Method --> ( ) -> (TripointCoord?, PointCoord?)
Shortcut for
project_remain("sm").
raw
🇲 Method --> ( ) -> Tripoint
reinterpret_as
🇲 Method --> ( origin: string, scale: string ) -> TripointCoord
Reinterpret this coordinate as another tripoint coordinate kind without changing x, y, or z.
rl_dist
🇲 Method --> ( other: TripointCoord ) -> integer?
Rectilinear distance to another
TripointCoordwith matching origin and scale. Returns nil if the argument is incompatible.
rotate_2d
🇲 Method --> ( integer, Point ) -> TripointCoord
scale
🇲 Method --> ( ) -> string
square_dist
🇲 Method --> ( other: TripointCoord ) -> integer?
Chebyshev distance to another
TripointCoordwith matching origin and scale. Returns nil if the argument is incompatible.
to
🇲 Method --> ( scale: string ) -> TripointCoord?
Projects this coordinate to another scale, preserving its origin and tripoint dimension. Returns nil if the conversion is not valid.
to_mmr
🇲 Method --> ( ) -> TripointCoord?
Shortcut for
to("mmr").
to_ms
🇲 Method --> ( ) -> TripointCoord?
Shortcut for
to("ms").
to_om
🇲 Method --> ( ) -> TripointCoord?
Shortcut for
to("om").
to_omt
🇲 Method --> ( ) -> TripointCoord?
Shortcut for
to("omt").
to_seg
🇲 Method --> ( ) -> TripointCoord?
Shortcut for
to("seg").
to_sm
🇲 Method --> ( ) -> TripointCoord?
Shortcut for
to("sm").
to_veh
🇲 Method --> ( ) -> TripointCoord?
Shortcut for
to("veh").
trig_dist
🇲 Method --> ( other: TripointCoord ) -> number?
Euclidean distance to another
TripointCoordwith matching origin and scale. Returns nil if the argument is incompatible.
type
🇲 Method --> ( ) -> string
xy
🇲 Method --> ( ) -> PointCoord
UiList
Bases
No base classes.
Constructors
- UiList.new( )
Members
entries
🇻 Variable --> UiListEntry[]
Entries from uilist. Remember, in lua, the first element of vector is
entries[1], notentries[0].
add
🇲 Method --> ( integer, string )
Adds an entry.
stringis its name, andintis what it returns. Ifintis-1, the number is decided orderly.
add_w_col
🇲 Method --> ( integer, string, string, string )
Adds an entry with desc and col(third
string). col is additional text on the right of the entry name.
add_w_desc
🇲 Method --> ( integer, string, string )
Adds an entry with desc(second
string).desc_enabled(true)is required for showing desc.
border_color
🇲 Method --> ( Color )
Changes the color. Default color is
c_magenta.
desc_enabled
🇲 Method --> ( boolean )
Puts a lower box. Footer or entry desc appears on it.
footer
🇲 Method --> ( string )
Sets footer text which is in lower box. It overwrites descs of entries unless is empty.
hilight_color
🇲 Method --> ( Color )
Changes the color. Default color is
h_white.
hotkey_color
🇲 Method --> ( Color )
Changes the color. Default color is
c_light_green.
query
🇲 Method --> ( ) -> integer
Returns retval for selected entry, or a negative number on fail/cancel
text
🇲 Method --> ( string )
Sets text which is in upper box.
text_color
🇲 Method --> ( Color )
Changes the color. Default color is
c_light_gray.
title
🇲 Method --> ( string )
Sets title which is on the top line.
title_color
🇲 Method --> ( Color )
Changes the color. Default color is
c_green.
UiListEntry
This type came from
UiList.
Bases
No base classes.
Constructors
No constructors.
Members
ctxt
🇻 Variable --> string
Entry text of column.
desc
🇻 Variable --> string
Entry description
enable
🇻 Variable --> boolean
Entry whether it's enabled or not. Default is
true.
txt
🇻 Variable --> string
Entry text
txt_color
🇲 Method --> ( Color )
Entry text color. Its default color is
c_red_red, which makes color of the entry same as whatuilistdecides. So if you want to make color different, choose one exceptc_red_red.
VitaminId
Bases
No base classes.
Constructors
- VitaminId.new( )
- VitaminId.new( VitaminId )
- VitaminId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> VitaminId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> VitaminRaw
str
🇲 Method --> ( ) -> string
VitaminRaw
Bases
No base classes.
Constructors
No constructors.
Members
deficiency
🇲 Method --> ( ) -> EffectTypeId
excess
🇲 Method --> ( ) -> EffectTypeId
has_flag
🇲 Method --> ( string ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
max
🇲 Method --> ( ) -> integer
min
🇲 Method --> ( ) -> integer
name
🇲 Method --> ( ) -> string
rate
🇲 Method --> ( ) -> TimeDuration
severity
🇲 Method --> ( integer ) -> integer
vitamin_id
🇲 Method --> ( ) -> VitaminId
vitamin_type
🇲 Method --> ( ) -> VitaminType
Volume
Bases
No base classes.
Constructors
No constructors.
Members
from_liter
🇫 Function --> ( integer ) -> Volume
from_milliliter
🇫 Function --> ( integer ) -> Volume
to_liter
🇲 Method --> ( ) -> number
to_milliliter
🇲 Method --> ( ) -> integer
WeaponCategoryId
Bases
No base classes.
Constructors
- WeaponCategoryId.new( )
- WeaponCategoryId.new( WeaponCategoryId )
- WeaponCategoryId.new( string )
Members
NULL_ID
🇫 Function --> ( ) -> WeaponCategoryId
implements_int_id
🇫 Function --> ( ) -> boolean
is_null
🇲 Method --> ( ) -> boolean
is_valid
🇲 Method --> ( ) -> boolean
obj
🇲 Method --> ( ) -> WeaponCategoryRaw
str
🇲 Method --> ( ) -> string
WrappedVehicle
Bases
No base classes.
Constructors
No constructors.
Members
pos
🇲 Method --> ( ) -> TripointBubMs
Returns the vehicle origin tile in local map-square coordinates.
type
🇲 Method --> ( ) -> string
Returns the vehicle prototype id string.
Enums
ActionId
Entries
ACTION_NULL=0ACTION_SELECT=1ACTION_SEC_SELECT=2ACTION_PAUSE=3ACTION_TIMEOUT=4ACTION_MOVE_FORTH=5ACTION_MOVE_FORTH_RIGHT=6ACTION_MOVE_RIGHT=7ACTION_MOVE_BACK_RIGHT=8ACTION_MOVE_BACK=9ACTION_MOVE_BACK_LEFT=10ACTION_MOVE_LEFT=11ACTION_MOVE_FORTH_LEFT=12ACTION_MOVE_DOWN=13ACTION_MOVE_UP=14ACTION_CYCLE_MOVE=15ACTION_RESET_MOVE=16ACTION_TOGGLE_RUN=17ACTION_TOGGLE_CROUCH=18ACTION_OPEN_MOVEMENT=19ACTION_TOGGLE_MAP_MEMORY=20ACTION_CENTER=21ACTION_SHIFT_N=22ACTION_SHIFT_NE=23ACTION_SHIFT_E=24ACTION_SHIFT_SE=25ACTION_SHIFT_S=26ACTION_SHIFT_SW=27ACTION_SHIFT_W=28ACTION_SHIFT_NW=29ACTION_OPEN=30ACTION_CLOSE=31ACTION_SMASH=32ACTION_EXAMINE=33ACTION_PICKUP=34ACTION_PICKUP_ALL=35ACTION_PICKUP_FEET=36ACTION_GRAB=37ACTION_HAUL=38ACTION_BUTCHER=39ACTION_CHAT=40ACTION_LOOK=41ACTION_PEEK=42ACTION_LIST_ITEMS=43ACTION_ZONES=44ACTION_LOOT=45ACTION_INVENTORY=46ACTION_ADVANCEDINV=47ACTION_COMPARE=48ACTION_ORGANIZE=49ACTION_USE=50ACTION_USE_WIELDED=51ACTION_WEAR=52ACTION_TAKE_OFF=53ACTION_EAT=54ACTION_OPEN_CONSUME=55ACTION_READ=56ACTION_WIELD=57ACTION_PICK_STYLE=58ACTION_RELOAD_ITEM=59ACTION_RELOAD_WEAPON=60ACTION_RELOAD_WIELDED=61ACTION_UNLOAD=62ACTION_UNLOAD_ALL=63ACTION_MEND=64ACTION_THROW=65ACTION_FIRE=66ACTION_FIRE_BURST=67ACTION_SELECT_FIRE_MODE=68ACTION_SELECT_DEFAULT_AMMO=69ACTION_CAST_SPELL=70ACTION_CAST_LAST_SPELL=71ACTION_DROP=72ACTION_DIR_DROP=73ACTION_BIONICS=74ACTION_MUTATIONS=75ACTION_SORT_ARMOR=76ACTION_AUTOATTACK=77ACTION_WAIT=78ACTION_CRAFT=79ACTION_RECRAFT=80ACTION_LONGCRAFT=81ACTION_CONSTRUCT=82ACTION_DISASSEMBLE=83ACTION_SALVAGE=84ACTION_SLEEP=85ACTION_CONTROL_VEHICLE=86ACTION_TOGGLE_AUTO_TRAVEL_MODE=87ACTION_TOGGLE_SAFEMODE=88ACTION_TOGGLE_AUTOSAFE=89ACTION_TOGGLE_THIEF_MODE=90ACTION_IGNORE_ENEMY=91ACTION_WHITELIST_ENEMY=92ACTION_SAVE=93ACTION_QUICKSAVE=94ACTION_QUICKLOAD=95ACTION_SUICIDE=96ACTION_PL_INFO=97ACTION_MAP=98ACTION_SKY=99ACTION_MISSIONS=100ACTION_SCORES=101ACTION_FACTIONS=102ACTION_MORALE=103ACTION_MESSAGES=104ACTION_OPEN_WIKI=105ACTION_OPEN_HHG=106ACTION_HELP=107ACTION_MAIN_MENU=108ACTION_DIARY=109ACTION_KEYBINDINGS=110ACTION_OPTIONS=111ACTION_AUTOPICKUP=112ACTION_AUTONOTES=113ACTION_SAFEMODE=114ACTION_COLOR=115ACTION_WORLD_MODS=116ACTION_DISTRACTION_MANAGER=117ACTION_TOGGLE_CHARACTER_PREVIEW_CLOTHES=118ACTION_TOGGLE_FULLSCREEN=119ACTION_DEBUG=120ACTION_LUA_CONSOLE=121ACTION_LUA_RELOAD=122ACTION_DISPLAY_SCENT=123ACTION_DISPLAY_SCENT_TYPE=124ACTION_TOGGLE_DEBUG_MODE=125ACTION_ZOOM_OUT=126ACTION_ZOOM_IN=127ACTION_ACTIONMENU=128ACTION_ITEMACTION=129ACTION_TOGGLE_PIXEL_MINIMAP=130ACTION_TOGGLE_PANEL_ADM=131ACTION_PANEL_MGMT=132ACTION_RELOAD_TILESET=133ACTION_TOGGLE_AUTO_FEATURES=134ACTION_TOGGLE_AUTO_PULP_BUTCHER=135ACTION_TOGGLE_AUTO_MINING=136ACTION_TOGGLE_AUTO_FORAGING=137ACTION_TOGGLE_AUTO_PICKUP=138ACTION_DISPLAY_TEMPERATURE=139ACTION_DISPLAY_VEHICLE_AI=140ACTION_DISPLAY_VISIBILITY=141ACTION_DISPLAY_LIGHTING=142ACTION_DISPLAY_RADIATION=143ACTION_DISPLAY_TRANSPARENCY=144ACTION_DISPLAY_OUTSIDE=145ACTION_DISPLAY_SUBMAP_GRID=146ACTION_DISPLAY_SOUND_ABSORPTION=147ACTION_DISPLAY_SOUND_WALLS=148ACTION_TOGGLE_ZONE_OVERLAY=149ACTION_DISPLAY_TILES_NO_VFX=150ACTION_TOGGLE_HOUR_TIMER=151ACTION_SWAP_TO_NPC=152
AddictionType
Entries
NONE=0CAFFEINE=1ALCOHOL=2SLEEP=3PKILLER=4SPEED=5CIG=6COKE=7CRACK=8MUTAGEN=9DIAZEPAM=10MARLOSS_R=11MARLOSS_B=12MARLOSS_Y=13
ArtifactCharge
Entries
ARTC_NULL=0ARTC_TIME=1ARTC_SOLAR=2ARTC_PAIN=3ARTC_HP=4ARTC_FATIGUE=5ARTC_PORTAL=6
ArtifactChargeReq
Entries
ACR_NULL=0ACR_EQUIP=1ACR_SKIN=2ACR_SLEEP=3ACR_RAD=4ACR_WET=5ACR_SKY=6
ArtifactEffectActive
Entries
AEP_NULL=0AEP_STR_UP=1AEP_DEX_UP=2AEP_PER_UP=3AEP_INT_UP=4AEP_ALL_UP=5AEP_SPEED_UP=6AEP_PBLUE=7AEP_SNAKES=8AEP_INVISIBLE=9AEP_CLAIRVOYANCE=10AEP_SUPER_CLAIRVOYANCE=11AEP_STEALTH=12AEP_EXTINGUISH=13AEP_GLOW=14AEP_PSYSHIELD=15AEP_RESIST_ELECTRICITY=16AEP_CARRY_MORE=17AEP_SAP_LIFE=18AEP_FUN=19AEP_SPLIT=20AEP_HUNGER=21AEP_THIRST=22AEP_SMOKE=23AEP_EVIL=24AEP_SCHIZO=25AEP_RADIOACTIVE=26AEP_MUTAGENIC=27AEP_ATTENTION=28AEP_STR_DOWN=29AEP_DEX_DOWN=30AEP_PER_DOWN=31AEP_INT_DOWN=32AEP_ALL_DOWN=33AEP_SPEED_DOWN=34AEP_FORCE_TELEPORT=35AEP_MOVEMENT_NOISE=36AEP_BAD_WEATHER=37AEP_SICK=38AEP_CLAIRVOYANCE_PLUS=39
ArtifactEffectPassive
Entries
AEA_NULL=0AEA_STORM=1AEA_FIREBALL=2AEA_ADRENALINE=3AEA_MAP=4AEA_BLOOD=5AEA_FATIGUE=6AEA_ACIDBALL=7AEA_PULSE=8AEA_HEAL=9AEA_CONFUSED=10AEA_ENTRANCE=11AEA_BUGS=12AEA_TELEPORT=13AEA_LIGHT=14AEA_GROWTH=15AEA_HURTALL=16AEA_FUN=17AEA_SPLIT=18AEA_RADIATION=19AEA_PAIN=20AEA_MUTATE=21AEA_PARALYZE=22AEA_FIRESTORM=23AEA_ATTENTION=24AEA_TELEGLOW=25AEA_NOISE=26AEA_SCREAM=27AEA_DIM=28AEA_FLASH=29AEA_VOMIT=30AEA_SHADOWS=31AEA_STAMINA_EMPTY=32
Attitude
Entries
Hostile=0Neutral=1Friendly=2Any=3
BodyPart
Entries
TORSO=0HEAD=1EYES=2MOUTH=3ARM_L=4ARM_R=5HAND_L=6HAND_R=7LEG_L=8LEG_R=9FOOT_L=10FOOT_R=11
CharacterMoveMode
Entries
walk=0run=1crouch=2
Color
Entries
c_black=0c_white=1c_light_gray=2c_dark_gray=3c_red=4c_green=5c_blue=6c_cyan=7c_magenta=8c_brown=9c_light_red=10c_light_green=11c_light_blue=12c_light_cyan=13c_pink=14c_yellow=15h_black=16h_white=17h_light_gray=18h_dark_gray=19h_red=20h_green=21h_blue=22h_cyan=23h_magenta=24h_brown=25h_light_red=26h_light_green=27h_light_blue=28h_light_cyan=29h_pink=30h_yellow=31i_black=32i_white=33i_light_gray=34i_dark_gray=35i_red=36i_green=37i_blue=38i_cyan=39i_magenta=40i_brown=41i_light_red=42i_light_green=43i_light_blue=44i_light_cyan=45i_pink=46i_yellow=47c_unset=48c_black_red=49c_white_red=50c_light_gray_red=51c_dark_gray_red=52c_red_red=53c_green_red=54c_blue_red=55c_cyan_red=56c_magenta_red=57c_brown_red=58c_light_red_red=59c_light_green_red=60c_light_blue_red=61c_light_cyan_red=62c_pink_red=63c_yellow_red=64c_black_white=65c_dark_gray_white=66c_light_gray_white=67c_white_white=68c_red_white=69c_light_red_white=70c_green_white=71c_light_green_white=72c_brown_white=73c_yellow_white=74c_blue_white=75c_light_blue_white=76c_magenta_white=77c_pink_white=78c_cyan_white=79c_light_cyan_white=80c_black_green=81c_dark_gray_green=82c_light_gray_green=83c_white_green=84c_red_green=85c_light_red_green=86c_green_green=87c_light_green_green=88c_brown_green=89c_yellow_green=90c_blue_green=91c_light_blue_green=92c_magenta_green=93c_pink_green=94c_cyan_green=95c_light_cyan_green=96c_black_yellow=97c_dark_gray_yellow=98c_light_gray_yellow=99c_white_yellow=100c_red_yellow=101c_light_red_yellow=102c_green_yellow=103c_light_green_yellow=104c_brown_yellow=105c_yellow_yellow=106c_blue_yellow=107c_light_blue_yellow=108c_magenta_yellow=109c_pink_yellow=110c_cyan_yellow=111c_light_cyan_yellow=112c_black_magenta=113c_dark_gray_magenta=114c_light_gray_magenta=115c_white_magenta=116c_red_magenta=117c_light_red_magenta=118c_green_magenta=119c_light_green_magenta=120c_brown_magenta=121c_yellow_magenta=122c_blue_magenta=123c_light_blue_magenta=124c_magenta_magenta=125c_pink_magenta=126c_cyan_magenta=127c_light_cyan_magenta=128c_black_cyan=129c_dark_gray_cyan=130c_light_gray_cyan=131c_white_cyan=132c_red_cyan=133c_light_red_cyan=134c_green_cyan=135c_light_green_cyan=136c_brown_cyan=137c_yellow_cyan=138c_blue_cyan=139c_light_blue_cyan=140c_magenta_cyan=141c_pink_cyan=142c_cyan_cyan=143c_light_cyan_cyan=144
DamageType
Entries
DT_NULL=0DT_TRUE=1DT_BIOLOGICAL=2DT_BASH=3DT_CUT=4DT_ACID=5DT_STAB=6DT_HEAT=7DT_COLD=8DT_DARK=9DT_LIGHT=10DT_PSI=11DT_ELECTRIC=12DT_BULLET=13
Direction
Entries
center=0west=1east=2north=3north_west=4north_east=5south=6south_west=7south_east=8below=9below_west=10below_east=11below_north=12below_north_west=13below_north_east=14below_south=15below_south_west=16below_south_east=17above=18above_west=19above_east=20above_north=21above_north_west=22above_north_east=23above_south=24above_south_west=25above_south_east=26
MissionGoal
Entries
MGOAL_NULL=0MGOAL_GO_TO=1MGOAL_GO_TO_TYPE=2MGOAL_FIND_ITEM=3MGOAL_FIND_ANY_ITEM=4MGOAL_FIND_ITEM_GROUP=5MGOAL_FIND_MONSTER=6MGOAL_FIND_NPC=7MGOAL_ASSASSINATE=8MGOAL_KILL_MONSTER=9MGOAL_KILL_MONSTER_TYPE=10MGOAL_KILL_NEMESIS=11MGOAL_RECRUIT_NPC=12MGOAL_RECRUIT_NPC_CLASS=13MGOAL_COMPUTER_TOGGLE=14MGOAL_KILL_MONSTER_SPEC=15MGOAL_TALK_TO_NPC=16MGOAL_CONDITION=17MGOAL_KILL_MONSTERS=18
MissionOrigin
Entries
ORIGIN_NULL=0ORIGIN_GAME_START=1ORIGIN_OPENER_NPC=2ORIGIN_ANY_NPC=3ORIGIN_SECONDARY=4ORIGIN_COMPUTER=5
MonsterAttitude
Entries
MATT_NULL=0MATT_FRIEND=1MATT_FPASSIVE=2MATT_FLEE=3MATT_IGNORE=4MATT_FOLLOW=5MATT_ATTACK=6MATT_ZLAVE=7MATT_UNKNOWN=8
MonsterFactionAttitude
Entries
ByMood=0Neutral=1Friendly=2Hate=3
MonsterFlag
Entries
SEES=0HEARS=1GOODHEARING=2SMELLS=3KEENNOSE=4STUMBLES=5WARM=6NEMESIS=7NOHEAD=8HARDTOSHOOT=9GRABS=10BASHES=11DESTROYS=12BORES=13POISON=14VENOM=15BADVENOM=16PARALYZEVENOM=17BLEED=18WEBWALK=19DIGS=20CAN_DIG=21FLIES=22AQUATIC=23SWIMS=24ATTACKMON=25ANIMAL=26PLASTIC=27SUNDEATH=28ELECTRIC=29ACIDPROOF=30ACIDTRAIL=31SHORTACIDTRAIL=32FIREPROOF=33SLUDGEPROOF=34SLUDGETRAIL=35COLDPROOF=36BIOPROOF=37DARKPROOF=38LIGHTPROOF=39PSIPROOF=40FIREY=41QUEEN=42ELECTRONIC=43FUR=44LEATHER=45WOOL=46FEATHER=47BONES=48FAT=49CONSOLE_DESPAWN=50IMMOBILE=51STATIONARY=52ID_CARD_DESPAWN=53RIDEABLE_MECH=54CARD_OVERRIDE=55MILITARY_MECH=56MECH_RECON_VISION=57MECH_DEFENSIVE=58HIT_AND_RUN=59GUILT=60PAY_BOT=61HUMAN=62NO_BREATHE=63FLAMMABLE=64REVIVES=65CHITIN=66VERMIN=67NOGIB=68LARVA=69ARTHROPOD_BLOOD=70ACID_BLOOD=71BILE_BLOOD=72ABSORBS=73ABSORBS_SPLITS=74CBM_CIV=75CBM_POWER=76CBM_SCI=77CBM_OP=78CBM_TECH=79CBM_SUBS=80UNUSED_76=81FISHABLE=82GROUP_BASH=83SWARMS=84GROUP_MORALE=85INTERIOR_AMMO=86CLIMBS=87PACIFIST=88PUSH_MON=89PUSH_VEH=90NIGHT_INVISIBILITY=91REVIVES_HEALTHY=92NO_NECRO=93PATH_AVOID_DANGER_1=94PATH_AVOID_DANGER_2=95PATH_AVOID_FIRE=96PATH_AVOID_FALL=97PRIORITIZE_TARGETS=98NOT_HALLUCINATION=99CANPLAY=100PET_MOUNTABLE=101PET_HARNESSABLE=102CAN_FETCH=103DOGFOOD=104MILKABLE=105SHEARABLE=106NO_BREED=107NO_FUNG_DMG=108PET_WONT_FOLLOW=109DRIPS_NAPALM=110DRIPS_GASOLINE=111ELECTRIC_FIELD=112LOUDMOVES=113CAN_OPEN_DOORS=114STUN_IMMUNE=115DROPS_AMMO=116CAN_BE_ORDERED=117SMALL_HEAD=118TINY_HEAD=119NO_HEAD_BONUS_CRIT=120HEAD_BONUS_CRIT_1=121HEAD_BONUS_CRIT_2=122TORSO_BONUS_CRIT_1=123TORSO_BONUS_CRIT_2=124PROJECTILE_RESISTANT_1=125PROJECTILE_RESISTANT_2=126PROJECTILE_RESISTANT_3=127PROJECTILE_RESISTANT_4=128VOLATILE=129CANT_CLONE=130MOUNTABLE_STAIRS=131MOUNTABLE_LADDER=132MOUNTABLE_OBSTACLES=133MOUNTABLE_DOORS=134MOUNTABLE_LEDGE=135FACTION_MEMORY=136COMBAT_MOUNT=137CANT_TRAIN=138
MonsterSize
Entries
TINY=0SMALL=1MEDIUM=2LARGE=3HUGE=4
MoonPhase
Entries
MOON_NEW=0MOON_WAXING_CRESCENT=1MOON_HALF_MOON_WAXING=2MOON_WAXING_GIBBOUS=3MOON_FULL=4MOON_WANING_GIBBOUS=5MOON_HALF_MOON_WANING=6MOON_WANING_CRESCENT=7
MsgType
Entries
good=0bad=1mixed=2warning=3info=4neutral=5debug=6headshot=7critical=8grazing=9
NpcAttitude
Entries
NPCATT_NULL=0NPCATT_TALK=1NPCATT_LEGACY_1=2NPCATT_FOLLOW=3NPCATT_LEGACY_2=4NPCATT_LEAD=5NPCATT_WAIT=6NPCATT_LEGACY_6=7NPCATT_MUG=8NPCATT_WAIT_FOR_LEAVE=9NPCATT_KILL=10NPCATT_FLEE=11NPCATT_LEGACY_3=12NPCATT_HEAL=13NPCATT_LEGACY_4=14NPCATT_LEGACY_5=15NPCATT_ACTIVITY=16NPCATT_FLEE_TEMP=17NPCATT_RECOVER_GOODS=18
NpcNeed
Entries
need_none=0need_ammo=1need_weapon=2need_gun=3need_food=4need_drink=5need_safety=6
OtMatchType
Entries
EXACT=0TYPE=1PREFIX=2CONTAINS=3
SfxChannel
Entries
daytime_outdoors_env=0nighttime_outdoors_env=1underground_env=2indoors_env=3indoors_rain_env=4outdoors_snow_env=5outdoors_flurry_env=6outdoors_thunderstorm_env=7outdoors_rain_env=8outdoors_drizzle_env=9outdoor_blizzard=10deafness_tone=11danger_extreme_theme=12danger_high_theme=13danger_medium_theme=14danger_low_theme=15stamina_75=16stamina_50=17stamina_35=18idle_chainsaw=19chainsaw_theme=20player_activities=21exterior_engine_sound=22interior_engine_sound=23radio=24
VitaminType
Entries
vitamin=0toxin=1drug=2counter=3
Libraries
PointAbsMmr
Members
new
🇫 Function --> ( ) -> PointAbsMmr
🇫 Function --> ( Point ) -> PointAbsMmr
🇫 Function --> ( integer, integer ) -> PointAbsMmr
PointAbsMs
Members
new
🇫 Function --> ( ) -> PointAbsMs
🇫 Function --> ( Point ) -> PointAbsMs
🇫 Function --> ( integer, integer ) -> PointAbsMs
PointAbsOm
Members
new
🇫 Function --> ( ) -> PointAbsOm
🇫 Function --> ( Point ) -> PointAbsOm
🇫 Function --> ( integer, integer ) -> PointAbsOm
PointAbsOmt
Members
new
🇫 Function --> ( ) -> PointAbsOmt
🇫 Function --> ( Point ) -> PointAbsOmt
🇫 Function --> ( integer, integer ) -> PointAbsOmt
PointAbsSeg
Members
new
🇫 Function --> ( ) -> PointAbsSeg
🇫 Function --> ( Point ) -> PointAbsSeg
🇫 Function --> ( integer, integer ) -> PointAbsSeg
PointAbsSm
Members
new
🇫 Function --> ( ) -> PointAbsSm
🇫 Function --> ( Point ) -> PointAbsSm
🇫 Function --> ( integer, integer ) -> PointAbsSm
PointBubMs
Members
new
🇫 Function --> ( ) -> PointBubMs
🇫 Function --> ( Point ) -> PointBubMs
🇫 Function --> ( integer, integer ) -> PointBubMs
PointBubSm
Members
new
🇫 Function --> ( ) -> PointBubSm
🇫 Function --> ( Point ) -> PointBubSm
🇫 Function --> ( integer, integer ) -> PointBubSm
PointMmrMs
Members
new
🇫 Function --> ( ) -> PointMmrMs
🇫 Function --> ( Point ) -> PointMmrMs
🇫 Function --> ( integer, integer ) -> PointMmrMs
PointMmrOmt
Members
new
🇫 Function --> ( ) -> PointMmrOmt
🇫 Function --> ( Point ) -> PointMmrOmt
🇫 Function --> ( integer, integer ) -> PointMmrOmt
PointMmrSm
Members
new
🇫 Function --> ( ) -> PointMmrSm
🇫 Function --> ( Point ) -> PointMmrSm
🇫 Function --> ( integer, integer ) -> PointMmrSm
PointMntVeh
Members
new
🇫 Function --> ( ) -> PointMntVeh
🇫 Function --> ( Point ) -> PointMntVeh
🇫 Function --> ( integer, integer ) -> PointMntVeh
PointOmMmr
Members
new
🇫 Function --> ( ) -> PointOmMmr
🇫 Function --> ( Point ) -> PointOmMmr
🇫 Function --> ( integer, integer ) -> PointOmMmr
PointOmMs
Members
new
🇫 Function --> ( ) -> PointOmMs
🇫 Function --> ( Point ) -> PointOmMs
🇫 Function --> ( integer, integer ) -> PointOmMs
PointOmOmt
Members
new
🇫 Function --> ( ) -> PointOmOmt
🇫 Function --> ( Point ) -> PointOmOmt
🇫 Function --> ( integer, integer ) -> PointOmOmt
PointOmSeg
Members
new
🇫 Function --> ( ) -> PointOmSeg
🇫 Function --> ( Point ) -> PointOmSeg
🇫 Function --> ( integer, integer ) -> PointOmSeg
PointOmSm
Members
new
🇫 Function --> ( ) -> PointOmSm
🇫 Function --> ( Point ) -> PointOmSm
🇫 Function --> ( integer, integer ) -> PointOmSm
PointOmtMs
Members
new
🇫 Function --> ( ) -> PointOmtMs
🇫 Function --> ( Point ) -> PointOmtMs
🇫 Function --> ( integer, integer ) -> PointOmtMs
PointOmtSm
Members
new
🇫 Function --> ( ) -> PointOmtSm
🇫 Function --> ( Point ) -> PointOmtSm
🇫 Function --> ( integer, integer ) -> PointOmtSm
PointRelMmr
Members
new
🇫 Function --> ( ) -> PointRelMmr
🇫 Function --> ( Point ) -> PointRelMmr
🇫 Function --> ( integer, integer ) -> PointRelMmr
PointRelMs
Members
new
🇫 Function --> ( ) -> PointRelMs
🇫 Function --> ( Point ) -> PointRelMs
🇫 Function --> ( integer, integer ) -> PointRelMs
PointRelOm
Members
new
🇫 Function --> ( ) -> PointRelOm
🇫 Function --> ( Point ) -> PointRelOm
🇫 Function --> ( integer, integer ) -> PointRelOm
PointRelOmt
Members
new
🇫 Function --> ( ) -> PointRelOmt
🇫 Function --> ( Point ) -> PointRelOmt
🇫 Function --> ( integer, integer ) -> PointRelOmt
PointRelSeg
Members
new
🇫 Function --> ( ) -> PointRelSeg
🇫 Function --> ( Point ) -> PointRelSeg
🇫 Function --> ( integer, integer ) -> PointRelSeg
PointRelSm
Members
new
🇫 Function --> ( ) -> PointRelSm
🇫 Function --> ( Point ) -> PointRelSm
🇫 Function --> ( integer, integer ) -> PointRelSm
PointRelVeh
Members
new
🇫 Function --> ( ) -> PointRelVeh
🇫 Function --> ( Point ) -> PointRelVeh
🇫 Function --> ( integer, integer ) -> PointRelVeh
PointSegMmr
Members
new
🇫 Function --> ( ) -> PointSegMmr
🇫 Function --> ( Point ) -> PointSegMmr
🇫 Function --> ( integer, integer ) -> PointSegMmr
PointSegMs
Members
new
🇫 Function --> ( ) -> PointSegMs
🇫 Function --> ( Point ) -> PointSegMs
🇫 Function --> ( integer, integer ) -> PointSegMs
PointSegOmt
Members
new
🇫 Function --> ( ) -> PointSegOmt
🇫 Function --> ( Point ) -> PointSegOmt
🇫 Function --> ( integer, integer ) -> PointSegOmt
PointSegSm
Members
new
🇫 Function --> ( ) -> PointSegSm
🇫 Function --> ( Point ) -> PointSegSm
🇫 Function --> ( integer, integer ) -> PointSegSm
PointSmMs
Members
new
🇫 Function --> ( ) -> PointSmMs
🇫 Function --> ( Point ) -> PointSmMs
🇫 Function --> ( integer, integer ) -> PointSmMs
TripointAbsMmr
Members
new
🇫 Function --> ( ) -> TripointAbsMmr
🇫 Function --> ( Tripoint ) -> TripointAbsMmr
🇫 Function --> ( Point, integer ) -> TripointAbsMmr
🇫 Function --> ( PointAbsMmr, integer ) -> TripointAbsMmr
🇫 Function --> ( integer, integer, integer ) -> TripointAbsMmr
TripointAbsMs
Members
new
🇫 Function --> ( ) -> TripointAbsMs
🇫 Function --> ( Tripoint ) -> TripointAbsMs
🇫 Function --> ( Point, integer ) -> TripointAbsMs
🇫 Function --> ( PointAbsMs, integer ) -> TripointAbsMs
🇫 Function --> ( integer, integer, integer ) -> TripointAbsMs
TripointAbsOm
Members
new
🇫 Function --> ( ) -> TripointAbsOm
🇫 Function --> ( Tripoint ) -> TripointAbsOm
🇫 Function --> ( Point, integer ) -> TripointAbsOm
🇫 Function --> ( PointAbsOm, integer ) -> TripointAbsOm
🇫 Function --> ( integer, integer, integer ) -> TripointAbsOm
TripointAbsOmt
Members
new
🇫 Function --> ( ) -> TripointAbsOmt
🇫 Function --> ( Tripoint ) -> TripointAbsOmt
🇫 Function --> ( Point, integer ) -> TripointAbsOmt
🇫 Function --> ( PointAbsOmt, integer ) -> TripointAbsOmt
🇫 Function --> ( integer, integer, integer ) -> TripointAbsOmt
TripointAbsSeg
Members
new
🇫 Function --> ( ) -> TripointAbsSeg
🇫 Function --> ( Tripoint ) -> TripointAbsSeg
🇫 Function --> ( Point, integer ) -> TripointAbsSeg
🇫 Function --> ( PointAbsSeg, integer ) -> TripointAbsSeg
🇫 Function --> ( integer, integer, integer ) -> TripointAbsSeg
TripointAbsSm
Members
new
🇫 Function --> ( ) -> TripointAbsSm
🇫 Function --> ( Tripoint ) -> TripointAbsSm
🇫 Function --> ( Point, integer ) -> TripointAbsSm
🇫 Function --> ( PointAbsSm, integer ) -> TripointAbsSm
🇫 Function --> ( integer, integer, integer ) -> TripointAbsSm
TripointBubMs
Members
new
🇫 Function --> ( ) -> TripointBubMs
🇫 Function --> ( Tripoint ) -> TripointBubMs
🇫 Function --> ( Point, integer ) -> TripointBubMs
🇫 Function --> ( PointBubMs, integer ) -> TripointBubMs
🇫 Function --> ( integer, integer, integer ) -> TripointBubMs
TripointBubSm
Members
new
🇫 Function --> ( ) -> TripointBubSm
🇫 Function --> ( Tripoint ) -> TripointBubSm
🇫 Function --> ( Point, integer ) -> TripointBubSm
🇫 Function --> ( PointBubSm, integer ) -> TripointBubSm
🇫 Function --> ( integer, integer, integer ) -> TripointBubSm
TripointMmrMs
Members
new
🇫 Function --> ( ) -> TripointMmrMs
🇫 Function --> ( Tripoint ) -> TripointMmrMs
🇫 Function --> ( Point, integer ) -> TripointMmrMs
🇫 Function --> ( PointMmrMs, integer ) -> TripointMmrMs
🇫 Function --> ( integer, integer, integer ) -> TripointMmrMs
TripointMmrOmt
Members
new
🇫 Function --> ( ) -> TripointMmrOmt
🇫 Function --> ( Tripoint ) -> TripointMmrOmt
🇫 Function --> ( Point, integer ) -> TripointMmrOmt
🇫 Function --> ( PointMmrOmt, integer ) -> TripointMmrOmt
🇫 Function --> ( integer, integer, integer ) -> TripointMmrOmt
TripointMmrSm
Members
new
🇫 Function --> ( ) -> TripointMmrSm
🇫 Function --> ( Tripoint ) -> TripointMmrSm
🇫 Function --> ( Point, integer ) -> TripointMmrSm
🇫 Function --> ( PointMmrSm, integer ) -> TripointMmrSm
🇫 Function --> ( integer, integer, integer ) -> TripointMmrSm
TripointMntVeh
Members
new
🇫 Function --> ( ) -> TripointMntVeh
🇫 Function --> ( Tripoint ) -> TripointMntVeh
🇫 Function --> ( Point, integer ) -> TripointMntVeh
🇫 Function --> ( PointMntVeh, integer ) -> TripointMntVeh
🇫 Function --> ( integer, integer, integer ) -> TripointMntVeh
TripointOmMmr
Members
new
🇫 Function --> ( ) -> TripointOmMmr
🇫 Function --> ( Tripoint ) -> TripointOmMmr
🇫 Function --> ( Point, integer ) -> TripointOmMmr
🇫 Function --> ( PointOmMmr, integer ) -> TripointOmMmr
🇫 Function --> ( integer, integer, integer ) -> TripointOmMmr
TripointOmMs
Members
new
🇫 Function --> ( ) -> TripointOmMs
🇫 Function --> ( Tripoint ) -> TripointOmMs
🇫 Function --> ( Point, integer ) -> TripointOmMs
🇫 Function --> ( PointOmMs, integer ) -> TripointOmMs
🇫 Function --> ( integer, integer, integer ) -> TripointOmMs
TripointOmOmt
Members
new
🇫 Function --> ( ) -> TripointOmOmt
🇫 Function --> ( Tripoint ) -> TripointOmOmt
🇫 Function --> ( Point, integer ) -> TripointOmOmt
🇫 Function --> ( PointOmOmt, integer ) -> TripointOmOmt
🇫 Function --> ( integer, integer, integer ) -> TripointOmOmt
TripointOmSeg
Members
new
🇫 Function --> ( ) -> TripointOmSeg
🇫 Function --> ( Tripoint ) -> TripointOmSeg
🇫 Function --> ( Point, integer ) -> TripointOmSeg
🇫 Function --> ( PointOmSeg, integer ) -> TripointOmSeg
🇫 Function --> ( integer, integer, integer ) -> TripointOmSeg
TripointOmSm
Members
new
🇫 Function --> ( ) -> TripointOmSm
🇫 Function --> ( Tripoint ) -> TripointOmSm
🇫 Function --> ( Point, integer ) -> TripointOmSm
🇫 Function --> ( PointOmSm, integer ) -> TripointOmSm
🇫 Function --> ( integer, integer, integer ) -> TripointOmSm
TripointOmtMs
Members
new
🇫 Function --> ( ) -> TripointOmtMs
🇫 Function --> ( Tripoint ) -> TripointOmtMs
🇫 Function --> ( Point, integer ) -> TripointOmtMs
🇫 Function --> ( PointOmtMs, integer ) -> TripointOmtMs
🇫 Function --> ( integer, integer, integer ) -> TripointOmtMs
TripointOmtSm
Members
new
🇫 Function --> ( ) -> TripointOmtSm
🇫 Function --> ( Tripoint ) -> TripointOmtSm
🇫 Function --> ( Point, integer ) -> TripointOmtSm
🇫 Function --> ( PointOmtSm, integer ) -> TripointOmtSm
🇫 Function --> ( integer, integer, integer ) -> TripointOmtSm
TripointRelMmr
Members
new
🇫 Function --> ( ) -> TripointRelMmr
🇫 Function --> ( Tripoint ) -> TripointRelMmr
🇫 Function --> ( Point, integer ) -> TripointRelMmr
🇫 Function --> ( PointRelMmr, integer ) -> TripointRelMmr
🇫 Function --> ( integer, integer, integer ) -> TripointRelMmr
TripointRelMs
Members
new
🇫 Function --> ( ) -> TripointRelMs
🇫 Function --> ( Tripoint ) -> TripointRelMs
🇫 Function --> ( Point, integer ) -> TripointRelMs
🇫 Function --> ( PointRelMs, integer ) -> TripointRelMs
🇫 Function --> ( integer, integer, integer ) -> TripointRelMs
TripointRelOm
Members
new
🇫 Function --> ( ) -> TripointRelOm
🇫 Function --> ( Tripoint ) -> TripointRelOm
🇫 Function --> ( Point, integer ) -> TripointRelOm
🇫 Function --> ( PointRelOm, integer ) -> TripointRelOm
🇫 Function --> ( integer, integer, integer ) -> TripointRelOm
TripointRelOmt
Members
new
🇫 Function --> ( ) -> TripointRelOmt
🇫 Function --> ( Tripoint ) -> TripointRelOmt
🇫 Function --> ( Point, integer ) -> TripointRelOmt
🇫 Function --> ( PointRelOmt, integer ) -> TripointRelOmt
🇫 Function --> ( integer, integer, integer ) -> TripointRelOmt
TripointRelSeg
Members
new
🇫 Function --> ( ) -> TripointRelSeg
🇫 Function --> ( Tripoint ) -> TripointRelSeg
🇫 Function --> ( Point, integer ) -> TripointRelSeg
🇫 Function --> ( PointRelSeg, integer ) -> TripointRelSeg
🇫 Function --> ( integer, integer, integer ) -> TripointRelSeg
TripointRelSm
Members
new
🇫 Function --> ( ) -> TripointRelSm
🇫 Function --> ( Tripoint ) -> TripointRelSm
🇫 Function --> ( Point, integer ) -> TripointRelSm
🇫 Function --> ( PointRelSm, integer ) -> TripointRelSm
🇫 Function --> ( integer, integer, integer ) -> TripointRelSm
TripointRelVeh
Members
new
🇫 Function --> ( ) -> TripointRelVeh
🇫 Function --> ( Tripoint ) -> TripointRelVeh
🇫 Function --> ( Point, integer ) -> TripointRelVeh
🇫 Function --> ( PointRelVeh, integer ) -> TripointRelVeh
🇫 Function --> ( integer, integer, integer ) -> TripointRelVeh
TripointSegMmr
Members
new
🇫 Function --> ( ) -> TripointSegMmr
🇫 Function --> ( Tripoint ) -> TripointSegMmr
🇫 Function --> ( Point, integer ) -> TripointSegMmr
🇫 Function --> ( PointSegMmr, integer ) -> TripointSegMmr
🇫 Function --> ( integer, integer, integer ) -> TripointSegMmr
TripointSegMs
Members
new
🇫 Function --> ( ) -> TripointSegMs
🇫 Function --> ( Tripoint ) -> TripointSegMs
🇫 Function --> ( Point, integer ) -> TripointSegMs
🇫 Function --> ( PointSegMs, integer ) -> TripointSegMs
🇫 Function --> ( integer, integer, integer ) -> TripointSegMs
TripointSegOmt
Members
new
🇫 Function --> ( ) -> TripointSegOmt
🇫 Function --> ( Tripoint ) -> TripointSegOmt
🇫 Function --> ( Point, integer ) -> TripointSegOmt
🇫 Function --> ( PointSegOmt, integer ) -> TripointSegOmt
🇫 Function --> ( integer, integer, integer ) -> TripointSegOmt
TripointSegSm
Members
new
🇫 Function --> ( ) -> TripointSegSm
🇫 Function --> ( Tripoint ) -> TripointSegSm
🇫 Function --> ( Point, integer ) -> TripointSegSm
🇫 Function --> ( PointSegSm, integer ) -> TripointSegSm
🇫 Function --> ( integer, integer, integer ) -> TripointSegSm
TripointSmMs
Members
new
🇫 Function --> ( ) -> TripointSmMs
🇫 Function --> ( Tripoint ) -> TripointSmMs
🇫 Function --> ( Point, integer ) -> TripointSmMs
🇫 Function --> ( PointSmMs, integer ) -> TripointSmMs
🇫 Function --> ( integer, integer, integer ) -> TripointSmMs
ch_names
Members
generate
🇫 Function --> ( boolean? ) -> string
Generates a random full name with an optional boolean for gender. The loaded name is one of usage with optional gender. The combinations used in names files are as follows: Backer | (Female|Male|Unisex) Given | (Female|Male) // unisex names are duplicated in each group Family | Unisex Nick City World
pick
🇫 Function --> ( any ) -> string
Generates a single name using any combination of search flags.
const
Various game constants
Members
OMT_MS_SIZE
🇨 Constant --> integer = 24
OMT_SM_SIZE
🇨 Constant --> integer = 2
OM_MS_SIZE
🇨 Constant --> integer = 4320
OM_OMT_SIZE
🇨 Constant --> integer = 180
OM_SM_SIZE
🇨 Constant --> integer = 360
SM_MS_SIZE
🇨 Constant --> integer = 12
coords
Members
overmap_terrain_tiles
🇫 Function --> ( ) -> PointCoord[]
Returns every map-square offset within one overmap terrain tile as
PointCoordvalues.
overmap_tiles
🇫 Function --> ( ) -> PointCoord[]
Returns every map-square offset within one overmap as
PointCoordvalues.
point
🇫 Function --> ( string, string, Point ) -> PointCoord
🇫 Function --> ( string, string, integer, integer ) -> PointCoord
point_abs_mmr
🇫 Function --> ( integer, integer ) -> PointCoord
point_abs_ms
🇫 Function --> ( integer, integer ) -> PointCoord
point_abs_om
🇫 Function --> ( integer, integer ) -> PointCoord
point_abs_omt
🇫 Function --> ( integer, integer ) -> PointCoord
point_abs_seg
🇫 Function --> ( integer, integer ) -> PointCoord
point_abs_sm
🇫 Function --> ( integer, integer ) -> PointCoord
point_bub_ms
🇫 Function --> ( integer, integer ) -> PointCoord
point_bub_sm
🇫 Function --> ( integer, integer ) -> PointCoord
point_mmr_ms
🇫 Function --> ( integer, integer ) -> PointCoord
point_mmr_omt
🇫 Function --> ( integer, integer ) -> PointCoord
point_mmr_sm
🇫 Function --> ( integer, integer ) -> PointCoord
point_mnt_veh
🇫 Function --> ( integer, integer ) -> PointCoord
point_om_mmr
🇫 Function --> ( integer, integer ) -> PointCoord
point_om_ms
🇫 Function --> ( integer, integer ) -> PointCoord
point_om_omt
🇫 Function --> ( integer, integer ) -> PointCoord
point_om_seg
🇫 Function --> ( integer, integer ) -> PointCoord
point_om_sm
🇫 Function --> ( integer, integer ) -> PointCoord
point_omt_ms
🇫 Function --> ( integer, integer ) -> PointCoord
point_omt_sm
🇫 Function --> ( integer, integer ) -> PointCoord
point_rel_mmr
🇫 Function --> ( integer, integer ) -> PointCoord
point_rel_ms
🇫 Function --> ( integer, integer ) -> PointCoord
point_rel_om
🇫 Function --> ( integer, integer ) -> PointCoord
point_rel_omt
🇫 Function --> ( integer, integer ) -> PointCoord
point_rel_seg
🇫 Function --> ( integer, integer ) -> PointCoord
point_rel_sm
🇫 Function --> ( integer, integer ) -> PointCoord
point_rel_veh
🇫 Function --> ( integer, integer ) -> PointCoord
point_seg_mmr
🇫 Function --> ( integer, integer ) -> PointCoord
point_seg_ms
🇫 Function --> ( integer, integer ) -> PointCoord
point_seg_omt
🇫 Function --> ( integer, integer ) -> PointCoord
point_seg_sm
🇫 Function --> ( integer, integer ) -> PointCoord
point_sm_ms
🇫 Function --> ( integer, integer ) -> PointCoord
project_combine
🇫 Function --> ( coarse: any, fine: any ) -> nil | PointCoord | TripointCoord
Combines a coarse coordinate with a remainder from project_remain. Returns
PointCoordorTripointCoorddepending on the inputs, or nil if the pair is incompatible.
project_remain
🇫 Function --> ( coord: any, scale: string ) -> (nil | PointCoord | TripointCoord, PointCoord?)
Splits a
PointCoordorTripointCoordinto a coarser coordinate plus a remainder.Pointinput returnsPointCoord,PointCoord; tripoint input returnsTripointCoord,PointCoord. Returns nil, nil if the split is not valid.
project_remain_mmr
🇫 Function --> ( coord: any ) -> (nil | PointCoord | TripointCoord, PointCoord?)
Shortcut for
project_remain(coord, "mmr").
project_remain_om
🇫 Function --> ( coord: any ) -> (nil | PointCoord | TripointCoord, PointCoord?)
Shortcut for
project_remain(coord, "om").
project_remain_omt
🇫 Function --> ( coord: any ) -> (nil | PointCoord | TripointCoord, PointCoord?)
Shortcut for
project_remain(coord, "omt").
project_remain_seg
🇫 Function --> ( coord: any ) -> (nil | PointCoord | TripointCoord, PointCoord?)
Shortcut for
project_remain(coord, "seg").
project_remain_sm
🇫 Function --> ( coord: any ) -> (nil | PointCoord | TripointCoord, PointCoord?)
Shortcut for
project_remain(coord, "sm").
project_to
🇫 Function --> ( coord: any, scale: string ) -> nil | PointCoord | TripointCoord
Projects a
PointCoordorTripointCoordto another scale, preserving its origin and point dimension. Returns nil if the conversion is not valid.
project_to_mmr
🇫 Function --> ( coord: any ) -> nil | PointCoord | TripointCoord
Shortcut for
project_to(coord, "mmr").
project_to_ms
🇫 Function --> ( coord: any ) -> nil | PointCoord | TripointCoord
Shortcut for
project_to(coord, "ms").
project_to_om
🇫 Function --> ( coord: any ) -> nil | PointCoord | TripointCoord
Shortcut for
project_to(coord, "om").
project_to_omt
🇫 Function --> ( coord: any ) -> nil | PointCoord | TripointCoord
Shortcut for
project_to(coord, "omt").
project_to_seg
🇫 Function --> ( coord: any ) -> nil | PointCoord | TripointCoord
Shortcut for
project_to(coord, "seg").
project_to_sm
🇫 Function --> ( coord: any ) -> nil | PointCoord | TripointCoord
Shortcut for
project_to(coord, "sm").
project_to_veh
🇫 Function --> ( coord: any ) -> nil | PointCoord | TripointCoord
Shortcut for
project_to(coord, "veh").
rl_dist
🇫 Function --> ( lhs: Point, rhs: Point ) -> integer
🇫 Function --> ( lhs: Tripoint, rhs: Tripoint ) -> integer
🇫 Function --> ( lhs: PointCoord, rhs: PointCoord ) -> integer?
🇫 Function --> ( lhs: TripointCoord, rhs: TripointCoord ) -> integer?
Rectilinear distance between two raw coordinates, or between two typed coordinates with matching origin and scale. Returns nil if the typed coordinates are incompatible.
square_dist
🇫 Function --> ( lhs: Point, rhs: Point ) -> integer
🇫 Function --> ( lhs: Tripoint, rhs: Tripoint ) -> integer
🇫 Function --> ( lhs: PointCoord, rhs: PointCoord ) -> integer?
🇫 Function --> ( lhs: TripointCoord, rhs: TripointCoord ) -> integer?
Chebyshev distance between two raw coordinates, or between two typed coordinates with matching origin and scale. Returns nil if the typed coordinates are incompatible.
submap_tiles
🇫 Function --> ( ) -> PointCoord[]
Returns every map-square offset within one submap as
PointCoordvalues.
tinymap_tiles
🇫 Function --> ( ) -> PointCoord[]
Returns every map-square offset within the tinymap as
PointCoordvalues.
trig_dist
🇫 Function --> ( lhs: Point, rhs: Point ) -> number
🇫 Function --> ( lhs: Tripoint, rhs: Tripoint ) -> number
🇫 Function --> ( lhs: PointCoord, rhs: PointCoord ) -> number?
🇫 Function --> ( lhs: TripointCoord, rhs: TripointCoord ) -> number?
Euclidean distance between two raw coordinates, or between two typed coordinates with matching origin and scale. Returns nil if the typed coordinates are incompatible.
tripoint
🇫 Function --> ( string, string, Tripoint ) -> TripointCoord
🇫 Function --> ( string, string, integer, integer, integer ) -> TripointCoord
tripoint_abs_mmr
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_abs_ms
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_abs_om
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_abs_omt
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_abs_seg
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_abs_sm
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_bub_ms
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_bub_sm
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_mmr_ms
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_mmr_omt
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_mmr_sm
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_mnt_veh
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_om_mmr
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_om_ms
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_om_omt
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_om_seg
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_om_sm
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_omt_ms
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_omt_sm
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_rel_mmr
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_rel_ms
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_rel_om
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_rel_omt
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_rel_seg
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_rel_sm
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_rel_veh
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_seg_mmr
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_seg_ms
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_seg_omt
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_seg_sm
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
tripoint_sm_ms
🇫 Function --> ( integer, integer, integer ) -> TripointCoord
date_time
System date and time API.
Members
day
🇫 Function --> ( ) -> integer
hour
🇫 Function --> ( ) -> integer
0 -> 23
millisecond
🇫 Function --> ( ) -> integer
minute
🇫 Function --> ( ) -> integer
month
🇫 Function --> ( ) -> integer
second
🇫 Function --> ( ) -> integer
weekday
🇫 Function --> ( ) -> integer
Days since Saturday.
weekday_str
🇫 Function --> ( ) -> string
year
🇫 Function --> ( ) -> integer
gapi
Global game methods
Members
abs_to_bub
🇫 Function --> ( TripointAbsSm ) -> TripointBubSm
abs_to_bub
🇫 Function --> ( TripointAbsMs ) -> TripointBubMs
add_msg
🇫 Function --> ( MsgType, any )
🇫 Function --> ( any )
add_npc_follower
🇫 Function --> ( Npc )
add_on_every_x_hook
🇫 Function --> ( TimeDuration, function )
before_time_starts
🇫 Function --> ( ) -> TimePoint
bodytemp_cold
🇫 Function --> ( ) -> integer
bodytemp_hot
🇫 Function --> ( ) -> integer
bodytemp_norm
🇫 Function --> ( ) -> integer
bub_to_abs
🇫 Function --> ( TripointBubMs ) -> TripointAbsMs
bub_to_abs
🇫 Function --> ( TripointBubSm ) -> TripointAbsSm
call_builtin_examine
🇫 Function --> ( string, Player, TripointBubMs )
Run a built-in examine action at a position.
choose_adjacent
🇫 Function --> ( string, boolean? ) -> TripointBubMs?
choose_adjacent_highlight
🇫 Function --> ( string, string, ActionId, boolean? ) -> TripointBubMs?
🇫 Function --> ( string, string, bool, boolean? ) -> TripointBubMs?
choose_adjacent_uilist
🇫 Function --> ( string, string, function, function ) -> TripointBubMs?
choose_area
🇫 Function --> ( string, TripointBubMs, boolean ) -> (TripointBubMs, TripointBubMs)?
choose_direction
🇫 Function --> ( string, boolean? ) -> TripointRelMs?
create_item
🇫 Function --> ( ItypeId, integer ) -> Detached<Item>
Spawns a new item. Same as
Item::spawn
current_turn
🇫 Function --> ( ) -> TimePoint
direction_from
🇫 Function --> ( TripointCoord ) -> Direction
Get direction from a relative tripoint coordinate delta.
direction_name
🇫 Function --> ( Direction ) -> string
Get direction name from direction enum
get_all_creatures
🇫 Function --> ( ) -> table
Returns all active creatures (monsters, NPCs, and the player) as a Lua array.
get_all_monsters
🇫 Function --> ( ) -> table
Returns all active monsters as a Lua array.
get_all_npcs
🇫 Function --> ( ) -> table
Returns all active NPCs as a Lua array.
get_avatar
🇫 Function --> ( ) -> Avatar
get_character_at
🇫 Function --> ( TripointBubMs, boolean? ) -> Character
🇫 Function --> ( Tripoint, boolean? ) -> Character
get_creature_at
🇫 Function --> ( TripointBubMs, boolean? ) -> Creature
🇫 Function --> ( Tripoint, boolean? ) -> Creature
get_distribution_grid_tracker
🇫 Function --> ( ) -> DistributionGridTracker
get_lua_log
🇫 Function --> ( integer ) -> table
Get recent Lua console log entries. Returns array of { level=string, text=string, from_user=bool }.
get_map
🇫 Function --> ( ) -> Map
get_messages
🇫 Function --> ( integer ) -> table
Get recent player message log entries. Returns array of { time=string, text=string }.
get_monster_at
🇫 Function --> ( TripointBubMs, boolean? ) -> Monster
🇫 Function --> ( Tripoint, boolean? ) -> Monster
get_monsters_near_omt
🇫 Function --> ( table ) -> table
Returns active monsters near an absolute overmap terrain tile as a Lua array.
Takes a table with keys:center,radius, and optionalignore_z.
get_npc_at
🇫 Function --> ( TripointBubMs, boolean? ) -> Npc
🇫 Function --> ( Tripoint, boolean? ) -> Npc
get_npcs_near_omt
🇫 Function --> ( table ) -> table
Returns active NPCs near an absolute overmap terrain tile as a Lua array.
Takes a table with keys:center,radius, and optionalignore_z.
get_overmap_buffer
🇫 Function --> ( ) -> OvermapBuffer
Get the global overmap buffer
get_player_pets
🇫 Function --> ( ) -> table
Get the player's pet monsters
get_simulated_npcs
🇫 Function --> ( ) -> table
Returns NPCs in simulated (fully loaded, AI-eligible) submaps as a Lua array.
light_ambient_lit
🇫 Function --> ( ) -> number
look_around
🇫 Function --> ( ) -> TripointBubMs?
place_monster_around
🇫 Function --> ( MonsterTypeId, TripointBubMs, integer ) -> Monster
🇫 Function --> ( MonsterTypeId, Tripoint, integer ) -> Monster
place_monster_at
🇫 Function --> ( MonsterTypeId, TripointBubMs ) -> Monster
🇫 Function --> ( MonsterTypeId, Tripoint ) -> Monster
place_player_local_at
🇫 Function --> ( TripointBubMs )
Teleports player to local coordinates within active map
place_player_overmap_at
🇫 Function --> ( TripointAbsOmt )
Teleports player to absolute coordinate in overmap
play_ambient_variant_sound
🇫 Function --> ( string, string, integer, SfxChannel, integer, number, integer )
play_variant_sound
🇫 Function --> ( string, string, integer )
🇫 Function --> ( string, string, integer, Angle, number, number )
register_action_menu_entry
🇫 Function --> ( table )
Register a Lua-defined action menu entry in the in-game action menu.
remove_npc_follower
🇫 Function --> ( Npc )
rng
🇫 Function --> ( integer, integer ) -> integer
six_cardinal_directions
🇫 Function --> ( ) -> TripointRelOmt[]
Get the six cardinal overmap-terrain direction offsets (N, S, E, W, Up, Down).
spawn_hallucination
🇫 Function --> ( TripointBubMs ) -> boolean
🇫 Function --> ( Tripoint ) -> boolean
turn_zero
🇫 Function --> ( ) -> TimePoint
gdebug
Debugging and logging API.
Members
clear_lua_log
🇫 Function --> ( )
debugmsg
🇫 Function --> ( any )
log_error
🇫 Function --> ( any )
log_info
🇫 Function --> ( any )
log_warn
🇫 Function --> ( any )
reload_lua_code
🇫 Function --> ( )
save_game
🇫 Function --> ( ) -> boolean
set_log_capacity
🇫 Function --> ( integer )
hooks
Documentation for hooks
Members
on_character_death
🇫 Function --> ( params: table )
Called when a character is dead.
The hook receives a table with keys:
on_character_display_skill_action
🇫 Function --> ( params: table )
Called when a skill is confirmed on the character display (
@) skill tab.
The hook receives a table with keys:
on_character_display_skill_info
🇫 Function --> ( params: table )
Called when drawing skill info on the character display (
@) skill tab.
The hook receives a table with keys:
on_character_effect
🇫 Function --> ( params: table )
Called when character is on the effect which has
EFFECT_LUA_ON_TICKflag.
The hook receives a table with keys:
on_character_effect_added
🇫 Function --> ( params: table )
Called when character gets the effect which has
EFFECT_LUA_ON_ADDEDflag.
The hook receives a table with keys:
on_character_effect_removed
🇫 Function --> ( params: table )
Called when character loses the effect which has
EFFECT_LUA_ON_REMOVEDflag.
The hook receives a table with keys:
on_character_reset_stats
🇫 Function --> ( params: table )
Called when character stat gets reset.
The hook receives a table with keys:
character(Character)
on_character_try_move
🇫 Function --> ( params: table )
Called after on_player_try_move or on_npc_try_move regardless of whether the specific hook vetoed.
All registered callbacks run; if any returns false, movement is blocked.
The hook receives a table with keys:
char(Character)from(TripointBubMs)to(TripointBubMs)movement_mode(CharacterMoveMode)via_ramp(bool)mounted(bool)mount(Creature, if mounted)
Return false to block the move.
on_creature_blocked
🇫 Function --> ( params: table )
Called when a character successfully blocks.
The hook receives a table with keys:
char(Character)source(Creature)bodypart_id(BodyPartTypeId)damage_instance(DamageInstance)damage_blocked(float)
on_creature_dodged
🇫 Function --> ( params: table )
Called when a character or monster successfully dodges.
The hook receives a table with keys:
on_creature_loaded
🇫 Function --> ( params: table )
Called when any creature is loaded onto the active map.
This is the base hook;on_monster_loadedandon_npc_loadedalso trigger this.
The hook receives a table with keys:
creature(Creature)
on_creature_melee_attacked
🇫 Function --> ( params: table )
Called after a character or monster has attacked in melee.
The hook receives a table with keys:
on_creature_performed_technique
🇫 Function --> ( params: table )
Called when a character has performed a technique.
The hook receives a table with keys:
char(Character)technique(MartialArtsTechniqueRaw)target(Creature)damage_instance(DamageInstance)move_cost(integer)
on_creature_spawn
🇫 Function --> ( params: table )
Called when any creature is spawned for the first time.
This is the base hook;on_monster_spawnandon_npc_spawnalso trigger this.
The hook receives a table with keys:
creature(Creature)
on_dialogue_end
🇫 Function --> ( params: table )
Called when the dialogue window closes.
The hook receives a table with keys:
npc(NPC): The NPC speaking
on_dialogue_option
🇫 Function --> ( params: table )
Called when a dialogue option is selected.
The hook receives a table with keys:
npc(NPC): The NPC speakingnext_topic(string): The topic that was selected
Return a new talk_topic id to add it as the next topic.
on_dialogue_start
🇫 Function --> ( params: table )
Called just before the dialogue window opens and the first topic is chosen.
The hook receives a table with keys:
npc(NPC): The NPC speakingnext_topic(string): The topic that will be shown first
Return a new talk_topic id to add it as the next topic.
on_elevator_try_use
🇫 Function --> ( params: table )
Called before the player uses elevator controls.
All registered callbacks run; if any returns false, elevator use is blocked.
The hook receives a table with keys:
player(Player)pos(TripointBubMs)om_terrain(string)
Return false to block elevator use.
on_every_x
🇫 Function --> ( table )
Called every in-game period
on_explosion_start
🇫 Function --> ( params: table )
Called when an explosion starts.
The hook receives a table with keys:
pos(TripointBubMs)damage(int)radius(int)fire(bool)
on_game_load
🇫 Function --> ( )
Called right after game has loaded.
on_game_save
🇫 Function --> ( )
Called when game is about to save.
on_game_started
🇫 Function --> ( )
Called when the game has first started.
on_mapgen_postprocess
🇫 Function --> ( params: table )
Called right after mapgen has completed.
The hook receives a table with keys:
on_mission_end
🇫 Function --> ( params: table )
Called right after mission has ended.
The hook receives a table with keys:
mission_type(mission_type): The type of the mission.mission(mission): The mission instance.success(bool): Successful if true else failed.
on_mission_start
🇫 Function --> ( params: table )
Called right after mission has started.
The hook receives a table with keys:
mission_type(mission_type): The type of the mission.mission(mission): The mission instance.
on_mon_death
🇫 Function --> ( params: table )
Called when a monster is dead.
The hook receives a table with keys:
on_mon_effect
🇫 Function --> ( params: table )
Called when character is on the effect which has
EFFECT_LUA_ON_TICKflag.
The hook receives a table with keys:
on_mon_effect_added
🇫 Function --> ( params: table )
Called when monster gets the effect which has
EFFECT_LUA_ON_ADDEDflag.
The hook receives a table with keys:
on_mon_effect_removed
🇫 Function --> ( params: table )
Called when monster loses the effect which has
EFFECT_LUA_ON_REMOVEDflag.
The hook receives a table with keys:
on_monster_loaded
🇫 Function --> ( params: table )
Called when a monster is loaded onto the active map.
Also triggerson_creature_loaded.
The hook receives a table with keys:
monster(Monster)
on_monster_spawn
🇫 Function --> ( params: table )
Called when a monster is spawned for the first time.
Also triggerson_creature_spawn.
Note: monsters spawned via mapgen submap spawn points will fire this hook,
but monsters materialized from overmap monster groups may not.
The hook receives a table with keys:
monster(Monster)
on_monster_try_move
🇫 Function --> ( params: table )
Called when a monster attempts to move.
All registered callbacks run; if any returns false, movement is blocked.
The hook receives a table with keys:
monster(Monster)from(TripointBubMs)to(TripointBubMs)force(bool): If the monster move call was forced
Return false to block the move.
on_npc_interaction
🇫 Function --> ( params: table )
Called when the player interacts with an NPC.
The hook receives a table with keys:
npc(NPC): The NPC being interacted with
on_npc_loaded
🇫 Function --> ( params: table )
Called when an NPC is loaded onto the active map.
Also triggerson_creature_loaded.
The hook receives a table with keys:
npc(Npc)
on_npc_spawn
🇫 Function --> ( params: table )
Called when an NPC is spawned for the first time.
Also triggerson_creature_spawn.
The hook receives a table with keys:
npc(Npc)
on_npc_try_move
🇫 Function --> ( params: table )
Called when an NPC attempts to move.
All registered callbacks run; if any returns false, movement is blocked.
The hook receives a table with keys:
npc(Npc)from(TripointBubMs)to(TripointBubMs)movement_mode(CharacterMoveMode)via_ramp(bool)mounted(bool)mount(Creature, if mounted)
Return false to block the move.
on_player_try_move
🇫 Function --> ( params: table )
Called when the player attempts to move.
All registered callbacks run; if any returns false, movement is blocked.
The hook receives a table with keys:
player(Player)from(TripointBubMs)to(TripointBubMs)movement_mode(CharacterMoveMode)via_ramp(bool)mounted(bool)mount(Creature, if mounted)
Return false to block the move.
on_shoot
🇫 Function --> ( params: table )
Called when shot(s) is fired from a gun.
The hook receives a table with keys:
shooter(Character)target_pos(TripointBubMs)shots(int)gun(item)ammo(item): ForRELOAD_AND_SHOOTguns like a bow. On the others, it returnsnilvalue.
on_throw
🇫 Function --> ( params: table )
Called when an item is thrown.
The hook receives a table with keys:
thrower(Character)target_pos(TripointBubMs)throw_from_pos(TripointBubMs)thrown(item)
on_try_monster_interaction
🇫 Function --> ( params: table )
Called when the player tries to interact with a monster.
The hook receives a table with keys:
monster(Monster): The monster being interacted with
Return false to prevent monster interaction actions from running.
on_try_npc_interaction
🇫 Function --> ( params: table )
Called when the player tries to interact with an NPC.
The hook receives a table with keys:
npc(NPC): The NPC being interacted with
Return false to prevent the npc interaction menu from appearing.
on_weather_changed
🇫 Function --> ( params: table )
Called when the weather has changed.
The hook receives a table with keys:
weather_id(string): Current weather IDold_weather_id(string): Previous weather IDtemperature(float): Current temperature in Celsiustemperature_f(float): Current temperature in Fahrenheitwindspeed(float): Wind speedwinddirection(integer): Wind direction in degreeshumidity(float): Humidity percentagepressure(float): Atmospheric pressureis_sheltered(boolean): Whether player is sheltered
on_weather_updated
🇫 Function --> ( params: table )
Called every 5 minutes when weather data is updated.
The hook receives a table with keys:
weather_id(string): Current weather IDtemperature(float): Current temperature in Celsiustemperature_f(float): Current temperature in Fahrenheitwindspeed(float): Wind speedwinddirection(integer): Wind direction in degreeshumidity(float): Humidity percentagepressure(float): Atmospheric pressureis_sheltered(boolean): Whether player is sheltered
locale
Localization API.
Members
gettext
🇫 Function --> ( string ) -> string
Expects english source string, returns translated string.
pgettext
🇫 Function --> ( string, string ) -> string
First is context string. Second is english source string.
vgettext
🇫 Function --> ( string, string, integer ) -> string
First is english singular string, second is english plural string. Number is amount to translate for.
vpgettext
🇫 Function --> ( string, string, string, integer ) -> string
First is context string. Second is english singular string. third is english plural. Number is amount to translate for.
monster_groups
Monster group definitions and helpers
Members
get_all
🇫 Function --> ( ) -> MonsterGroupRaw[]
Get all monster group definitions.
get_all_ids
🇫 Function --> ( ) -> MonsterGroupId[]
List all monster group ids currently loaded.
get_group
🇫 Function --> ( MonsterGroupId ) -> MonsterGroupRaw
Get a monster group definition by id.
get_monsters_from_group
🇫 Function --> ( MonsterGroupId ) -> MonsterTypeId[]
Get the monster ids directly listed in a group (default monster first).
monster_types
Monster type definitions and helpers
Members
get_all_ids
🇫 Function --> ( ) -> MonsterTypeId[]
List all monster type ids currently loaded.
overmapbuffer
Global overmap buffer interface for finding and inspecting overmap terrain.
Members
add_grid_connection
🇫 Function --> ( TripointAbsOmt, TripointAbsOmt ) -> boolean
Add an electric grid connection between two positions. Returns true on success.
check_ot
🇫 Function --> ( string, OtMatchType, TripointAbsOmt ) -> boolean
Check if the terrain at the given position matches the type and match mode. Returns boolean.
create_horde
🇫 Function --> ( table ) -> Mongroup
Create a monster horde at the given absolute OMT position. Pass a table with fields: type (mongroup_id, required), pos (TripointAbsOmt, required), radius (int), population (int), horde (bool), behaviour (string), diffuse (bool), target (TripointAbsOmt).
drain_fluid_grid_liquid_charges
🇫 Function --> ( TripointAbsOmt, ItypeId, integer ) -> integer
Drain liquid charges from the fluid grid at the given TripointAbsOmt position. Returns the number removed.
electric_grid_at
🇫 Function --> ( TripointAbsOmt ) -> TripointAbsOmt[]
Get all overmap tiles belonging to the electric grid at the given position. Returns TripointAbsOmt values.
electric_grid_connectivity_at
🇫 Function --> ( TripointAbsOmt ) -> TripointRelOmt[]
Get all electric grid connections from the given position. Returns TripointRelOmt offsets.
find_all
🇫 Function --> ( TripointAbsOmt, OmtFindParams ) -> TripointAbsOmt[]
Find all overmap terrain tiles matching the given parameters. Returns TripointAbsOmt values.
find_closest
🇫 Function --> ( TripointAbsOmt, OmtFindParams ) -> TripointAbsOmt?
Find the closest overmap terrain tile matching the given parameters. Returns TripointAbsOmt or nil if not found.
find_random
🇫 Function --> ( TripointAbsOmt, OmtFindParams ) -> TripointAbsOmt?
Find a random overmap terrain tile matching the given parameters. Returns TripointAbsOmt or nil if not found.
fluid_grid_at
🇫 Function --> ( TripointAbsOmt ) -> TripointAbsOmt[]
Get all overmap tiles belonging to the fluid grid at the given TripointAbsOmt position. Returns TripointAbsOmt values.
fluid_grid_connectivity_at
🇫 Function --> ( TripointAbsOmt ) -> TripointRelOmt[]
Get all fluid grid connections from the given TripointAbsOmt position. Returns TripointRelOmt offsets.
fluid_grid_liquid_charges_at
🇫 Function --> ( TripointAbsOmt, ItypeId ) -> integer
Get the available charges of a liquid in the fluid grid at the given TripointAbsOmt position.
fluid_grid_would_contaminate
🇫 Function --> ( TripointAbsOmt, ItypeId ) -> boolean
Check whether adding a liquid would contaminate the fluid grid at the given TripointAbsOmt position.
get_note
🇫 Function --> ( TripointAbsOmt ) -> string?
Get a player note at the given position. Returns string or nil.
has_horde
🇫 Function --> ( TripointAbsOmt ) -> boolean
Check if a horde is present at the given overmap tile.
horde_count
🇫 Function --> ( TripointAbsOmt ) -> integer
Count hordes influencing the given overmap tile (absolute OMT coordinates).
horde_size
🇫 Function --> ( TripointAbsOmt ) -> integer
Get the estimated size of the horde at the given overmap tile.
hordes_at
🇫 Function --> ( TripointAbsOmt ) -> Mongroup[]
List hordes influencing the given overmap tile (absolute OMT coordinates).
is_explored
🇫 Function --> ( TripointAbsOmt ) -> boolean
Check if the terrain at the given position has been explored by the player. Returns boolean.
monster_groups_at
🇫 Function --> ( TripointAbsOmt ) -> Mongroup[]
List monster groups influencing the given overmap tile (absolute OMT coordinates).
move_hordes
🇫 Function --> ( )
Advance horde movement across all loaded overmaps.
remove_grid_connection
🇫 Function --> ( TripointAbsOmt, TripointAbsOmt ) -> boolean
Remove an electric grid connection between two positions. Returns true on success.
reveal
🇫 Function --> ( TripointAbsOmt, integer, function? ) -> boolean
Reveal a square area around a TripointAbsOmt center on the overmap. Returns true if any new tiles were revealed. Optional filter callback receives oter_id and should return true to reveal that tile.
seen
🇫 Function --> ( TripointAbsOmt ) -> boolean
Check if the terrain at the given position has been seen by the player. Returns boolean.
set_note
🇫 Function --> ( TripointAbsOmt, string? )
Set a player note at the given position. Pass nil or empty string to clear.
set_seen
🇫 Function --> ( TripointAbsOmt, boolean? )
Set the seen status of terrain at the given position.
signal_hordes
🇫 Function --> ( TripointAbsSm, integer )
Signal nearby hordes toward an absolute submap position with the given strength.
ter
🇫 Function --> ( TripointAbsOmt ) -> OterIntId
Get the overmap terrain type at the given position. Returns an oter_id.
sidebar
Sidebar utility functions.
Members
clear_widgets
🇫 Function --> ( )
Clear all registered Lua sidebar widgets.
get_layout_id
🇫 Function --> ( ) -> string
Returns current sidebar layout id (e.g. classic, compact, labels).
register_widget
🇫 Function --> ( table )
Register a Lua sidebar widget. Options: id(string), name(string), height(int, use -2 to fill remaining space), order(int, 1-based), draw(function), default_toggle(bool), redraw_every_frame(bool), panel_visible(bool|function), render(function). draw(width, height) returns an array of entries: each entry is string or table { text=string, color=
Color|string }. text may include color tags like <color_red>text for multi-color lines.
tests_lib
Library for testing purposes
Members
my_awesome_lambda_1
🇫 Function --> ( ) -> integer
my_awesome_lambda_2
🇫 Function --> ( ) -> integer