Skip to content

Commit

Permalink
Update function documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
ThatNintendoNerd committed Sep 3, 2024
1 parent a32b793 commit e7d71df
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/service/gravity.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ struct GravityPos {
y: f32,
}

/// Updates the parameters for gravity if the given stage identifier is assigned specialized gravity parameters.
/// Updates the parameters for gravity if the given stage identifier is assigned specialized parameters.
pub fn try_set_gravity_param(stage_id: StageID) {
use crate::config::Config;

Expand Down
3 changes: 3 additions & 0 deletions src/service/settings.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ use smash_stage::app::{GlobalStageParameter, SpiritsBattleData};

use crate::{config::Config, offsets::Offsets};

/// Updates the stage's spirit battle settings if the given stage identifier is assigned a specialized setting.
pub fn try_set_stage_additional_settings(stage_parameter: &mut GlobalStageParameter) {
if is_invalid_melee_mode() {
return;
Expand All @@ -19,6 +20,7 @@ pub fn try_set_stage_additional_settings(stage_parameter: &mut GlobalStageParame
}
}

/// Updates the stage's spirit battle settings.
fn set_stage_additional_settings(stage_parameter: &mut GlobalStageParameter, setting: i8) {
let mut spirits_battle_data = SpiritsBattleData::default();

Expand All @@ -30,6 +32,7 @@ fn set_stage_additional_settings(stage_parameter: &mut GlobalStageParameter, set
}
}

/// Returns `true` if the working game mode is unsupported by this feature.
fn is_invalid_melee_mode() -> bool {
use smash_stage::app::{GlobalParameter, MeleeMode};

Expand Down

0 comments on commit e7d71df

Please sign in to comment.