Nucleus handler tools › Docs › Checks

A message filter without its hook

Warningprotoinput-needs-hookA Nucleus check · Probably wrong: Nucleus runs it, but not the way you meant.

Why it matters

Game.ProtoInput.BlockedMessages and the message filters only act inside Proto Input's message filter hook; without that hook they do nothing.

Example

✗ Wrong

Game.ProtoInput.InjectStartup = true;
Game.ProtoInput.BlockedMessages = [0x0008];

✓ Right

Game.ProtoInput.InjectStartup = true;
Game.ProtoInput.MessageFilterHook = true;
Game.ProtoInput.BlockedMessages = [0x0008];

How to fix it

Add Game.ProtoInput.MessageFilterHook = true; (the quick fix does).

Turn it off, or change how it shows

Each check can be shown as an error, warning, info or hint, or turned off. VS Code: "splitscreenme.lint.rules": { "protoinput-needs-hook": "off" } in your settings. Notepad++: Plugins › Nucleus Co-op handlers › Settings. Command line: ncdev lint --rule protoinput-needs-hook=off. Other editors: the lint.rules setting of ncdev lsp.

Is this right? Tell us what's wrong
Stuck, or not sure? Ask other handler authors: Discordr/nucleuscoop