Skip to main content

Action

Enum Action 

Source
pub enum Action {
Show 15 variants SetGlobalVariable { variable: String, value: Value, }, ModifyGlobalVariable { variable: String, op: ModifyOp, value: Value, }, SetPlayerVariable { player: Value, variable: String, value: Value, }, ModifyPlayerVariable { player: Value, variable: String, op: ModifyOp, value: Value, }, AssignMember { target: Value, op: Option<ModifyOp>, value: Value, }, CallSubroutine { subroutine: String, }, If { condition: Value, }, ElseIf { condition: Value, }, Else, While { condition: Value, }, ForGlobalVariable { variable: String, start: Value, stop: Value, step: Value, }, ForPlayerVariable { player: Value, variable: String, start: Value, stop: Value, step: Value, }, End, Disabled { action: Box<Action>, }, Call { name: String, args: Vec<Value>, },
}
Expand description

A Workshop action line. Control flow is represented in the same order as the Workshop source, including its explicit End lines.

Variants§

§

SetGlobalVariable

Fields

§variable: String
§value: Value
§

ModifyGlobalVariable

Fields

§variable: String
§value: Value
§

SetPlayerVariable

Fields

§player: Value
§variable: String
§value: Value
§

ModifyPlayerVariable

Fields

§player: Value
§variable: String
§value: Value
§

AssignMember

Fields

§target: Value
§value: Value
§

CallSubroutine

Fields

§subroutine: String
§

If

Fields

§condition: Value
§

ElseIf

Fields

§condition: Value
§

Else

§

While

Fields

§condition: Value
§

ForGlobalVariable

Fields

§variable: String
§start: Value
§stop: Value
§step: Value
§

ForPlayerVariable

Fields

§player: Value
§variable: String
§start: Value
§stop: Value
§step: Value
§

End

§

Disabled

Fields

§action: Box<Action>
§

Call

Fields

§name: String
§args: Vec<Value>

Implementations§

Source§

impl Action

Source

pub fn disabled(action: Action) -> Self

Mark an action as disabled.

Source

pub fn call( name: impl Into<String>, args: impl IntoIterator<Item = Value>, ) -> Self

Construct a dynamic action call by canonical Workshop id.

§

impl Action

pub fn destroy_icon(id: impl Into<Value>) -> Self

Constructs the canonical Workshop actions destroyIcon. Parameters: id.

pub fn start_forcing_outline_for( viewed_players: impl Into<Value>, viewing_players: impl Into<Value>, visible: impl Into<Value>, color: impl Into<Value>, visibility: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions startForcingOutlineFor. Parameters: viewed_players, viewing_players, visible, color, visibility.

pub fn reset_hero_availability(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions resetHeroAvailability. Parameters: player.

pub fn stop_forcing_outline_for( viewed_players: impl Into<Value>, viewing_players: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions stopForcingOutlineFor. Parameters: viewed_players, viewing_players.

pub fn set_crouch_enabled( player: impl Into<Value>, enabled: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setCrouchEnabled. Parameters: player, enabled.

pub fn create_icon( visible_to: impl Into<Value>, position: impl Into<Value>, icon: impl Into<Value>, reevaluation: impl Into<Value>, color: impl Into<Value>, show_when_offscreen: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions createIcon. Parameters: visible_to, position, icon, reevaluation, color, show_when_offscreen.

pub fn set_jump_enabled( player: impl Into<Value>, enabled: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setJumpEnabled. Parameters: player, enabled.

pub fn set_slow_motion(speed_percent: impl Into<Value>) -> Self

Constructs the canonical Workshop actions setSlowMotion. Parameters: speed_percent.

pub fn set_melee_enabled( player: impl Into<Value>, enabled: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setMeleeEnabled. Parameters: player, enabled.

pub fn start_forcing_spawn( team: impl Into<Value>, room: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions startForcingSpawn. Parameters: team, room.

pub fn set_primary_fire_enabled( player: impl Into<Value>, enabled: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setPrimaryFireEnabled. Parameters: player, enabled.

pub fn start_modifying_voiceline_pitch( player: impl Into<Value>, pitch_scalar: impl Into<Value>, reevaluation: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions startModifyingVoicelinePitch. Parameters: player, pitch_scalar, reevaluation.

pub fn set_ability_charge( player: impl Into<Value>, button: impl Into<Value>, charge_count: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setAbilityCharge. Parameters: player, button, charge_count.

pub fn start_forcing_name( player: impl Into<Value>, name: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions startForcingName. Parameters: player, name.

pub fn start_scaling_barriers( player: impl Into<Value>, scale: impl Into<Value>, reevaluation: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions startScalingBarriers. Parameters: player, scale, reevaluation.

pub fn detach(children: impl Into<Value>) -> Self

Constructs the canonical Workshop actions detach. Parameters: children.

pub fn stop_all_damage_over_time(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions stopAllDamageOverTime. Parameters: player.

pub fn resurrect(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions resurrect. Parameters: player.

pub fn attach_to( child: impl Into<Value>, parent: impl Into<Value>, offset: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions attachTo. Parameters: child, parent, offset.

pub fn stop_modifying_voiceline_pitch(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions stopModifyingVoicelinePitch. Parameters: player.

pub fn kill(player: impl Into<Value>, killer: impl Into<Value>) -> Self

Constructs the canonical Workshop actions kill. Parameters: player, killer.

pub fn respawn(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions respawn. Parameters: player.

pub fn stop_scaling_barriers(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions stopScalingBarriers. Parameters: player.

pub fn disable_nameplates_for( viewed_players: impl Into<Value>, viewing_players: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions disableNameplatesFor. Parameters: viewed_players, viewing_players.

pub fn stop_damage_over_time(damage_over_time_id: impl Into<Value>) -> Self

Constructs the canonical Workshop actions stopDamageOverTime. Parameters: damage_over_time_id.

pub fn stop_scaling_size(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions stopScalingSize. Parameters: player.

pub fn enable_nameplates_for( viewed_players: impl Into<Value>, viewing_players: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions enableNameplatesFor. Parameters: viewed_players, viewing_players.

pub fn set_environment_credit_player( player: impl Into<Value>, credit_player: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setEnvironmentCreditPlayer. Parameters: player, credit_player.

pub fn modify_player_variable_at_index( variable: impl Into<Value>, index: impl Into<Value>, operation: impl Into<Value>, value: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions modifyPlayerVariableAtIndex. Parameters: variable, index, operation, value.

pub fn disable_voice_chat( player: impl Into<Value>, team_voice_chat: impl Into<Value>, match_voice_chat: impl Into<Value>, group_voice_chat: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions disableVoiceChat. Parameters: player, team_voice_chat, match_voice_chat, group_voice_chat.

pub fn set_ability_resource( player: impl Into<Value>, button: impl Into<Value>, resource_percent: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setAbilityResource. Parameters: player, button, resource_percent.

pub fn log_to_inspector(text: impl Into<Value>) -> Self

Constructs the canonical Workshop actions logToInspector. Parameters: text.

pub fn disable_death_spectate_all_players(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions disableDeathSpectateAllPlayers. Parameters: player.

pub fn add_health_pool( player: impl Into<Value>, health_type: impl Into<Value>, max_health: impl Into<Value>, is_recoverable: impl Into<Value>, reevaluation: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions addHealthPool. Parameters: player, health_type, max_health, is_recoverable, reevaluation.

pub fn modify_global_variable_at_index( variable: impl Into<Value>, index: impl Into<Value>, operation: impl Into<Value>, value: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions modifyGlobalVariableAtIndex. Parameters: variable, index, operation, value.

pub fn disable_text_chat(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions disableTextChat. Parameters: player.

pub fn start_damage_modification( receivers: impl Into<Value>, damagers: impl Into<Value>, damage_percent: impl Into<Value>, reevaluation: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions startDamageModification. Parameters: receivers, damagers, damage_percent, reevaluation.

pub fn stop_healing_over_time(heal_over_time_id: impl Into<Value>) -> Self

Constructs the canonical Workshop actions stopHealingOverTime. Parameters: heal_over_time_id.

pub fn disable_messages(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions disableMessages. Parameters: player.

pub fn stop_damage_modification( damage_modification_id: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions stopDamageModification. Parameters: damage_modification_id.

pub fn disable_death_spectate_target_hud(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions disableDeathSpectateTargetHud. Parameters: player.

pub fn start_damage_over_time( player: impl Into<Value>, damager: impl Into<Value>, duration: impl Into<Value>, damage_per_second: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions startDamageOverTime. Parameters: player, damager, duration, damage_per_second.

pub fn stop_forcing_current_hero(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions stopForcingCurrentHero. Parameters: player.

pub fn disable_kill_feed(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions disableKillFeed. Parameters: player.

pub fn set_ability_cooldown( player: impl Into<Value>, button: impl Into<Value>, cooldown: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setAbilityCooldown. Parameters: player, button, cooldown.

pub fn start_forcing_hero( player: impl Into<Value>, hero: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions startForcingHero. Parameters: player, hero.

pub fn stop_chasing_global_variable(variable: impl Into<Value>) -> Self

Constructs the canonical Workshop actions stopChasingGlobalVariable. Parameters: variable.

pub fn set_ability2_enabled( player: impl Into<Value>, enabled: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setAbility2Enabled. Parameters: player, enabled.

pub fn preload_hero(player: impl Into<Value>, hero: impl Into<Value>) -> Self

Constructs the canonical Workshop actions preloadHero. Parameters: player, hero.

pub fn set_healing_dealt( player: impl Into<Value>, healing_dealt_percent: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setHealingDealt. Parameters: player, healing_dealt_percent.

pub fn start_healing_over_time( player: impl Into<Value>, healer: impl Into<Value>, duration: impl Into<Value>, healing_per_second: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions startHealingOverTime. Parameters: player, healer, duration, healing_per_second.

pub fn remove_health_pool(health_pool_id: impl Into<Value>) -> Self

Constructs the canonical Workshop actions removeHealthPool. Parameters: health_pool_id.

pub fn start_scaling_size( player: impl Into<Value>, scale: impl Into<Value>, reevaluation: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions startScalingSize. Parameters: player, scale, reevaluation.

pub fn set_facing( player: impl Into<Value>, direction: impl Into<Value>, relativity: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setFacing. Parameters: player, direction, relativity.

pub fn stop_forcing_position(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions stopForcingPosition. Parameters: player.

pub fn set_knockback_dealt( player: impl Into<Value>, knockback_dealt_percent: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setKnockbackDealt. Parameters: player, knockback_dealt_percent.

pub fn stop_acceleration(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions stopAcceleration. Parameters: player.

pub fn declare_team_victory(team: impl Into<Value>) -> Self

Constructs the canonical Workshop actions declareTeamVictory. Parameters: team.

pub fn stop_facing(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions stopFacing. Parameters: player.

pub fn start_forcing_position( player: impl Into<Value>, position: impl Into<Value>, reevaluate: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions startForcingPosition. Parameters: player, position, reevaluate.

pub fn set_knockback_received( player: impl Into<Value>, knockback_received_percent: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setKnockbackReceived. Parameters: player, knockback_received_percent.

pub fn start_acceleration( player: impl Into<Value>, direction: impl Into<Value>, rate: impl Into<Value>, max_speed: impl Into<Value>, relativity: impl Into<Value>, reevaluation: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions startAcceleration. Parameters: player, direction, rate, max_speed, relativity, reevaluation.

pub fn progress_bar_hud( visible_to: impl Into<Value>, value: impl Into<Value>, text: impl Into<Value>, location: impl Into<Value>, sort_order: impl Into<Value>, progress_bar_color: impl Into<Value>, text_color: impl Into<Value>, reevaluation: impl Into<Value>, spec_visibility: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions progressBarHud. Parameters: visible_to, value, text, location, sort_order, progress_bar_color, text_color, reevaluation, spec_visibility.

pub fn stop_forcing_button( player: impl Into<Value>, button: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions stopForcingButton. Parameters: player, button.

pub fn set_healing_received( player: impl Into<Value>, healing_received_percent: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setHealingReceived. Parameters: player, healing_received_percent.

pub fn destroy_progress_bar_in_world_text(text_id: impl Into<Value>) -> Self

Constructs the canonical Workshop actions destroyProgressBarInWorldText. Parameters: text_id.

pub fn set_objective_description( visible_to: impl Into<Value>, text: impl Into<Value>, reevaluation: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setObjectiveDescription. Parameters: visible_to, text, reevaluation.

pub fn start_forcing_button( player: impl Into<Value>, button: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions startForcingButton. Parameters: player, button.

pub fn damage( player: impl Into<Value>, damager: impl Into<Value>, amount: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions damage. Parameters: player, damager, amount.

pub fn set_projectile_gravity( player: impl Into<Value>, projectile_gravity_percent: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setProjectileGravity. Parameters: player, projectile_gravity_percent.

pub fn clear_status_effect( player: impl Into<Value>, status: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions clearStatusEffect. Parameters: player, status.

pub fn set_ammo( player: impl Into<Value>, clip: impl Into<Value>, ammo: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setAmmo. Parameters: player, clip, ammo.

pub fn destroy_dummy(team: impl Into<Value>, slot: impl Into<Value>) -> Self

Constructs the canonical Workshop actions destroyDummy. Parameters: team, slot.

pub fn stop_chasing_player_variable( player: impl Into<Value>, variable: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions stopChasingPlayerVariable. Parameters: player, variable.

pub fn set_projectile_speed( player: impl Into<Value>, projectile_speed_percent: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setProjectileSpeed. Parameters: player, projectile_speed_percent.

pub fn set_ult_enabled( player: impl Into<Value>, enabled: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setUltEnabled. Parameters: player, enabled.

pub fn set_max_ammo( player: impl Into<Value>, clip: impl Into<Value>, ammo: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setMaxAmmo. Parameters: player, clip, ammo.

pub fn create_dummy_bot( hero: impl Into<Value>, team: impl Into<Value>, slot: impl Into<Value>, position: impl Into<Value>, direction: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions createDummyBot. Parameters: hero, team, slot, position, direction.

pub fn loop_if(condition: impl Into<Value>) -> Self

Constructs the canonical Workshop actions loopIf. Parameters: condition.

pub fn loop_() -> Self

Constructs the canonical Workshop actions loop.

pub fn set_player_variable_at_index( variable: impl Into<Value>, index: impl Into<Value>, value: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setPlayerVariableAtIndex. Parameters: variable, index, value.

pub fn set_ability1_enabled( player: impl Into<Value>, enabled: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setAbility1Enabled. Parameters: player, enabled.

pub fn set_respawn_time( player: impl Into<Value>, time: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setRespawnTime. Parameters: player, time.

pub fn set_match_time(time: impl Into<Value>) -> Self

Constructs the canonical Workshop actions setMatchTime. Parameters: time.

pub fn remove_all_health_pools_from_player(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions removeAllHealthPoolsFromPlayer. Parameters: player.

pub fn enable_respawn(players: impl Into<Value>) -> Self

Constructs the canonical Workshop actions enableRespawn. Parameters: players.

pub fn heal( player: impl Into<Value>, healer: impl Into<Value>, amount: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions heal. Parameters: player, healer, amount.

pub fn force_button_press( player: impl Into<Value>, button: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions forceButtonPress. Parameters: player, button.

pub fn start_forcing_throttle( player: impl Into<Value>, min_forward: impl Into<Value>, max_forward: impl Into<Value>, min_backward: impl Into<Value>, max_backward: impl Into<Value>, min_sideways: impl Into<Value>, max_sideways: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions startForcingThrottle. Parameters: player, min_forward, max_forward, min_backward, max_backward, min_sideways, max_sideways.

pub fn apply_impulse( player: impl Into<Value>, direction: impl Into<Value>, speed: impl Into<Value>, relativity: impl Into<Value>, motion: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions applyImpulse. Parameters: player, direction, speed, relativity, motion.

pub fn communicate(player: impl Into<Value>, type_: impl Into<Value>) -> Self

Constructs the canonical Workshop actions communicate. Parameters: player, type_.

pub fn disable_respawn(players: impl Into<Value>) -> Self

Constructs the canonical Workshop actions disableRespawn. Parameters: players.

pub fn start_facing( player: impl Into<Value>, direction: impl Into<Value>, turn_rate: impl Into<Value>, relativity: impl Into<Value>, reevaluation: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions startFacing. Parameters: player, direction, turn_rate, relativity, reevaluation.

pub fn skip_if( condition: impl Into<Value>, number_of_actions: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions skipIf. Parameters: condition, number_of_actions.

pub fn set_global_variable_at_index( variable: impl Into<Value>, index: impl Into<Value>, value: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setGlobalVariableAtIndex. Parameters: variable, index, value.

pub fn remove_from_game(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions removeFromGame. Parameters: player.

pub fn start_rule( subroutine: impl Into<Value>, if_already_executing: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions startRule. Parameters: subroutine, if_already_executing.

pub fn cancel_primary_action(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions cancelPrimaryAction. Parameters: player.

pub fn restart_match() -> Self

Constructs the canonical Workshop actions restartMatch.

pub fn enable_builtin_game_mode_music() -> Self

Constructs the canonical Workshop actions enableBuiltinGameModeMusic.

pub fn destroy_all_in_world_text() -> Self

Constructs the canonical Workshop actions destroyAllInWorldText.

pub fn destroy_all_icons() -> Self

Constructs the canonical Workshop actions destroyAllIcons.

pub fn destroy_all_hud_text() -> Self

Constructs the canonical Workshop actions destroyAllHudText.

pub fn destroy_all_effects() -> Self

Constructs the canonical Workshop actions destroyAllEffects.

pub fn disable_builtin_game_mode_music() -> Self

Constructs the canonical Workshop actions disableBuiltinGameModeMusic.

pub fn break_() -> Self

Constructs the canonical Workshop actions break.

pub fn disable_builtin_game_mode_completion() -> Self

Constructs the canonical Workshop actions disableBuiltinGameModeCompletion.

pub fn disable_builtin_game_mode_announcer() -> Self

Constructs the canonical Workshop actions disableBuiltinGameModeAnnouncer.

pub fn disable_builtin_game_mode_scoring() -> Self

Constructs the canonical Workshop actions disableBuiltinGameModeScoring.

pub fn unpause_match_time() -> Self

Constructs the canonical Workshop actions unpauseMatchTime.

pub fn destroy_all_dummies() -> Self

Constructs the canonical Workshop actions destroyAllDummies.

pub fn pause_match_time() -> Self

Constructs the canonical Workshop actions pauseMatchTime.

pub fn disable_inspector() -> Self

Constructs the canonical Workshop actions disableInspector.

pub fn wait(time: impl Into<Value>, wait_behavior: impl Into<Value>) -> Self

Constructs the canonical Workshop actions wait. Parameters: time, wait_behavior.

pub fn create_beam_effect( visible_to: impl Into<Value>, type_: impl Into<Value>, start_position: impl Into<Value>, end_position: impl Into<Value>, color: impl Into<Value>, reevaluation: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions createBeamEffect. Parameters: visible_to, type_, start_position, end_position, color, reevaluation.

pub fn create_hud_text( visible_to: impl Into<Value>, header: impl Into<Value>, subheader: impl Into<Value>, text: impl Into<Value>, location: impl Into<Value>, sort_order: impl Into<Value>, header_color: impl Into<Value>, subheader_color: impl Into<Value>, text_color: impl Into<Value>, reevaluation: impl Into<Value>, spectators: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions createHudText. Parameters: visible_to, header, subheader, text, location, sort_order, header_color, subheader_color, text_color, reevaluation, spectators.

pub fn play_effect( visible_to: impl Into<Value>, type_: impl Into<Value>, color: impl Into<Value>, position: impl Into<Value>, radius: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions playEffect. Parameters: visible_to, type_, color, position, radius.

pub fn set_aim_speed( player: impl Into<Value>, turn_speed_percent: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setAimSpeed. Parameters: player, turn_speed_percent.

pub fn set_damage_dealt( player: impl Into<Value>, damage_dealt_percent: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setDamageDealt. Parameters: player, damage_dealt_percent.

pub fn set_damage_received( player: impl Into<Value>, damage_received_percent: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setDamageReceived. Parameters: player, damage_received_percent.

pub fn set_gravity( player: impl Into<Value>, gravity_percent: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setGravity. Parameters: player, gravity_percent.

pub fn set_health(player: impl Into<Value>, amount: impl Into<Value>) -> Self

Constructs the canonical Workshop actions setHealth. Parameters: player, amount.

pub fn set_max_health( player: impl Into<Value>, health_percent: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setMaxHealth. Parameters: player, health_percent.

pub fn set_move_speed( player: impl Into<Value>, move_speed_percent: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setMoveSpeed. Parameters: player, move_speed_percent.

pub fn set_ult_charge( player: impl Into<Value>, charge_percent: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setUltCharge. Parameters: player, charge_percent.

pub fn teleport(player: impl Into<Value>, position: impl Into<Value>) -> Self

Constructs the canonical Workshop actions teleport. Parameters: player, position.

pub fn chase_at_rate( variable: impl Into<Value>, destination: impl Into<Value>, rate: impl Into<Value>, reevaluation: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions chaseAtRate. Parameters: variable, destination, rate, reevaluation.

pub fn chase_over_time( variable: impl Into<Value>, destination: impl Into<Value>, duration: impl Into<Value>, reevaluation: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions chaseOverTime. Parameters: variable, destination, duration, reevaluation.

pub fn chase_player_variable_at_rate( player: impl Into<Value>, variable: impl Into<Value>, destination: impl Into<Value>, rate: impl Into<Value>, reevaluation: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions chasePlayerVariableAtRate. Parameters: player, variable, destination, rate, reevaluation.

pub fn chase_player_variable_over_time( player: impl Into<Value>, variable: impl Into<Value>, destination: impl Into<Value>, duration: impl Into<Value>, reevaluation: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions chasePlayerVariableOverTime. Parameters: player, variable, destination, duration, reevaluation.

pub fn set_invisibility( player: impl Into<Value>, invisible_to: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setInvisibility. Parameters: player, invisible_to.

pub fn set_status_effect( player: impl Into<Value>, assister: impl Into<Value>, status: impl Into<Value>, duration: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setStatusEffect. Parameters: player, assister, status, duration.

pub fn big_message(visible_to: impl Into<Value>, text: impl Into<Value>) -> Self

Constructs the canonical Workshop actions bigMessage. Parameters: visible_to, text.

pub fn small_message( visible_to: impl Into<Value>, text: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions smallMessage. Parameters: visible_to, text.

pub fn wait_until( continue_condition: impl Into<Value>, timeout: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions waitUntil. Parameters: continue_condition, timeout.

pub fn skip(number_of_actions: impl Into<Value>) -> Self

Constructs the canonical Workshop actions skip. Parameters: number_of_actions.

pub fn loop_if_condition_is_true() -> Self

Constructs the canonical Workshop actions loopIfConditionIsTrue.

pub fn abort_if(condition: impl Into<Value>) -> Self

Constructs the canonical Workshop actions abortIf. Parameters: condition.

pub fn modify_global_variable( variable: impl Into<Value>, operation: impl Into<Value>, value: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions modifyGlobalVariable. Parameters: variable, operation, value.

pub fn create_effect( visible_to: impl Into<Value>, type_: impl Into<Value>, color: impl Into<Value>, position: impl Into<Value>, radius: impl Into<Value>, reevaluation: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions createEffect. Parameters: visible_to, type_, color, position, radius, reevaluation.

pub fn create_in_world_text( visible_to: impl Into<Value>, text: impl Into<Value>, position: impl Into<Value>, scale: impl Into<Value>, clipping: impl Into<Value>, reevaluation: impl Into<Value>, color: impl Into<Value>, spec_visibility: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions createInWorldText. Parameters: visible_to, text, position, scale, clipping, reevaluation, color, spec_visibility.

pub fn create_progress_bar_in_world_text( visible_to: impl Into<Value>, value: impl Into<Value>, text: impl Into<Value>, position: impl Into<Value>, scale: impl Into<Value>, clipping: impl Into<Value>, progress_bar_color: impl Into<Value>, text_color: impl Into<Value>, reevaluation: impl Into<Value>, spec_visibility: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions createProgressBarInWorldText. Parameters: visible_to, value, text, position, scale, clipping, progress_bar_color, text_color, reevaluation, spec_visibility.

pub fn start_camera( player: impl Into<Value>, eye_position: impl Into<Value>, look_at_position: impl Into<Value>, blend_speed: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions startCamera. Parameters: player, eye_position, look_at_position, blend_speed.

pub fn stop_camera(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions stopCamera. Parameters: player.

pub fn start_game_mode() -> Self

Constructs the canonical Workshop actions startGameMode.

pub fn set_allowed_heroes( player: impl Into<Value>, hero: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setAllowedHeroes. Parameters: player, hero.

pub fn force_player_hero( player: impl Into<Value>, hero: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions forcePlayerHero. Parameters: player, hero.

pub fn stop_forcing_hero(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions stopForcingHero. Parameters: player.

pub fn force_throttle( player: impl Into<Value>, min_forward: impl Into<Value>, max_forward: impl Into<Value>, min_backward: impl Into<Value>, max_backward: impl Into<Value>, min_sideways: impl Into<Value>, max_sideways: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions forceThrottle. Parameters: player, min_forward, max_forward, min_backward, max_backward, min_sideways, max_sideways.

pub fn stop_forcing_throttle(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions stopForcingThrottle. Parameters: player.

pub fn stop_throttle_in_direction(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions stopThrottleInDirection. Parameters: player.

pub fn start_throttle_in_direction( player: impl Into<Value>, direction: impl Into<Value>, magnitude: impl Into<Value>, relativity: impl Into<Value>, behavior: impl Into<Value>, reevaluation: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions startThrottleInDirection. Parameters: player, direction, magnitude, relativity, behavior, reevaluation.

pub fn set_secondary_fire_enabled( player: impl Into<Value>, enabled: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setSecondaryFireEnabled. Parameters: player, enabled.

pub fn disable_game_mode_hud(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions disableGameModeHud. Parameters: player.

pub fn disable_game_mode_inworld_ui(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions disableGameModeInworldUI. Parameters: player.

pub fn disable_hero_hud(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions disableHeroHud. Parameters: player.

pub fn disable_scoreboard(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions disableScoreboard. Parameters: player.

pub fn enable_game_mode_hud(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions enableGameModeHud. Parameters: player.

pub fn enable_game_mode_inworld_ui(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions enableGameModeInworldUI. Parameters: player.

pub fn enable_hero_hud(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions enableHeroHud. Parameters: player.

pub fn enable_scoreboard(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions enableScoreboard. Parameters: player.

pub fn enable_inspector_recording() -> Self

Constructs the canonical Workshop actions enableInspectorRecording.

pub fn disable_movement_collision_with_environment( player: impl Into<Value>, include_floors: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions disableMovementCollisionWithEnvironment. Parameters: player, include_floors.

pub fn disable_movement_collision_with_players(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions disableMovementCollisionWithPlayers. Parameters: player.

pub fn enable_movement_collision_with_environment( player: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions enableMovementCollisionWithEnvironment. Parameters: player.

pub fn enable_movement_collision_with_players(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions enableMovementCollisionWithPlayers. Parameters: player.

pub fn disallow_button( player: impl Into<Value>, button: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions disallowButton. Parameters: player, button.

pub fn allow_button(player: impl Into<Value>, button: impl Into<Value>) -> Self

Constructs the canonical Workshop actions allowButton. Parameters: player, button.

pub fn destroy_hud_text(text_id: impl Into<Value>) -> Self

Constructs the canonical Workshop actions destroyHudText. Parameters: text_id.

pub fn destroy_in_world_text(text_id: impl Into<Value>) -> Self

Constructs the canonical Workshop actions destroyInWorldText. Parameters: text_id.

pub fn destroy_effect(entity: impl Into<Value>) -> Self

Constructs the canonical Workshop actions destroyEffect. Parameters: entity.

pub fn destroy_all_progress_bar_hud_text() -> Self

Constructs the canonical Workshop actions destroyAllProgressBarHudText.

pub fn destroy_all_progress_bar_in_world_text() -> Self

Constructs the canonical Workshop actions destroyAllProgressBarInWorldText.

pub fn stop_chasing_variable(variable: impl Into<Value>) -> Self

Constructs the canonical Workshop actions stopChasingVariable. Parameters: variable.

pub fn abort() -> Self

Constructs the canonical Workshop actions abort.

pub fn add_to_score(player: impl Into<Value>, score: impl Into<Value>) -> Self

Constructs the canonical Workshop actions addToScore. Parameters: player, score.

pub fn enable_death_spectate_all_players(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions enableDeathSpectateAllPlayers. Parameters: player.

pub fn enable_death_spectate_target_hud(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions enableDeathSpectateTargetHud. Parameters: player.

pub fn enable_kill_feed(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions enableKillFeed. Parameters: player.

pub fn enable_messages(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions enableMessages. Parameters: player.

pub fn enable_text_chat(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions enableTextChat. Parameters: player.

pub fn enable_voice_chat(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions enableVoiceChat. Parameters: player.

pub fn set_jump_vertical_speed( player: impl Into<Value>, jump_vertical_speed_percent: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setJumpVerticalSpeed. Parameters: player, jump_vertical_speed_percent.

pub fn set_reload_enabled( player: impl Into<Value>, enabled: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions setReloadEnabled. Parameters: player, enabled.

pub fn set_score(player: impl Into<Value>, score: impl Into<Value>) -> Self

Constructs the canonical Workshop actions setScore. Parameters: player, score.

pub fn set_weapon(player: impl Into<Value>, weapon: impl Into<Value>) -> Self

Constructs the canonical Workshop actions setWeapon. Parameters: player, weapon.

pub fn start_granting_assist_for( assisters: impl Into<Value>, targets: impl Into<Value>, reevaluation: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions startGrantingAssistFor. Parameters: assisters, targets, reevaluation.

pub fn start_transforming_throttle( player: impl Into<Value>, x_axis_scalar: impl Into<Value>, y_axis_scalar: impl Into<Value>, relative_direction: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions startTransformingThrottle. Parameters: player, x_axis_scalar, y_axis_scalar, relative_direction.

pub fn stop_all_healing_over_time(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions stopAllHealingOverTime. Parameters: player.

pub fn stop_forcing_name(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions stopForcingName. Parameters: player.

pub fn stop_transforming_throttle(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions stopTransformingThrottle. Parameters: player.

pub fn abort_if_condition_is_false() -> Self

Constructs the canonical Workshop actions __abortIfConditionIsFalse__.

pub fn abort_if_condition_is_true() -> Self

Constructs the canonical Workshop actions __abortIfConditionIsTrue__.

pub fn for_player_variable( player: impl Into<Value>, variable: impl Into<Value>, start: impl Into<Value>, stop: impl Into<Value>, step: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions __forPlayerVariable__. Parameters: player, variable, start, stop, step.

pub fn loop_if_condition_is_false() -> Self

Constructs the canonical Workshop actions __loopIfConditionIsFalse__.

pub fn add_to_team_score( team: impl Into<Value>, score: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions addToTeamScore. Parameters: team, score.

pub fn continue_() -> Self

Constructs the canonical Workshop actions continue.

pub fn declare_draw() -> Self

Constructs the canonical Workshop actions declareDraw.

pub fn declare_player_victory(player: impl Into<Value>) -> Self

Constructs the canonical Workshop actions declarePlayerVictory. Parameters: player.

pub fn declare_round_draw() -> Self

Constructs the canonical Workshop actions declareRoundDraw.

pub fn declare_round_victory(round_winning_team: impl Into<Value>) -> Self

Constructs the canonical Workshop actions declareRoundVictory. Parameters: round_winning_team.

pub fn destroy_progress_bar_hud(text_id: impl Into<Value>) -> Self

Constructs the canonical Workshop actions destroyProgressBarHud. Parameters: text_id.

pub fn enable_announcer() -> Self

Constructs the canonical Workshop actions enableAnnouncer.

pub fn enable_gamemode_completion() -> Self

Constructs the canonical Workshop actions enableGamemodeCompletion.

pub fn enable_scoring() -> Self

Constructs the canonical Workshop actions enableScoring.

pub fn go_to_assemble_heroes() -> Self

Constructs the canonical Workshop actions goToAssembleHeroes.

pub fn move_to_team( player: impl Into<Value>, team: impl Into<Value>, slot: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions moveToTeam. Parameters: player, team, slot.

pub fn return_to_lobby() -> Self

Constructs the canonical Workshop actions returnToLobby.

pub fn set_team_score(team: impl Into<Value>, score: impl Into<Value>) -> Self

Constructs the canonical Workshop actions setTeamScore. Parameters: team, score.

pub fn start_healing_modification( receivers: impl Into<Value>, healers: impl Into<Value>, healing_percent: impl Into<Value>, reevaluation: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions startHealingModification. Parameters: receivers, healers, healing_percent, reevaluation.

pub fn stop_all_assists() -> Self

Constructs the canonical Workshop actions stopAllAssists.

pub fn stop_all_damage_modifications() -> Self

Constructs the canonical Workshop actions stopAllDamageModifications.

pub fn stop_all_healing_modifications() -> Self

Constructs the canonical Workshop actions stopAllHealingModifications.

pub fn stop_assist(assist_id: impl Into<Value>) -> Self

Constructs the canonical Workshop actions stopAssist. Parameters: assist_id.

pub fn stop_forcing_spawn(team: impl Into<Value>) -> Self

Constructs the canonical Workshop actions stopForcingSpawn. Parameters: team.

pub fn stop_healing_modification( healing_modification_id: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions stopHealingModification. Parameters: healing_modification_id.

pub fn create_projectile( type_: impl Into<Value>, player: impl Into<Value>, start_position: impl Into<Value>, direction: impl Into<Value>, relativity: impl Into<Value>, modify_health_type: impl Into<Value>, affected_team: impl Into<Value>, damage: impl Into<Value>, damage_scalar: impl Into<Value>, explosion_radius: impl Into<Value>, explosion_effect: impl Into<Value>, explosion_sound: impl Into<Value>, oversize: impl Into<Value>, speed: impl Into<Value>, lifetime: impl Into<Value>, impulse_strength: impl Into<Value>, ricochet_count: impl Into<Value>, gravity: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions createProjectile. Parameters: type_, player, start_position, direction, relativity, modify_health_type, affected_team, damage, damage_scalar, explosion_radius, explosion_effect, explosion_sound, oversize, speed, lifetime, impulse_strength, ricochet_count, gravity.

pub fn create_homing_projectile( type_: impl Into<Value>, player: impl Into<Value>, start_position: impl Into<Value>, direction: impl Into<Value>, relativity: impl Into<Value>, modify_health_type: impl Into<Value>, affected_team: impl Into<Value>, damage: impl Into<Value>, damage_scalar: impl Into<Value>, explosion_radius: impl Into<Value>, explosion_effect: impl Into<Value>, explosion_sound: impl Into<Value>, oversize: impl Into<Value>, speed: impl Into<Value>, lifetime: impl Into<Value>, impulse_strength: impl Into<Value>, homing_target: impl Into<Value>, homing_strength: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions createHomingProjectile. Parameters: type_, player, start_position, direction, relativity, modify_health_type, affected_team, damage, damage_scalar, explosion_radius, explosion_effect, explosion_sound, oversize, speed, lifetime, impulse_strength, homing_target, homing_strength.

pub fn create_projectile_effect( visible_to: impl Into<Value>, type_: impl Into<Value>, friendly_to: impl Into<Value>, position: impl Into<Value>, direction: impl Into<Value>, oversize: impl Into<Value>, reevaluation: impl Into<Value>, ) -> Self

Constructs the canonical Workshop actions createProjectileEffect. Parameters: visible_to, type_, friendly_to, position, direction, oversize, reevaluation.

Trait Implementations§

Source§

impl Clone for Action

Source§

fn clone(&self) -> Action

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Action

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.