> ## Documentation Index
> Fetch the complete documentation index at: https://devdocs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# IGameInputDevice::SetForceFeedbackMotorGain

> IGameInputDevice::SetForceFeedbackMotorGain

# IGameInputDevice::SetForceFeedbackMotorGain

Applies a global attenuation factor to all loaded effects on a motor.

## Syntax

```cpp theme={null}
void SetForceFeedbackMotorGain(
    uint32_t motorIndex,
    float masterGain
);
```

### Parameters

*motorIndex*   \_In\_\
Type: uint32\_t

Index of the motor to be changed.

*masterGain*   \_In\_\
Type: float

Global attenuation factor to all loaded effects on the motor between 0.0 and 1.0.

### Return value

None.

## Remarks

This method applies a global attenuation factor to all loaded effects on the motor. The `masterGain` pointer accepts values between 0.0 and 1.0. This is used by the application's force feedback strength settings. For more information, see [Overview of GameInput](/build/core-features/common/input/overviews/input-overview).

## Requirements

**Header:** GameInput.h

[GameInput](/reference/input/gameinput/gameinput_members)\
[IGameInputDevice](/reference/input/gameinput/interfaces/igameinputdevice/igameinputdevice)

## Version History

| Version | Changes     |
| ------- | ----------- |
| **v0**  | Introduced. |


## Related topics

- [IGameInputDevice::SetHapticMotorState](/reference/input/gameinput/deprecated/interfaces/igameinputdevice/methods/igameinputdevice_sethapticmotorstate.md)
- [IGameInputForceFeedbackEffect::SetGain](/reference/input/gameinput/interfaces/igameinputforcefeedbackeffect/methods/igameinputforcefeedbackeffect_setgain.md)
- [IGameInputForceFeedbackEffect::GetGain](/reference/input/gameinput/interfaces/igameinputforcefeedbackeffect/methods/igameinputforcefeedbackeffect_getgain.md)
- [IGameInputDevice](/reference/input/gameinput/interfaces/igameinputdevice/igameinputdevice.md)
- [IGameInputForceFeedbackEffect](/reference/input/gameinput/interfaces/igameinputforcefeedbackeffect/igameinputforcefeedbackeffect.md)
