[−][src]Function smash::app::lua_bind::ControlModule::check_button_on
pub unsafe extern "C" fn check_button_on(
arg1: *mut BattleObjectModuleAccessor,
arg2: c_int
) -> bool
Returns whether or not the current module_accessor is holding the specified CONTROL_PAD_BUTTON on the same frame this function was run
Arguments
-
moudule_accessor
- a pointer to BattleObjectModuleAccessor -
control_pad_button
- a CONTROL_PAD_BUTTON lua const
Example
if ControlModule::check_button_on(module_accessor, *CONTROL_PAD_BUTTON_GUARD) {
DamageModule::add_damage(boma, 5.0, 0);
}