3 Blueprints - one holding a cube, one a sphere and one a cone.
Blueprint interface set on sphere and cone so that when you click the cube, sphere and cone change colour. All is fine.
Is it possible to put the cone BP inside the sphere BP and still make calls to both?
Currently with my setup only the sphere changes colour. It seems that there is no way of getting reference to the cone BP inside the sphere BP or am I just messing up, which is usually the case? Selecting the cone BP and dragging it to the event graph of sphere results in the âdoes implement interfaceâ failing.
First things first. These should all just be instances of one BP. You get to select the static mesh when you drop it in the level.
Then, Iâm guessing youâre saying, âwhen I click BP A, I want BPs B and C to change colorâ?
Totally doable with just one BP. The BPI has two calls
-
Change color
-
You have been clicked
When you click a BP it can tell the other 2 to change color.
You donât actually need BPIs to make this work, but itâs a good idea to learn about them.
Make the blueprint like this ( construction script and colors array )
BPI
Event graph
So I put 3 in the level, I can change the mesh on the instance:
Thank you for the response. I needed to be more clear in my question. It was to do with communication between blueprints.
So it is easy to use the interface to set up comms between BP A, BP B and BP C, with BP A sending commands to BP B and BP C. In my example changing colours.
However what I am struggling with is if you need to nest BP C inside BP B. I can still get BP A to communicate with BP B, but not BP C. I am currently reviewing dispatchers to see if that solves the issue. Any advice would be appreciated.
Hi - dispatchers wonât help.
If you had MyBP, and it had a child that was also MyBP, you would have to
As you can see, child actors is not a great way to go in blueprint.
Maybe you can say why you want this setup, and I can recommend a route. Forget about BP for the moment, just describe the functionality you need.
Thank you for the response - I did track down getting the Child Actor then that allows you access to the interface calls.
In terms of what I am trying to do, think of a carousel (C) or a ferris wheel (F).
It would seem to make sense to make a BP C for the horse+pole (C) or Carriage/Seat/Pole/Roof(F).
Then have a BP B that holds the number of those elements needed eg 10 horses, 10 carriages. BP B can then be rotated as a single item.
Then have a BP A the hold the stationary structural geometry of (C) or (F) and also BP B.
Then it is a case of how BP A can communicate with the elements of BP B or all BP Cs.
Hope that makes sense.
So in BP A, there is a BP called BP Ferris Ring and Carriages (BPFRC)
I can get the child actor of that.
Start Just Ferris Wheel is the interface element which is in (BPFRC), so can be called.
This seems to work OK. I do not know if it is the âcorrectâ way of doing it.
Yes, this is correct. And access the child as an actor, which is the point most people would miss.
I appreciate what youâre saying, but as you work with BPs and BP child actors, youâll find itâs a lot easier to make all these things separate BPs
Again, thanks for the prompt responses and advice.