t2:ffb_reset

ffb_reset


ffb_reset — Reset all FFBs speed and duration

Description


void ffb_reset();

Reset all FFBs speed and duration to the original values and restore the transmission of force feedback signals from the console to the connected controllers.

ATTENTION: The ffb_reset() should NOT be called on every interaction of main.

Return Value


No value is returned.

Examples


Example #1 ffb_reset() example

main {
    if(event_active(BUTTON_16)) {
        ffb_set(FFB_1, 100.0, 500);
    } else if(is_release(BUTTON_16)) {
        uint32 duration;
        ffb_get(FFB_1, &duration);
        if(duration == 0) {
            ffb_reset();
        }
    }
}

See Also

t2/ffb_reset.txt · Last modified: 2016/11/29 10:35 by J2Kbr