x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

How to talk to multiple blueprints at once?

My main character holds 2 guns,one in each hand.But they are different actors from time to time since there are more then 2 pistols in the game available to the player.What is the best way to talk to both this actors at the same time?I tried custom events but then i have to cast to each of them actors individualy,and there are so many guns! Please guys,any idea or sugestion is a go for me!Thank you in advance

Product Version: UE 4.20
Tags:
more ▼

asked Oct 29 '18 at 01:53 AM in Blueprint Scripting

avatar image

ken09block123
8 1 4

avatar image Segovo Oct 29 '18 at 02:11 AM

Could you add images to explain the problem? I'm not sure I understand the issue.

avatar image AyanMiru Oct 29 '18 at 02:17 AM

Not sure about your setup. But It seems to be better idea to have one blueprint with gun model changing? Maybe creating a struct with parameters for different guns. If they have to be different actors then they can inherit from the same parent and you can call functionality on that parent.

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

2 answers: sort voted first

I don't have my computer now, but I post the picture as soon as i can. But its a simple situation : my character has 2 child actor slots (imagine they are each hand), and when i am holding 2 pistols at once, my character BP casts to a custom event inside one pistol then the other so it fires each gun when i want to. The problem is that i am casting to each pistol individually, so i thought, maybe theres a way to cast to whatever child actor i am currently holding? Rather than making i huge node mess, as i check witch of the dozens of weapons is the one i am currently holding? Sorry if sounds confusing, i post pictures asap

more ▼

answered Oct 29 '18 at 02:24 AM

avatar image

ken09block123
8 1 4

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

This is an official UE4 training video on all the different ways to communicate between blueprints. By the sound of your problem you will do best with the "Event Dispatchers" Part if you want to jump straight in but i would suggest watching the entire video helped me loads with similar issues of BP communications. https://www.youtube.com/watch?v=EM_HYqQdToE

more ▼

answered Oct 29 '18 at 02:05 PM

avatar image

mattyi85
16 1 4 8

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question