mirror of
https://github.com/jugeeya/UltimateTrainingModpack.git
synced 2024-11-28 12:50:16 +00:00
Format Rust code using rustfmt
This commit is contained in:
parent
e18b02e985
commit
54f4e002fa
2 changed files with 47 additions and 11 deletions
|
@ -3,7 +3,7 @@ use crate::hitbox_visualizer;
|
||||||
use skyline::hooks::{getRegionAddress, InlineCtx, Region};
|
use skyline::hooks::{getRegionAddress, InlineCtx, Region};
|
||||||
use skyline::nn::hid::*;
|
use skyline::nn::hid::*;
|
||||||
use skyline::nn::ro::LookupSymbol;
|
use skyline::nn::ro::LookupSymbol;
|
||||||
use smash::app::{self, lua_bind::*, enSEType};
|
use smash::app::{self, enSEType, lua_bind::*};
|
||||||
use smash::lib::lua_const::*;
|
use smash::lib::lua_const::*;
|
||||||
use smash::params::*;
|
use smash::params::*;
|
||||||
use smash::phx::{Hash40, Vector3f};
|
use smash::phx::{Hash40, Vector3f};
|
||||||
|
@ -385,14 +385,30 @@ pub unsafe fn handle_se(
|
||||||
bool2: bool,
|
bool2: bool,
|
||||||
bool3: bool,
|
bool3: bool,
|
||||||
bool4: bool,
|
bool4: bool,
|
||||||
se_type: enSEType
|
se_type: enSEType,
|
||||||
) -> u64 {
|
) -> u64 {
|
||||||
// Make effects silent while we're killing fighters. Stops death explosion and fighter misfoot.
|
// Make effects silent while we're killing fighters. Stops death explosion and fighter misfoot.
|
||||||
if save_states::is_killing() {
|
if save_states::is_killing() {
|
||||||
let silent_hash = Hash40::new("se_silent");
|
let silent_hash = Hash40::new("se_silent");
|
||||||
return original!()(module_accessor,silent_hash,bool1,bool2,bool3,bool4,se_type);
|
return original!()(
|
||||||
|
module_accessor,
|
||||||
|
silent_hash,
|
||||||
|
bool1,
|
||||||
|
bool2,
|
||||||
|
bool3,
|
||||||
|
bool4,
|
||||||
|
se_type,
|
||||||
|
);
|
||||||
}
|
}
|
||||||
original!()(module_accessor, my_hash,bool1,bool2,bool3,bool4,se_type)
|
original!()(
|
||||||
|
module_accessor,
|
||||||
|
my_hash,
|
||||||
|
bool1,
|
||||||
|
bool2,
|
||||||
|
bool3,
|
||||||
|
bool4,
|
||||||
|
se_type,
|
||||||
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
#[skyline::hook(replace = EffectModule::req)] // hooked to prevent death gfx from playing when loading save states
|
#[skyline::hook(replace = EffectModule::req)] // hooked to prevent death gfx from playing when loading save states
|
||||||
|
@ -405,13 +421,33 @@ pub unsafe fn handle_effect(
|
||||||
arg6: u32,
|
arg6: u32,
|
||||||
arg7: i32,
|
arg7: i32,
|
||||||
arg8: bool,
|
arg8: bool,
|
||||||
arg9: i32
|
arg9: i32,
|
||||||
) -> u64 {
|
) -> u64 {
|
||||||
if save_states::is_killing() {
|
if save_states::is_killing() {
|
||||||
// Making the size 0 prevents these effects from being displayed. Fixs throw explosions, ICs squall, etc.
|
// Making the size 0 prevents these effects from being displayed. Fixs throw explosions, ICs squall, etc.
|
||||||
return original!()(module_accessor,eff_hash,pos,rot,0.0,arg6,arg7,arg8,arg9);
|
return original!()(
|
||||||
|
module_accessor,
|
||||||
|
eff_hash,
|
||||||
|
pos,
|
||||||
|
rot,
|
||||||
|
0.0,
|
||||||
|
arg6,
|
||||||
|
arg7,
|
||||||
|
arg8,
|
||||||
|
arg9,
|
||||||
|
);
|
||||||
}
|
}
|
||||||
original!()(module_accessor,eff_hash,pos,rot,size,arg6,arg7,arg8,arg9)
|
original!()(
|
||||||
|
module_accessor,
|
||||||
|
eff_hash,
|
||||||
|
pos,
|
||||||
|
rot,
|
||||||
|
size,
|
||||||
|
arg6,
|
||||||
|
arg7,
|
||||||
|
arg8,
|
||||||
|
arg9,
|
||||||
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
#[allow(improper_ctypes)]
|
#[allow(improper_ctypes)]
|
||||||
|
|
|
@ -277,7 +277,7 @@ pub unsafe fn save_states(module_accessor: &mut app::BattleObjectModuleAccessor)
|
||||||
module_accessor,
|
module_accessor,
|
||||||
Hash40::new("se_system_position_reset"),
|
Hash40::new("se_system_position_reset"),
|
||||||
true,
|
true,
|
||||||
true
|
true,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue