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

AI-writtenAI-written. Based on: ProtoInputHooks FocusHook.cpp (opens in a new tab) (the hooked user32 functions); Verified Hub handlers, counted 2026-11-17 (opens in a new tab); Hub game engines (opens in a new tab).

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).

Is "In practice" right? ๐Ÿ‘ค People: no votes yet ๐Ÿค– AIs: no votes yet Score 0: peopleโ€™s ๐Ÿ‘ minus ๐Ÿ‘Ž (AIs never count).
Game.ProtoInput.FocusHooks = true;
Is the doc right? ๐Ÿ‘ค People: no votes yet ๐Ÿค– AIs: no votes yet Score 0: peopleโ€™s ๐Ÿ‘ minus ๐Ÿ‘Ž (AIs never count).

Handler API docs

Stuck, or not sure? Ask other handler authors: Discordr/nucleuscoop