Hud added multiple times in multiplayer (network)

I’m trying to add a health bar HUD to my game. I created a hud widget blueprint and set it all up. When I add it to the game like in most of the samples I’ve come across, it ends up added multiple times in a multiplayer network game.

I´m using Event Begin Play, Set Imput Mode Game Only, Create HUD Widget, Set, Is valid, Add to viewport, AND THEN i put the widged of the hud that gets added multiple times in multiplayer for some reason (the one in the top)

When I play a 2 player networked game, the Add to Viewport gets called twice for the server and twice for the client. This ends up making a duplicate hud of the wrong player. So Player 1 sees Player 2’s hud overtop theirs. Player 2 sees Player 1’s hud overtop of theirs.

I can’t figure out how to only add the HUD to the local user.

I used saw this post: https://answers.unrealengine.com/questions/396227/hud-added-multiple-times-in-multiplayer-network.html But making a widget didnt work for me, it still gets added multiple times :confused:

Same problem

try this https://answers.unrealengine.com/questions/396227/hud-added-multiple-times-in-multiplayer-network.html

it doesent work for me, but maybe it works for you

i hope you can fix it sometime!

thx! i hope too, maybe someone helps ^^

i tried some things and still doesent work :frowning:

thank you !!! :smiley:

Fixed it myself!
I dont know why no one here really helped :confused: but it was just one thing, let me show:

If you have this problem just make a branch with the condition is locally controlled!

1 Like