[][src]Function smash::app::lua_bind::AttackModule::is_infliction

pub unsafe extern "C" fn is_infliction(
    arg1: *mut BattleObjectModuleAccessor,
    arg2: c_int
) -> bool

Returns whether or not you are currently hitting an opponent (in hitlag).

Arguments

Example

// transition to instantly to WAIT when hitting someone and holding shield
if AttackModule::is_infliction(module_accessor, *COLLISION_KIND_MASK_HIT) && ControlModule::check_button_on(module_accessor, *CONTROL_PAD_BUTTON_GUARD) {
    StatusModule::change_status_request_from_script(module_accessor, *FIGHTER_STATUS_KIND_WAIT, true);
}