Adding an interact button to open a door with a key

@Everynone Okay, there’s actually one thing left to sort out. I forgot that the nodes on the right here…

…are needed in order for the keys to toggle on and appear in the player HUD. :sweat_smile:

I tried adding them here, but it looks like the Add to Map only allows one thing to hook up to.

EDIT: Okay, after a bit of experimenting, those nodes in the original Keycard_BP can stay where they are. I’ve also put the Destroy Actor back in there rather than after Add Map in the FirstPersonPlayer_BP. Things are looking to be working correctly and they appear in the HUD again. :slight_smile:

You have access the HUD in the player, no need to move the data around, hard reference the pawn and so on. Player overlaps the key → player updates its hud.

As always, I’m not having much luck moving it into the FirstPersonCharacter_BP. :-\ Using the same nodes as before, once I walk into a keycard, the player disappears/dies and I’m not able to move anymore. I’m always left with loads of errors. So as usual, I’m not sure how to approach this differently.

As mentioned above. Call the HUD here if you want to notify it that a key has been picked up. And destroy the key as the last thing. It sounds like you’re destroying the player, not the key. Connect the target pin.

1 Like

I was about to report that I was still struggling and having issues getting it set up correctly, but I managed to figure it out. I hope this is correct. It works anyway. :smiley:


Thanks again for your help.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.