OldUnreal / UnrealTournamentPatches

Other
955 stars 28 forks source link

[469d] Ued - Modifier keys (CTRL, ALT, and SHIFT) produce unexpected results when combined with custom single key bindings #1588

Open BerserkerBG opened 2 months ago

BerserkerBG commented 2 months ago

In Ued, assigning actions to single keys interferes with the expected behavior of modifier key combinations (e.g., CTRL, ALT, and SHIFT). When a key with a custom binding is used in conjunction with modifier keys, both the custom action and the standard modifier action are executed simultaneously. Some combinations can even cause the modifier key to not work at all.

Reproduce steps:

1. Bind a single key (e.g., D) to an action such as "Subtract." (you can do that by using the command "set input D BRUSH SUBTRACT" 2. Select an Actor inside a map and press CTRL+D to attempt a Duplicate operation for the selected Actor. 3. Observe that both Duplicate and Subtract actions are performed at the same time.

Expected result:

After we perform CTRL+D for Duplicate operation, we expect only one operation to be performed (Duplicate). But instead, both Duplicate and Subtract actions are performed at the same time, because we have custom single key binding for the D key.

Problem:

This behavior forces Users to avoid using custom bindings for common keys like A, S, D, Z, X, C, V, because it disrupts standard modifier key functions (CTRL+A for select all, CTRL+S for save, CTRL+D for duplicate, CTRL+Z for undo, CTRL+X for cut, CTRL+C for copy, and CTRL+V for paste).

Fix proposal:

Modify Ued so that when modifier keys (CTRL, ALT, SHIFT) are pressed, they temporarily ignore the custom bindings of single keys. This would ensure that standard modifier key functions operate as expected, without interference from custom key bindings.

SeriousBuggie commented 2 months ago

Yes. it can be filtered by modfifixer I guess. But still can be problems with single keya: A for add actor, P for toggle realtime/play mode, L fo spam lights on mouse click, N for toggle paths, B for toggle RBB visibility and so on.

So mappers must be aware of that, and use game bind with cautions.

SeriousBuggie commented 2 months ago

Simplest test - bind something on "P" and try Use ALt+P for toggle realtime. In log must be no info on run bind command. Test version show in log all bind commands.