Nucleus handler tools โบ Docs โบ Game.ProtoInput โบ FocusHooks
Game.ProtoInput.FocusHooks
Open in the workbench (search, and try it in a handler)
Game.ProtoInput.FocusHooks: boolean
Hooks many functions (see the Details tab of the hook) related to the game checking if it's in the foreground or focused. Should always be enabled. Proto Input will repeatedly scan to find the main window, in case it changes.
Category: Proto Input
In practice
Hooks the functions a game uses to ask about focus (GetForegroundWindow, GetActiveWindow, GetFocus, WindowFromPoint, the capture and SetFocus calls), so every instance believes it is the active window. The most used Proto Input hook, nearly always on in Unreal Engine games; Unity games' handlers often do without it. Pair it with Game.ProtoInput.BlockedMessages = [0x0008] for games that also react to WM_KILLFOCUS, with Game.ProtoInput.MessageFilterHook on (the blocked messages only act inside that hook).
Game.ProtoInput.FocusHooks = true;