Problem with Spawning Actors from HUD Actions

Hello Everyone,

Im creating a Side-Scroller + Tower Defense Game, and I have some problems with the systems required to do so.

First, i can’t figure out how to Spawn (Build) a Turrent into an specified location from pressing a button in my HUD.
What i tried so far, was to create an Interface Blueprint between the Game_HUD and both LevelBlueprint and some other class blueprint witch I Called Turrent Spawn.

But it seems that the values of my variables on the HUD Blueprint dont get updated in any of the Blueprints Im working on.

Here is an Example of my problem:

This Image shows the variable that i have in GameHUD and the one witch i need to use to spawn the actor.

This if the BP Interface function inside GameHUD, this colect the value of the variable showned above, and send to the other BP.
4ecf59df496abbc7c63a8e5514cd4fd34e66608a.jpeg

This shows the Level BP and the Object Variable i created in order to try to get the value on GameHUD to the Level BP and make the spawn happen. (I exposed the variable in order to get to work, but it didnt)
bcf47b6444df79c579479d0e60f6895b50df6002.jpeg

This is the Spawn Turrent BP i tried toi make and BP Interface event and spawn the actor, but did not work too.

Please Help Me :frowning:

Is your interface implemented on all BP using this interface ? (Blueprint Props button=>Interfaces)

break it down, regardless if you are going to make it multiplayer.

  1. HUD is owned by PlayerController, once you have a button hit, try to get player controller and emit a control event.
  2. Spawn anything that affects games should be done in a GameMode BP, and you can put your state/resource checking here as well.(state/vars better save in GameState)
  3. if you want to have a hidden(no rendering) persistent object to do the spawning, then it would be level, but still let GameMode to send the message.

Hey PenguinTD and Eddy71, thanks for the tips, when you said about “emit a control event” I realized that the GameHUD does not execute nodes such as Spawn Actor from Events like “Begin Play”, then I tried to spawn an Actor from the Event “Receive Hit Box Release” and it WORKED! Thanks Dudes for all the Help!

BTW, i tried to get this system to work in the GameMode BP and it didnt, whenever i hit the Simulate Button, the Graph does not seem to work at all, its just dont activate any node, maybe I was doing it wrong, but anyway, Thanks again for the Help!