Page MenuHomeFeedback Tracker

Add ActionManager::DeactivateContext and DeactivateAction
Reviewed, NormalPublic

Description

If possible alongside ActivateContext there should be a DeactivateContext
and alongside ActivateAction a DeactivateAction

Details

Severity
Tweak
Resolution
Open
Reproducibility
N/A
Operating System
Windows 10 x64
Category
General

Event Timeline

Geez changed the task status from New to Reviewed.Feb 2 2023, 10:09 AM
Geez added a subscriber: Geez.Feb 3 2023, 10:23 AM

Hello TheBonBon.
According to the devs: There is no "Deactivate" by design. You need to call ActivateContext periodically to make context active. So Context is deactivated by not calling ActivateContext or activating another context with higher priority (which block/deactivate all other contexts with lower prio).

Regards,
Geez

Hello Geez,

What about actions that are not in a context? They don't have a priority setting.

Regards,
TheBonBon

Hello Geez,

What about actions that are not in a context? They don't have a priority setting.

Regards,
TheBonBon

I found out that normal actions have a context that references them.

I'm trying to only block the CharacterWeaponContext (prio: 1) and GadgetContext (prio: 4) but keep all other contexts with lower prio active.
I could override the priorities but I don't know how that would affect other stuff.

Maybe not deactivating contexts but something like this would be nice to have, so its possible to block the input from being proccessed further. So even though its still active it doesn't trigger anything.
This way you could target specific contexts or even actions and keep all others "functional".
InputManager::BlockContext(string name, bool blocked)