Character BP not taking keyboard input, but will take mouse click

328706-charbp-no-key-input.jpg

I’ve tried about 10+ post solutions that none have worked. But I can’t seem to get keyboard input to trigger. It works fine in level blueprint…I’m certain it’s a BP Class issue or something, but I don’t understand why mouse click will PrintString, while keyboard will not.

I could be wrong, but I think that:
You have to make sure the actor that is expected to handle input, is set up to receive input.
If it is a Player Controller class, then it most likely receives input by default.
If it is any other class, then it either needs to be possessed by playercontroller 0 (which is the one that gets all the mouse and keyboard inputs), or you have to set it to receive input.

The details pane of an actor should have the options to set it to receive input, usually from a specific playercontroller, if I remember correctly.

I’m not sure why it’s getting the mouse input though.

It is very possible another actor is CONSUMING the input for pressing the ‘1’ key before it reaches the actor you’re having trouble with.

Look through every other blueprint you have that takes the keyboard “1” input, check whether that input event node is set to Consume Input. If it is, then that’s likely the reason it’s not reaching this one because it already got handled AND consumed by another actor.

I’m not sure why the other images I’d attached don’t just show up like the first one…but you can click on them individually to see I’m setting the player to enabled, and possessed, and all that jazz.
I don’t have any of my othe blueprints doing any other keyboard inputs…so the Consume thing seems unlikely. Of course there’s no way that I KNOW OF to search the project for a conflicting blueprint…but those shouldn’t matter if they are NOT in or referenced in an object in the Level/World Outliner, right?

Okay, I checked out the other screenshots.
I agree - even if another actor would have taken the input it shouldn’t happen if they’re not in the level during gameplay.

This is a tough one. A couple of other things I thought of to check:

  • Project Settings > Input: Is there anything that maps the 1 key to any inputAction or inputAxis? If so, does it work if you replace your “1” node with that inputAction?
  • Are you pressing 1 on the numpad or on the number row of the keyboard? I think they might have different event nodes for each.
  • I’m assuming you’re testing in PIE. Does it work in Standalone mode?

I’ve tried a bunch of different keys other than “1”. I’ve tried action mappings, and yes…keypad vs keyboard numerals. I think there is something blocking me. Like…Do I need to enable characters to allow keypresses in game mode, or something like that? some global variable, or console variable needs a thumbs up?

I’m curious if anyone has any sample projects they can point to that has a character blueprint executing key presses. Last resort will be to see what the controller input is doing for 3rd person shooter, but that might follow the same rules as why my mouse-clicks work, but keyboard doesn’t

Is this a custom character BP then? Have you tried adding a custom input in project settings? Do you have a character movement component set up? It shouldn’t be a conflict w/ another player actor as the player controller will swap to whatever the current possessed character is, using only that player controller. Make sure you’re using actor or character and not pawn.

That’s worth looking into - is the playercontroller set for its Input Mode to UI Only, Game Only or Game and UI?

SOLUTION Here

Explanation Why?
The Actual problem lies in Receiving the input As the Mouse is Default selector It will Take input…(Most of the cases) as for the Keyboard if Multiple Objects(widgets or actors) have events on keyboard or Any thin… It will Bottleneck each other Resulting Some may not be working…

So for the Solution 1 - Do Enable and Disable input As required And Disable the input on Beginplay or Initialize…(i have tried possess and all it dont work like that)

Solution 2 (Worked for me) - When Click on the Event of Keyboard like ‘Enter’ in its details panel Turn off the ‘Consume Input’