Nucleus handler tools › Docs › ProtoInput
ProtoInput
Open in the workbench (search, and try it in a handler)
Proto Input calls at runtime, inside Game.Play and other callbacks.
ProtoInput.AddHandleToRename— Needs the RenameHandlesHookID hook. Any mutex, event or semaphore the game creates or opens whose name contains this text gets a random…ProtoInput.AddNamedPipeToRename— Needs the RenameHandlesHookID hook. Any named pipe the game creates whose name contains this text gets a random number appended.…ProtoInput.AddSelectedKeyboardHandle— Assigns a keyboard to the game instance, so its raw input drives that instance's fake keyboard. Parameters: the instance handle and the…ProtoInput.AddSelectedMouseHandle— Assigns a mouse to the game instance, so its raw input drives that instance's fake mouse. Parameters: the instance handle and the mouse's…ProtoInput.AllowFakeCursorOutOfBounds— Changes how far the fake cursor can move. Parameters: the instance handle, allowOutOfBounds (true: no limit at all) and extendBounds (true:…ProtoInput.DisableMessageBlock— Stops blocking a window message that ProtoInput.EnableMessageBlock blocked. Parameters: the instance handle…ProtoInput.DisableMessageFilter— Turns off a window message filter in the game instance. Parameters: the instance handle (Player.ProtoInputInstanceHandle) and a filter ID…ProtoInput.EasyHookInjectRuntime— Loads Proto Input into a running process with EasyHook, through the helper ProtoInputIJ32.exe/ProtoInputIJ64.exe. Parameters: the process…ProtoInput.EasyHookInjectStartup— Starts a game executable suspended and loads Proto Input into it before it runs. Parameters: the exe path, the command line, the process…ProtoInput.EasyHookStealthInjectRuntime— Same as ProtoInput.EasyHookInjectRuntime, but EasyHook injects in stealth mode (EASYHOOK_INJECT_STEALTH). Parameters: the process ID and…ProtoInput.EnableMessageBlock— Blocks a window message in the game instance: the game reads it as an empty message (WM_NULL). Parameters: the instance handle…ProtoInput.EnableMessageFilter— Turns on a window message filter in the game instance. Parameters: the instance handle (Player.ProtoInputInstanceHandle) and a filter ID…ProtoInput.GetTaskbarAutohide— Returns true if the Windows taskbar is set to auto-hide. Takes no parameters.ProtoInput.InstallHook— Installs a Proto Input hook in the game instance. Parameters: the instance handle (Player.ProtoInputInstanceHandle) and a hook ID from…ProtoInput.LockInput— Locks or unlocks the real mouse and keyboard for the whole PC (runs in Nucleus, not in a game): while locked, mouse input is blocked, keys…ProtoInput.RemoteLoadLibraryInjectRuntime— Loads Proto Input into a running process by calling LoadLibraryW inside it. Parameters: the process ID and the folder that holds…ProtoInput.RestartExplorer— Resumes the explorer.exe threads suspended by ProtoInput.SuspendExplorer. Takes no parameters. Nucleus calls it when input is unlocked.ProtoInput.SetAdjustWindowRectSettings— Sets the rectangle the AdjustWindowRectHookID hook starts from: every AdjustWindowRect/AdjustWindowRectEx call computes the window size…ProtoInput.SetControllerIndex— Chooses the controllers the game instance sees through the XinputHookID hook. Parameters: the instance handle, then the controller for the…ProtoInput.SetCreateSingleHIDName— Sets the one HID device path the CreateSingleHIDHookID hook lets the game open; opening any other path containing "HID" or "hid" fails.…ProtoInput.SetCursorClipOptions— Option for the ClipCursorHookID hook. true (the default) turns the game's ClipCursor area into a limit for the fake cursor; false ignores…ProtoInput.SetDefaultBottomRightMouseBounds— With ProtoInput.SetPutMouseInsideWindow on, true restores the default bottom and right limit of the fake cursor (the window width and…ProtoInput.SetDefaultTopLeftMouseBounds— With ProtoInput.SetPutMouseInsideWindow on, true restores the default top and left limit of the fake cursor (-1 instead of 0). Parameters:…ProtoInput.SetDinputDeviceGUID— Chooses the DirectInput controller the DinputOrderHookID hook opens for every DirectInput device the game creates. Parameters: the instance…ProtoInput.SetDinputHookAlsoHooksGetDeviceState— When true, the DinputOrderHookID hook also hooks the controller's GetDeviceState. Parameters: the instance handle and true/false. Call it…ProtoInput.SetDontWaitWindowBorder— Option for the RemoveBorderHookID hook: when true, it removes the main window's border right away on install instead of waiting up to 10…ProtoInput.SetDrawFakeCursor— Shows or hides the fake cursor Proto Input draws over the game for this instance. Parameters: the instance handle and true/false.ProtoInput.SetDrawFakeCursorFix— Switches the fake cursor to an alternative drawing mode that offsets it by the cursor image's detected hotspot and does not resize it for…ProtoInput.SetExternalFreezeFakeInput— When true, Proto Input stops passing the assigned mouse and keyboard input to the game instance. Parameters: the instance handle and…ProtoInput.SetManualScaling— Rescales the mouse position the game sees (mouse messages, GetCursorPos, GetCursorInfo) by oldX/newX and oldY/newY. Parameters: the…ProtoInput.SetMoveWindowDontReposition— When true, the MoveWindowHookID hook keeps the position the game asked for and only forces the size. Parameters: the instance handle and…ProtoInput.SetMoveWindowDontResize— When true, the MoveWindowHookID hook keeps the size the game asked for and only forces the position. Parameters: the instance handle and…ProtoInput.SetMoveWindowSettings— Sets the position and size the MoveWindowHookID hook applies to every MoveWindow call. Parameters: the instance handle, x, y, width, height…ProtoInput.SetPointerInMouse— When true, Proto Input subclasses the game's main window and turns mouse messages into pointer messages (WM_POINTERUPDATE, WM_POINTERDOWN,…ProtoInput.SetPutMouseInsideWindow— When true, the fake cursor is kept inside the game window (from 0 to width minus 1) and its drawing window is placed with the game window…ProtoInput.SetRawInputBypass— When true, raw input from every mouse and keyboard is forwarded to the game unchanged, not only from the assigned devices, and Proto…ProtoInput.SetReregisterinput— Option for the RegisterRawInputHookID hook: when true and the game registered for raw input without a target window, the game's main window…ProtoInput.SetSendMessagesToSubWindows— When true, left, middle and right mouse button messages are also posted to the child window under the fake cursor, not only to the main…ProtoInput.SetSetWindowPosDontReposition— When true, the SetWindowPosHookID hook keeps the position the game asked for and only forces the size. Parameters: the instance handle and…ProtoInput.SetSetWindowPosDontResize— When true, the SetWindowPosHookID hook keeps the size the game asked for and only forces the position. Parameters: the instance handle and…ProtoInput.SetSetWindowPosSettings— Sets the position and size the SetWindowPosHookID hook applies to every SetWindowPos call. Parameters: the instance handle, x, y, width,…ProtoInput.SetShowCursorWhenImageUpdated— Option for the CursorVisibilityStateHookID hook. When true, every SetCursor call with a cursor image shows the fake cursor; when false,…ProtoInput.SetTaskbarAutohide— Turns auto-hide of the Windows taskbar on (true) or off (false). It also turns the taskbar's always-on-top state off.ProtoInput.SetToggleFakeCursorVisibilityShortcut— Sets a key that shows or hides the fake cursor when pressed on the instance's keyboard; that key press is not passed to the game.…ProtoInput.SetTranslateMKBtoXinput— When true, the XinputHookID hook presents the instance's mouse and keyboard as an XInput controller in the slots that have no controller.…ProtoInput.SetTranslateXinputtoMKB— When true, Proto Input turns the instance's controller into mouse and keyboard input for the game. It is switched off again if a mouse or…ProtoInput.SetupMessagesToSend— Chooses which window messages Proto Input posts to the game window from the assigned mouse and keyboard. Parameters, in order: the instance…ProtoInput.SetupState— Tells Proto Input in the game which instance number it is, starting at 1 (lower values are refused). Parameters: the instance handle and…ProtoInput.SetUseDinputRedirection— When true, the XinputHookID hook reads a DirectInput controller (the one chosen by ProtoInput.SetControllerIndex, among DirectInput…ProtoInput.SetUseOpenXinput— When true, the XinputHookID hook reads controllers through OpenXinput instead of xinput1_3.dll, which allows controller numbers above 4.…ProtoInput.SetXinputtoMKBCFG— Sets options for ProtoInput.SetTranslateXinputtoMKB. Parameters, in order: the instance handle; swap sticks; screen scanning (moves the…ProtoInput.SetXinputtoMKBkeys— Sets the controller-to-keyboard mapping used by ProtoInput.SetTranslateXinputtoMKB. Parameters, in order: the instance handle; virtual-key…ProtoInput.StartFocusMessageLoop— Starts posting focus messages to the game's main window in a loop, so the game believes it is focused. Parameters, in order: the instance…ProtoInput.StopFocusMessageLoop— Pauses the focus message loop started by ProtoInput.StartFocusMessageLoop. Parameter: the instance handle.ProtoInput.SuspendExplorer— Suspends the threads of explorer.exe that own the taskbar, start menu, Alt+Tab and desktop menus, so they can't be opened by accident.…ProtoInput.UninstallHook— Removes a Proto Input hook from the game instance. Parameters: the instance handle (Player.ProtoInputInstanceHandle) and a hook ID from…ProtoInput.UpdateMainWindowHandle— Sets which window Proto Input treats as the game's main window (focus, cursor and input messages target it). Parameters: the instance…ProtoInput.Values· ProtoInputValues — Hook and message filter IDs for InstallHook, EnableMessageFilter, ...ProtoInput.Values.AdjustWindowRectHookID· number — Selects the AdjustWindowRect hook (ID 20): AdjustWindowRect and AdjustWindowRectEx compute the window size from the rectangle set by…ProtoInput.Values.BlockRawInputHookID· number — Selects the block raw input hook (ID 15): GetRawInputDeviceList and GetRegisteredRawInputDevices report no devices to the game. Pass it to…ProtoInput.Values.ClipCursorHookID· number — Selects the ClipCursor hook (ID 9): the game's ClipCursor no longer confines the real cursor; by default it confines the fake cursor…ProtoInput.Values.CreateSingleHIDHookID· number — Selects the single HID hook (ID 17): once ProtoInput.SetCreateSingleHIDName is set, the game can open only that HID device path. Pass it to…ProtoInput.Values.CursorVisibilityStateHookID· number — Selects the cursor visibility hook (ID 8): the game's ShowCursor, SetCursor and SetSystemCursor calls show, hide and set the image of the…ProtoInput.Values.DinputOrderHookID· number — Selects the DirectInput order hook (ID 13): every DirectInput device the game creates opens the controller set by…ProtoInput.Values.FindWindowHookID· number — Selects the FindWindow hook (ID 16): FindWindow and FindWindowEx find nothing and EnumWindows lists no windows, so an instance can't find…ProtoInput.Values.FocusHooksHookID· number — Selects the focus hooks (ID 10): GetForegroundWindow, GetActiveWindow, GetFocus, GetCapture and WindowFromPoint return the game's main…ProtoInput.Values.GetAsyncKeyStateHookID· number — Selects the GetAsyncKeyState hook (ID 6): GetAsyncKeyState reports the keys and buttons of the instance's assigned keyboard and mouse. Pass…ProtoInput.Values.GetCursorInfoID· number — Meant to select the GetCursorInfo hook, which makes GetCursorInfo report the fake cursor position. In Nucleus this value equals…ProtoInput.Values.GetCursorPosHookID· number — Selects the GetCursorPos hook (ID 3): gives each instance its own cursor position, as GetCursorPos returns the instance's fake cursor. Pass…ProtoInput.Values.GetKeyboardStateHookID· number — Selects the GetKeyboardState hook (ID 7): GetKeyboardState reports the keys and buttons of the instance's assigned keyboard and mouse. Pass…ProtoInput.Values.GetKeyStateHookID· number — Selects the GetKeyState hook (ID 5): GetKeyState reports the keys and buttons of the instance's assigned keyboard and mouse. Pass it to…ProtoInput.Values.GetRawInputDataHookID· number — Selects the GetRawInputData hook (ID 1): when the game reads raw input that Proto Input forwarded, it gets the assigned device's data;…ProtoInput.Values.KeyboardButtonFilterID· number — Selects the keyboard button filter (ID 7): only WM_KEYDOWN/WM_KEYUP messages synthesized by Proto Input reach the game, so the real…ProtoInput.Values.MessageFilterHookID· number — Selects the message filter hook (ID 2) on GetMessage/PeekMessage: messages the game reads carry the fake cursor position, and the enabled…ProtoInput.Values.MouseActivateFilterID· number — Selects the mouse activate filter (ID 2): WM_MOUSEACTIVATE messages always tell the game it is being focused. Only acts while…ProtoInput.Values.MouseButtonFilterID· number — Selects the mouse button filter (ID 6): only mouse button messages synthesized by Proto Input reach the game, so the real mouse doesn't…ProtoInput.Values.MouseMoveFilterID· number — Selects the mouse move filter (ID 1): WM_MOUSEMOVE messages carry the instance's fake cursor position and button and modifier state. Only…ProtoInput.Values.MouseWheelFilterID· number — Selects the mouse wheel filter (ID 5): only WM_MOUSEWHEEL messages synthesized by Proto Input reach the game, so scrolling isn't sent…ProtoInput.Values.MoveWindowHookID· number — Selects the MoveWindow hook (ID 19): every MoveWindow call uses the position and size from ProtoInput.SetMoveWindowSettings. Pass it to…ProtoInput.Values.RawInputFilterID· number — Selects the raw input filter (ID 0): WM_INPUT messages always say they arrived while the game was in the foreground. Only acts while…ProtoInput.Values.RegisterRawInputHookID· number — Selects the RegisterRawInput hook (ID 0): the game's RegisterRawInputDevices calls no longer reach Windows, and Proto Input forwards only…ProtoInput.Values.RemoveBorderHookID· number — Selects the remove border hook (ID 21): removes the main window's border and title bar on install (see ProtoInput.SetDontWaitWindowBorder),…ProtoInput.Values.RenameHandlesHookID· number — Selects the rename handles hook (ID 11): mutexes, events, semaphores and named pipes whose names match ProtoInput.AddHandleToRename or…ProtoInput.Values.SetCursorPosHookID· number — Selects the SetCursorPos hook (ID 4): the game's SetCursorPos moves only the instance's fake cursor, not the real one. Pass it to…ProtoInput.Values.SetWindowPosHookID· number — Selects the SetWindowPos hook (ID 14): every SetWindowPos call uses the position and size from ProtoInput.SetSetWindowPosSettings. Pass it…ProtoInput.Values.SetWindowsHookHookID· number — Selects the SetWindowsHook hook (ID 23): the game's low-level keyboard, low-level mouse and GetMessage hooks are not registered with…ProtoInput.Values.WindowActivateAppFilterID· number — Selects the window activate app filter (ID 4): WM_ACTIVATEAPP messages always say the game is active. Only acts while MessageFilterHookID…ProtoInput.Values.WindowActivateFilterID· number — Selects the window activate filter (ID 3): WM_ACTIVATE messages always say the game window is active. Only acts while MessageFilterHookID…ProtoInput.Values.WindowStyleHookID· number — Selects the window style hook (ID 18): window styles the game sets with SetWindowLong/SetWindowLongPtr lose the border, system menu and…ProtoInput.Values.XinputHookID· number — Selects the XInput hook (ID 12): each instance sees only the controllers chosen by ProtoInput.SetControllerIndex, in the order given. Pass…ProtoInput.WakeUpProcess— Resumes the threads of a game started suspended by ProtoInput.EasyHookInjectStartup, then looks for its main window again. Parameter: the…