Common
Functions
remove_kv
Clear the key value of the instance.
Parameters
cli.remove_kv (_ins, _value)
remove_unit_kv
Clear unit type key.
Parameters
cli.remove_unit_kv (_id, _value)
remove_item_kv
Clear item type key.
Parameters
cli.remove_item_kv (_id, _value)
remove_ability_kv
Clear skill type key.
Parameters
cli.remove_ability_kv (_id, _value)
remove_prefab_kv
Clear Destroyables/Technology/Projectiles/Magic Effects/Type Keys.
Parameters
cli.remove_prefab_kv (_id, _value)
cleartag
Clear label.
Parameter
create_random_pool
Create a random pool.
cli.create_random_pool ()
set_weight_of_specified_number
Set random pool to specify integer weight.
Parameters
cli.set_weight_of_specified_number (pool, number, weight)
remove_specified_number
The random pool removes the specified integer.
Parameters
cli.remove_specified_number (pool, number)
pick_random_pool
Traverse the random pool.
display_info_to_player
Tip the player.
Parameters
cli.display_info_to_player (player, msg, is_language)
increase_weight_of_specified_number
The random pool increases the specified integer weight.
Parameters
cli.increase_weight_of_specified_number (pool, number, weight)
separate_string
Split string array.
Parameters
cli.separate_string (str_list, str1, str2)
get_camp_by_camp_id
Get camp.
Parameter
cli.get_camp_by_camp_id (id)
stringtobool
String type to bool.
Parameter
set_cascaded_shadow_distance
Set shadow distance.
Parameter
cli.set_cascaded_shadow_distance (_dis)
remove_timer
Delete timer.
Parameter
pause_timer
Pause timer.
Parameter
resume_timer
Resume timer.
Parameter
set_terrain_texture_at_a_specified_point
Set the terrain texture for a point.
Parameters
cli.set_terrain_texture_at_a_specified_point (point, terrain_type_name, range, area_type_name)
replace_specified_terrain_texture_in_region
Replace the specified terrain texture within the area.
Parameters
cli.replace_specified_terrain_texture_in_region (area, terrain_type_name, target_terrain_type_name)
set_region_weather
Set regional weather.
Parameters
cli.set_region_weather (area, weather_name)
set_global_weather
Set global weather.
Parameter
cli.set_global_weather (weather_name)
set_player_filter_effect
Set player's filter effect.
Parameters
cli.set_player_filter_effect (player, filter_name)
display_player_terrain_texture
Show/Hide Player Surface Textures.
Parameters
cli.display_player_terrain_texture (player, is_visible)
enable_vignetting
Set dark corner switch.
Parameters
cli.enable_vignetting (player, is_enable)
set_vignetting_size
Set vignette size.
Parameters
cli.set_vignetting_size (player, size)
set_vignetting_breathing_period
Set vignette breathing cycle.
Parameters
cli.set_vignetting_breathing_period (player, circle_time)
set_vignetting_changing_amplitude
Set the variation range of vignetting.
Parameters
cli.set_vignetting_changing_amplitude (player, range)
set_vignetting_color
Set vignette color.
Parameters
cli.set_vignetting_color (player, red, green, blue, alpha)
set_fog_attribute
Set fog properties.
Parameters
cli.set_fog_attribute (fog, direction, pos_x, pos_y, pos_z, scale_x, scale_y, scale_z, red, green, blue, concentration, speed)
set_cascaded_shadow_distanc
Set shadow distance.
Parameter
cli.set_cascaded_shadow_distance (distance)
set_cascaded_shadow_enable
Switch Cascaded Shadows
Parameter
cli.set_cascaded_shadow_enable (is_enable)
set_post_effect
Switch style for player
Parameters
cli.set_post_effect (player, processing_name)
set_table_value
Set the value of a one-dimensional table
Parameters
cli.set_table_value (table, value, key)
set_table_value_multi
Set the value of multidimensional table
Parameters
cli.set_table_value_multi (table, value, key, field)
insert_table_value
Insert values into the table.
Parameters
cli.insert_table_value (table, value, index)
remove_nth_table_value
Delete the N-th value of a one-dimensional table.
Parameters
cli.remove_nth_table_value (table, index)
pick_table
Traverse the table.
Parameter
pick_table_ordered
Traversing the table (preserving order).
Parameter
cli.pick_table_ordered (table)
dump_table
Print sheet.
Parameter
new_empty_table
Create empty table.
Parameter
Return
copy_table
Copy table.
Parameter
Return
pause_game
Pause game.
start_new_round_of_game
Start a new game.
Parameter
cli.start_new_round_of_game (is_quick_reset)
enable_soft_pause
Enable soft pause.
resume_soft_pause
Resume soft pause.
set_damage_factor
Set damage factor.
Parameters
cli.set_damage_factor (attack_type_name, armor_type_name, ratio)
set_compound_attributes
Set composite properties.
Parameters
cli.set_compound_attributes (primary_attribute_name, secondary_attr_name, value)
set_game_time_elapsing_rate
Set how fast game time passes.
Parameter
cli.set_game_time_elapsing_rate (speed)
set_game_time
Set game time.
Parameter
create_artificial_time
Create artificial time.
Parameters
cli.create_artificial_time (time, dur)
set_random_seed
Set random number seed.
Parameter
cli.set_random_seed (seed)
toggle_time_elapsing_is_on
Switching time lapse.
Parameter
cli.toggle_time_elapsing_is_on (is_on)
toggle_target_point_grassland_is_on
Grass at switch target point.
Parameters
cli.toggle_target_point_grassland_is_on (is_on, point)
clear
Empty.
Parameter
cli.clear (player_or_unit_group)
play_screen_particle_for_a_set_duration
Create screen effects.
Parameters
cli.play_screen_particle_for_a_set_duration (sfx_id, duration, player, is_on_fog)
set_variable
Set variable.
Parameters
cli.set_variable (key, value, type)
play_sound_for_player
Play sound.
Parameters
cli.play_sound_for_player (player, sound, is_loop, fade_in_time, fade_out_time)
stop_sound_for_player
Stop playing sound.
Parameters
cli.stop_sound_for_player (player, sound, is_immediately)
play_3d_sound_for_player
Play 3D sound.
Parameters
cli.play_3d_sound_for_player (player, sound, point, height, fade_in_time, fade_out_time, is_make_sure_play, is_loop)
follow_object_play_3d_sound_for_player
Play sound with unit.
Parameters
cli.follow_object_play_3d_sound_for_player (player, sound, unit, fade_in_time, fade_out_time, is_make_sure_play, is_loop)
set_sound_volume
Set sound volume.
Parameters
cli.set_sound_volume (player, sound, value)
print_to_dialog
Print log.
Parameters
cli.print_to_dialog (type, information)
test_show_message_tip
Display interface test information.
Parameters
cli.test_show_message_tip (information, time)
test_log_message
Record API test log (optional display).
Parameters
cli.test_log_message (information, time, is_center)
get_icon_id
Get the picture of the icon icon of the skill/buff/item/unit.
Parameter
get_obj_from_data
Get the contents of the data table.
Parameters
Return
cli.get_obj_from_data (data, string)
all_conditions_succeed
All conditions are met.
Parameter
Return
cli.all_conditions_succeed (conditions)
any_conditions_succeed
Either condition holds.
Parameter
Return
cli.any_conditions_succeed (conditions)
all_conditions_failed
None of the conditions is met.
Parameter
Return
cli.all_conditions_failed (conditions)
get_str_length
Get string length.
Parameter
Return
cli.get_str_length (_str)
pos_in_str
Index of the target character in the string.
Parameters
Return
cli.pos_in_str (_str1, _str2)
get_tech_max_level
Get the maximum level of technology.
Parameter
Return
cli.get_tech_max_level (_techid)
get_player_ui_pos_x
Get the player's mouse screen coordinate X.
Parameter
Return
cli.get_player_ui_pos_x (_player)
get_player_ui_pos_y
Get the player's mouse screen coordinate X.
Parameter
Return
cli.get_player_ui_pos_y (_player)
get_player_pointing_pos
Get the player's mouse coordinates.
Parameter
Return
cli.get_player_pointing_pos (_player)
get_instance_location_point
Get the location of the projectile/item/unit/destructible object.
Parameter
Return
cli.get_instance_location_point (_ins)
get_team
Get the team of the player/unit.
Parameter
Return
str_to_unit_command_type
String to unit command type.
Parameter
Return
cli.str_to_unit_command_type (_str)
str_to_point
String to point.
Parameter
Return
str_to_ability_cast_type
String transfer skill release type.
Parameter
Return
cli.str_to_ability_cast_type (_str)
str_to_link_sfx_key
String to link effect.
Parameter
Return
cli.str_to_link_sfx_key (_str)
str_to_role_relation
String to Player Relationship.
Parameter
Return
cli.str_to_role_relation (_str)
str_to_unit_type
String to unit classification.
Parameter
Return
cli.str_to_unit_type (_str)
str_to_unit_key
String to unit type.
Parameter
Return
cli.str_to_unit_key (_str)
str_to_unit_name
String to unit property.
Parameter
Return
cli.str_to_unit_name (_str)
str_to_item_key
String to item type.
Parameter
Return
cli.str_to_item_key (_str)
str_to_role_res
String to player attribute.
Parameter
Return
cli.str_to_role_res (_str)
str_to_role_status
String to player state.
Parameter
Return
cli.str_to_role_status (_str)
str_to_role_type
String to player control state.
Parameter
Return
cli.str_to_role_type (_str)
str_to_ability_key
String to skill type.
Parameter
Return
cli.str_to_ability_key (_str)
str_to_ability_type
String to skill slot type.
Parameter
Return
cli.str_to_ability_type (_str)
str_to_dest_key
String to destructible type.
Parameter
Return
cli.str_to_dest_key (_str)
str_to_project_key
String to projectile type.
Parameter
Return
cli.str_to_project_key (_str)
str_to_particle_sfx_key
String to special effect.
Parameter
Return
cli.str_to_particle_sfx_key (_str)
str_to_tech_key
String to technology type.
Parameter
Return
cli.str_to_tech_key (_str)
str_to_model_key
String to model type.
Parameter
Return
cli.str_to_model_key (_str)
str_to_modifier_key
String to magic effect type.
Parameter
Return
cli.str_to_modifier_key (_str)
str_to_modifier_effect_type
String to magic effect effect type.
Parameter
Return
cli.str_to_modifier_effect_type (_str)
str_to_modifier_type
String to magic effect category.
Parameter
Return
cli.str_to_modifier_type (_str)
str_to_camp
String to alignment.
Parameter
Return
str_to_keyboard_key
String to keyboard key.
Parameter
Return
cli.str_to_keyboard_key (_str)
str_to_mouse_key
String to mouse button.
Parameter
Return
cli.str_to_mouse_key (_str)
str_to_mouse_wheel
String to mouse wheel.
Parameter
Return
cli.str_to_mouse_wheel (_str)
str_to_store_key
String to platform prop type.
Parameter
Return
cli.str_to_store_key (_str)
str_to_damage_type
String to damage type.
Parameter
Return
cli.str_to_damage_type (_str)
str_to_unit_attr_type
String to unit attribute type.
Parameter
Return
cli.str_to_unit_attr_type (_str)
str_to_audio_key
String to sound type.
Parameter
Return
cli.str_to_audio_key (_str)
get_icon_id
Get pictures according to the picture ID.
Parameter
Return
move_to_pos
Move.
Parameters
Return
cli.move_to_pos (point, range)
stop
Stop.
Return
garrison
Stationed.
Parameter
Return
attack_move
Attack move.
Parameters
Return
cli.attack_move (point, range)
attack_target
Target.
Parameters
Return
cli.attack_target (unit, range)
move_along_path
Move along the path.
Parameters
Return
cli.move_along_path (path, patrol_mode_name, is_attack, nearby_start_point, is_deviate_return)
cast_ability
Release skills.
Parameters
Return
cli.cast_ability (ability, point1, point2, point3, unit, item, dest)
pick_up_item
Pick up items.
Parameter
Return
discard_item
Discarded items.
Parameters
Return
cli.discard_item (item, point)
give_item
Give items.
Parameters
Return
cli.give_item (item, unit)
use_item
Items used.
Parameters
Return
cli.use_item (item, point1, point2, point3, unit, target_item, dest)
follow
Follow.
Parameter
Return
empty
Empty command.
Return
table_length
Table length.
Parameter
Return
get_max_tech_level
Get the maximum level of technology.
Parameter
Return
cli.get_max_tech_level (tech_id)
get_tech_icon
Get tech icons.
Parameters
Return
cli.get_tech_icon (tech_id, index)
get_tech_type_from_event
Get the technology type in the event.
Return
cli.get_tech_type_from_event ()
get_tech_type_description
Get the description of the technology type.
Parameter
Return
cli.get_tech_type_description (tech_id)
get_tech_type_name
Get the name of the technology type.
Parameter
Return
cli.get_tech_type_name (tech_id)
get_current_game_mode
Get the current game mode.
Return
cli.get_current_game_mode ()
get_local_language_environment
Get locale.
Return
cli.get_local_language_environment ()
current_game_run_time
The time the game has been running.
Return
cli.current_game_run_time ()
get_current_game_time
Get the current time of the game.
Return
cli.get_current_game_time ()
get_damage_factor
Get damage factor.
Parameters
Return
cli.get_damage_factor (attack_type_name, area_type_name)
get_coefficient
Get the slave coefficient of the 3D attribute.
Parameters
Return
cli.get_coefficient (primary_attribute_name, secondary_attr_name)
get_game_environment_of_current_round
Get the game environment of this game.
Return
cli.get_game_environment_of_current_round ()
get_global_archive
Get global archive.
Parameter
Return
cli.get_global_archive (name)
get_archive_rank_player_archive_value
Get integer save leaderboard player save value.
Parameters
Return
cli.get_archive_rank_player_archive_value (file, index)
if_pri_attr_state_open
Whether to enable 3D attributes or not.
Return
cli.if_pri_attr_state_open ()
get_mover_bound_projectiles
Get kinematically bound projectiles.
Return
cli.get_mover_bound_projectiles ()
get_tech_changed_level
Get the level of technology change.
Parameter
Return
cli.get_tech_changed_level (data)
trigger_modifier
Trigger magic effect.
Parameter
Return
cli.trigger_modifier (data)
tech_researched
Researched technology.
Return
get_unit_in_event
Get the units in the event.
Parameter
Return
cli.get_unit_in_event (data)
modifier_receiver
Magic effect carrier.
Parameter
Return
cli.modifier_receiver (data)
get_ability_owner
Get the owner of the skill.
Parameter
Return
cli.get_ability_owner (ability)
modifier_provider
Magic effect caster.
Parameter
Return
cli.modifier_provider (modifier)
ability_selected_target_item
The target item selected by the skill.
Parameters
Return
cli.ability_selected_target_item (ability, data)
picked_modifier
The magic effect traversed.
Return
player_that_triggered_current_event
The player who triggered the current event.
Parameter
Return
cli.player_that_triggered_current_event (data)
projectile_that_triggered_current_event
The projectile that triggered the current event.
Parameter
Return
cli.projectile_that_triggered_current_event (data)
ability_selected_target_unit
Get the unit selected by the skill.
Parameters
Return
cli.ability_selected_target_unit (ability, data)
get_modifier_stack_changed_value
Get the change value of the magic effect layer.
Parameter
Return
cli.get_modifier_stack_changed_value (data)
tech_upgraded_or_downgraded
Level-up technology.
Return
cli.tech_upgraded_or_downgraded ()
item_selected_in_picking_item_group
The selected item when traversing the item group.
Return
cli.item_selected_in_picking_item_group ()
level_changed_tech
Level-changing technology.
Return
cli.level_changed_tech ()
get_damage_or_healing_target_unit
Get the unit taking damage (healing).
Parameter
Return
cli.get_damage_or_healing_target_unit (data)
picked_unit_in_unit_group
Get the units traversed in the unit group.
Return
cli.picked_unit_in_unit_group ()
get_killer_unit
Get killer unit.
Parameter
Return
cli.get_killer_unit (data)
get_picked_projectile
Get the projectiles traversed.
Return
cli.get_picked_projectile ()
get_dead_unit
Get dead unit.
Parameter
Return
Get_Damage_or_Healing_Source_Unit
Get the unit dealing damage (healing).
Parameter
Return
cli.Get_Damage_or_Healing_Source_Unit (data)
unit_to_gain_item
Get item unit.
Return
unit_to_lose_item
Lost item unit.
Return
unit_to_use_item
Use item units.
Return
unit_to_change_stacks
Holder of items with varying stacks.
Return
cli.unit_to_change_stacks ()
get_unit_about_to_gain_modifier
Get units about to get magic effects.
Parameter
Return