EventChecker.IsModifierCombinationPressed Method |
Note: This API is now obsolete.
Verifies that the requested key modifiers are pressed.
Namespace:
KSPDev.InputUtils
Assembly:
KSPDev_Utils.2.2 (in KSPDev_Utils.2.2.dll) Version: 2.2 for KSP v1
Syntax[ObsoleteAttribute("This method will soon be depreacted. Use CheckAnySymmetricalModifiers().")]
public static bool IsModifierCombinationPressed(
KeyModifiers modifiers
)
Request Example
View SourceParameters
- modifiers
- Type: KSPDev.InputUtils.KeyModifiers
A combination of key modifiers to verify.
Return Value
Type:
Booleantrue when exactly the requested combination is pressed.
RemarksThe check will succeed only if the exact set of modifier keys is pressed. If there
are more or less modifiers pressed the check will fail. E.g. if there are
LeftAlt and
LeftShift pressed but the check is executed against
AnyShift then it will fail. Though, checking for
AnyShift | AnyAlt will succeed.
In case of checking for None the check will require no modifier keys to be
pressed. If you deal with mouse button events it's a good idea to verify if no modifiers are
pressed even if you don't care about other combinations. It will let other modders to use
mouse buttons and not to interfere with your mod.
See Also