Skip to content

$catch_stat

Player statistics.

25 natives. Read-only natives only look things up; the rest change something. Parameter types use the language's names (Types).

clear_staged_stats

$catch_stat.clear_staged_stats(user: User)

Clear the value of all staged stats for the given user.

ParameterTypeMeaning
userUserThe user for which to set the stat.

commit_staged_stats

$catch_stat.commit_staged_stats(user: User)

Commit the value of all staged stats for the given user.

ParameterTypeMeaning
userUserThe user for which to set the stat.

debug_build_key

$catch_stat.debug_build_key(player_stat: Reference, stat_period: int, map_type: int, rules_type: int, team_count: int, team_size: int, is_ranked: bool, use_throw_info: bool, throw_type: int, total_charge_level: int, ball_type: int)

Debug: Build a key with the given match information. Determine stat mode using its determinants.

ParameterTypeMeaning
player_statReferenceA reference to the player_stat for which to set the value.
stat_periodintThe stat period for which to set the stat. A value from the vcatch_stat_period_t enum
map_typeintThe map type to use for this player stat. A value from the vcatch_map_type_t enum.
rules_typeintThe rules type to use. A value from the vcatch_match_rules_type_t enum.
team_countintThe number of teams in the match.
team_sizeintThe number of players per team in the match.
is_rankedboolWhether or not the match is ranked.
use_throw_infoboolWhether or not throw info is included in the arguments.
throw_typeintThe throw type of the throw. A value from the vcatch_throw_type_t enum.
total_charge_levelintThe floor of the sum of the charge level and overcharge level of the ball being thrown. -1 to not use.
ball_typeintThe type of the ball being thrown. A value from the vcatch_ball_type_t enum.

debug_get_player_stat_base_key

read-only
$catch_stat.debug_get_player_stat_base_key(player_stat: Reference) -> string

Debug: Get a the base key of a player stat.

ParameterTypeMeaning
player_statReferenceThe player_stat file for which to get the base key.

Returns string: The base key for the given player_stat file.

debug_get_player_stat_is_period_lifetime

read-only
$catch_stat.debug_get_player_stat_is_period_lifetime(player_stat: Reference) -> bool

Debug: Get whether or not a player stat is tracked for the lifetime period.

ParameterTypeMeaning
player_statReferenceThe player_stat file to query.

Returns bool: Whether or not the given player is tracked for the lifetime period.

debug_get_player_stat_is_period_midnight_madness

read-only
$catch_stat.debug_get_player_stat_is_period_midnight_madness(player_stat: Reference) -> bool

Debug: Get whether or not a player stat is tracked for the midnight madness period.

ParameterTypeMeaning
player_statReferenceThe player_stat file to query.

Returns bool: Whether or not the given player is tracked for the midnight madness period.

debug_get_player_stat_is_period_seasonal

read-only
$catch_stat.debug_get_player_stat_is_period_seasonal(player_stat: Reference) -> bool

Debug: Get whether or not a player stat is tracked for the seasonal period.

ParameterTypeMeaning
player_statReferenceThe player_stat file to query.

Returns bool: Whether or not the given player is tracked for the season period.

debug_get_player_stat_requires_ball_type

read-only
$catch_stat.debug_get_player_stat_requires_ball_type(player_stat: Reference) -> bool

Debug: Get whether or not a player stat needs ball type info.

ParameterTypeMeaning
player_statReferenceThe player_stat file to query.

Returns bool: Whether or not the given player stat requires the ball type.

debug_get_player_stat_requires_charge_level

read-only
$catch_stat.debug_get_player_stat_requires_charge_level(player_stat: Reference) -> bool

Debug: Get whether or not a player stat needs charge level info.

ParameterTypeMeaning
player_statReferenceThe player_stat file to query.

Returns bool: Whether or not the given player stat requires the charge level.

debug_get_player_stat_requires_throw_type

read-only
$catch_stat.debug_get_player_stat_requires_throw_type(player_stat: Reference) -> bool

Debug: Get whether or not a player stat needs throw type info.

ParameterTypeMeaning
player_statReferenceThe player_stat file to query.

Returns bool: Whether or not the given player stat requires the throw type.

debug_get_staged_stats

read-only
$catch_stat.debug_get_staged_stats(user: User) -> list

Debug: Get a list of staged key/value pairs.

ParameterTypeMeaning
userUserThe user for which to get the stats.

Returns list: List of all staged stat key/value pairs for the given user.

get_player_stat

read-only
$catch_stat.get_player_stat(user: User, player_stat: Reference, stat_period: int, stat_mode: int, map_type: int, use_throw_info: bool, throw_type: int, total_charge_level: int, ball_type: int) -> int

Get the value of a persistent stat for the given user.

ParameterTypeMeaning
userUserThe user for which to get the stat.
player_statReferenceA reference to the player_stat for which to get the value.
stat_periodintThe stat period for which to get the stat. A value from the vcatch_stat_period_t enum
stat_modeintThe stat mode for which to get the stat. A value from the vcatch_stat_mode_t enum
map_typeintThe map type obtained from catch_world. A value from the vcatch_map_type_t enum.
use_throw_infoboolWhether or not throw info is included in the arguments.
throw_typeintThe throw type of the throw. A value from the vcatch_throw_type_t enum.
total_charge_levelintThe floor of the sum of the charge level and overcharge level of the ball being thrown. -1 to not use.
ball_typeintThe type of the ball being thrown. A value from the vcatch_ball_type_t enum.

Returns int: The persistent stat value.

get_player_stat_for_match

read-only
$catch_stat.get_player_stat_for_match(user: User, player_stat: Reference, stat_period: int, map_type: int, match_def: Reference, match_rules: Reference, use_throw_info: bool, throw_type: int, total_charge_level: int, ball_type: int, match_flow: int) -> int

Get the value of a persistent stat for the given user for this particular match.

ParameterTypeMeaning
userUserThe user for which to get the stat.
player_statReferenceA reference to the player_stat for which to set the value.
stat_periodintThe stat period for which to set the stat. A value from the vcatch_stat_period_t enum
map_typeintThe map type obtained from catch_world. A value from the vcatch_map_type_t enum.
match_defReferenceA match definition file reference .
match_rulesReferenceA match rules file reference.
use_throw_infoboolWhether or not throw info is included in the arguments.
throw_typeintThe throw type of the throw. A value from the vcatch_throw_type_t enum.
total_charge_levelintThe floor of the sum of the charge level and overcharge level of the ball being thrown. -1 to not use.
ball_typeintThe type of the ball being thrown. A value from the vcatch_ball_type_t enum.
match_flowintThe match flow that was matchamde into.

Returns int: The persistent stat value.

get_player_stat_from_key

read-only
$catch_stat.get_player_stat_from_key(user: User, stat_key: string, is_staged: bool) -> int

Get the value of a persistent stat for the given user.

ParameterTypeMeaning
userUserThe user for which to get the stat.
stat_keystringThe stat key.
is_stagedboolWhether or not the stat is staged.

Returns int: The stat value.

get_player_stat_sum_a_key_list_from_brag_def

read-only
$catch_stat.get_player_stat_sum_a_key_list_from_brag_def(user: User, player_brag_def: Reference) -> int

The get sum of the values from a_key_list from brag def.

ParameterTypeMeaning
userUserThe user for which to get the stat.
player_brag_defReferenceThe brag def.

Returns int: The stat value.

get_player_stat_sum_b_key_list_from_brag_def

read-only
$catch_stat.get_player_stat_sum_b_key_list_from_brag_def(user: User, player_brag_def: Reference) -> int

The get sum of the values from b_key_list from brag def.

ParameterTypeMeaning
userUserThe user for which to get the stat.
player_brag_defReferenceThe brag def.

Returns int: The stat value.

get_staged_player_stat

read-only
$catch_stat.get_staged_player_stat(user: User, player_stat: Reference, stat_period: int, stat_mode: int, map_type: int, use_throw_info: bool, throw_type: int, total_charge_level: int, ball_type: int) -> int

Get the value of a staged stat for the given user.

ParameterTypeMeaning
userUserThe user for which to get the stat.
player_statReferenceA reference to the player_stat for which to get the value.
stat_periodintThe stat period for which to get the stat. A value from the vcatch_stat_period_t enum
stat_modeintThe stat mode for which to get the stat. A value from the vcatch_stat_mode_t enum
map_typeintThe map type obtained from catch_world. A value from the vcatch_map_type_t enum.
use_throw_infoboolWhether or not throw info is included in the arguments.
throw_typeintThe throw type of the throw. A value from the vcatch_throw_type_t enum.
total_charge_levelintThe floor of the sum of the charge level and overcharge level of the ball being thrown. -1 to not use.
ball_typeintThe type of the ball being thrown. A value from the vcatch_ball_type_t enum.

Returns int: The staged stat value.

get_staged_player_stat_for_match

read-only
$catch_stat.get_staged_player_stat_for_match(user: User, player_stat: Reference, map_type: int, match_def: Reference, match_rules: Reference, use_throw_info: bool, throw_type: int, total_charge_level: int, ball_type: int, match_flow: int) -> int

Get the value of a staged stat for the given user for this particular match.

ParameterTypeMeaning
userUserThe user for which to get the stat.
player_statReferenceA reference to the player_stat for which to set the value.
map_typeintThe map type obtained from catch_world. A value from the vcatch_map_type_t enum.
match_defReferenceA match definition file reference .
match_rulesReferenceA match rules file reference.
use_throw_infoboolWhether or not throw info is included in the arguments.
throw_typeintThe throw type of the throw. A value from the vcatch_throw_type_t enum.
total_charge_levelintThe floor of the sum of the charge level and overcharge level of the ball being thrown. -1 to not use.
ball_typeintThe type of the ball being thrown. A value from the vcatch_ball_type_t enum.
match_flowintThe match flow that was matchamde into.

Returns int: The persistent stat value.

get_staged_player_stat_for_match_with_period

read-only
$catch_stat.get_staged_player_stat_for_match_with_period(user: User, player_stat: Reference, stat_period: int, map_type: int, match_def: Reference, match_rules: Reference, use_throw_info: bool, throw_type: int, total_charge_level: int, ball_type: int, match_flow: int) -> int

Get the value of a staged stat for the given user for this particular match.

ParameterTypeMeaning
userUserThe user for which to get the stat.
player_statReferenceA reference to the player_stat for which to set the value.
stat_periodintThe stat period for which to set the stat. A value from the vcatch_stat_period_t enum
map_typeintThe map type obtained from catch_world. A value from the vcatch_map_type_t enum.
match_defReferenceA match definition file reference .
match_rulesReferenceA match rules file reference.
use_throw_infoboolWhether or not throw info is included in the arguments.
throw_typeintThe throw type of the throw. A value from the vcatch_throw_type_t enum.
total_charge_levelintThe floor of the sum of the charge level and overcharge level of the ball being thrown. -1 to not use.
ball_typeintThe type of the ball being thrown. A value from the vcatch_ball_type_t enum.
match_flowintThe match flow that was matchamde into.

Returns int: The persistent stat value.

increment_staged_player_stat

$catch_stat.increment_staged_player_stat(user: User, player_stat: Reference, amount: int, stat_mode: int, map_type: int, use_throw_info: bool, throw_type: int, total_charge_level: int, ball_type: int, is_midnight_madness: bool)

Increment the value of a staged stat for the given user.

ParameterTypeMeaning
userUserThe user for which to set the stat.
player_statReferenceA reference to the player_stat for which to set the value.
amountintThe amount to increment the stat.
stat_modeintThe stat mode for which to get the stat. A value from the vcatch_stat_mode_t enum
map_typeintThe map type obtained from catch_world. A value from the vcatch_map_type_t enum.
use_throw_infoboolWhether or not throw info is included in the arguments.
throw_typeintThe throw type of the throw. A value from the vcatch_throw_type_t enum.
total_charge_levelintThe floor of the sum of the charge level and overcharge level of the ball being thrown. -1 to not use.
ball_typeintThe type of the ball being thrown. A value from the vcatch_ball_type_t enum.
is_midnight_madnessboolAre in current in midnight madness?

increment_staged_player_stat_for_match

$catch_stat.increment_staged_player_stat_for_match(user: User, player_stat: Reference, amount: int, map_type: int, match_def: Reference, match_rules: Reference, use_throw_info: bool, throw_type: int, total_charge_level: int, ball_type: int, match_flow: int, is_midnight_madness: bool)

Increment the value of a staged stat for the given user for this particular match.

ParameterTypeMeaning
userUserThe user for which to get the stat.
player_statReferenceA reference to the player_stat for which to set the value.
amountintThe amount to increment the stat.
map_typeintThe map type obtained from catch_world. A value from the vcatch_map_type_t enum.
match_defReferenceA match definition file reference .
match_rulesReferenceA match rules file reference.
use_throw_infoboolWhether or not throw info is included in the arguments.
throw_typeintThe throw type of the throw. A value from the vcatch_throw_type_t enum.
total_charge_levelintThe floor of the sum of the charge level and overcharge level of the ball being thrown. -1 to not use.
ball_typeintThe type of the ball being thrown. A value from the vcatch_ball_type_t enum.
match_flowintThe match flow that was matchamde into.
is_midnight_madnessboolAre in current in midnight madness?

set_player_stat

$catch_stat.set_player_stat(user: User, player_stat: Reference, value: int, stat_period: int, stat_mode: int, map_type: int, use_throw_info: bool, throw_type: int, total_charge_level: int, ball_type: int, match_flow: int)

Set the value of a persistent stat for the given user.

ParameterTypeMeaning
userUserThe user for which to set the stat.
player_statReferenceA reference to the player_stat for which to set the value.
valueintThe value to set for the stat.
stat_periodintThe stat period for which to set the stat. A value from the vcatch_stat_period_t enum
stat_modeintThe stat mode for which to get the stat. A value from the vcatch_stat_mode_t enum
map_typeintThe map type obtained from catch_world. A value from the vcatch_map_type_t enum.
use_throw_infoboolWhether or not throw info is included in the arguments.
throw_typeintThe throw type of the throw. A value from the vcatch_throw_type_t enum.
total_charge_levelintThe floor of the sum of the charge level and overcharge level of the ball being thrown. -1 to not use.
ball_typeintThe type of the ball being thrown. A value from the vcatch_ball_type_t enum.
match_flowintThe match flow that was matchamde into.

set_player_stat_for_match

$catch_stat.set_player_stat_for_match(user: User, player_stat: Reference, value: int, stat_period: int, map_type: int, match_def: Reference, match_rules: Reference, use_throw_info: bool, throw_type: int, total_charge_level: int, ball_type: int, match_flow: int)

Set the value of a persistent stat for the given user for this particular match.

ParameterTypeMeaning
userUserThe user for which to get the stat.
player_statReferenceA reference to the player_stat for which to set the value.
valueintThe value to set for the stat.
stat_periodintThe stat period for which to set the stat. A value from the vcatch_stat_period_t enum
map_typeintThe map type obtained from catch_world. A value from the vcatch_map_type_t enum.
match_defReferenceA match definition file reference .
match_rulesReferenceA match rules file reference.
use_throw_infoboolWhether or not throw info is included in the arguments.
throw_typeintThe throw type of the throw. A value from the vcatch_throw_type_t enum.
total_charge_levelintThe floor of the sum of the charge level and overcharge level of the ball being thrown. -1 to not use.
ball_typeintThe type of the ball being thrown. A value from the vcatch_ball_type_t enum.
match_flowintThe match flow that was matchmade into.

set_staged_player_stat

$catch_stat.set_staged_player_stat(user: User, player_stat: Reference, value: int, stat_period: int, stat_mode: int, map_type: int, use_throw_info: bool, throw_type: int, total_charge_level: int, ball_type: int)

Set the value of a staged stat for the given user.

ParameterTypeMeaning
userUserThe user for which to set the stat.
player_statReferenceA reference to the player_stat for which to set the value.
valueintThe value to set for the stat.
stat_periodintThe stat period for which to set the stat. A value from the vcatch_stat_period_t enum
stat_modeintThe stat mode for which to get the stat. A value from the vcatch_stat_mode_t enum
map_typeintThe map type obtained from catch_world. A value from the vcatch_map_type_t enum.
use_throw_infoboolWhether or not throw info is included in the arguments.
throw_typeintThe throw type of the throw. A value from the vcatch_throw_type_t enum.
total_charge_levelintThe floor of the sum of the charge level and overcharge level of the ball being thrown. -1 to not use.
ball_typeintThe type of the ball being thrown. A value from the vcatch_ball_type_t enum.

set_staged_player_stat_for_match

$catch_stat.set_staged_player_stat_for_match(user: User, player_stat: Reference, value: int, stat_period: int, map_type: int, match_def: Reference, match_rules: Reference, use_throw_info: bool, throw_type: int, total_charge_level: int, ball_type: int, match_flow: int)

Set the value of a staged stat for the given user for this particular match.

ParameterTypeMeaning
userUserThe user for which to get the stat.
player_statReferenceA reference to the player_stat for which to set the value.
valueintThe value to set for the stat.
stat_periodintThe stat period for which to set the stat. A value from the vcatch_stat_period_t enum
map_typeintThe map type obtained from catch_world. A value from the vcatch_map_type_t enum.
match_defReferenceA match definition file reference .
match_rulesReferenceA match rules file reference.
use_throw_infoboolWhether or not throw info is included in the arguments.
throw_typeintThe throw type of the throw. A value from the vcatch_throw_type_t enum.
total_charge_levelintThe floor of the sum of the charge level and overcharge level of the ball being thrown. -1 to not use.
ball_typeintThe type of the ball being thrown. A value from the vcatch_ball_type_t enum.
match_flowintThe match flow that was matchmade into.