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"

Multi player casts to one blueprint

I was hoping to find out some information in regards to how Unreal Engine 4 handles multiple casts to a single blueprints, specifically what happens when more than one player calls a function in a blueprint.

Does it complete the first call then complete the second, or does the second call cancel the first call from running.

This is specifically surrounding adding instances in a master Instance Static Mesh (actor).

Product Version: UE 4.10
more ▼

asked Mar 09 '16 at 01:20 PM in Blueprint Scripting

avatar image

68 13 18 29

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

1 answer: sort voted first

What I found out when testing this a while ago was this:

Events get canceled when called again and start over. Everything else works just fine.

If you call a function that one will also be finished. You will always get the return value.

Casting doesn't impact anything. You are basically asking a thing "Hey are you an apple?" and the cast will say "Yes!" or "No". It does not impact the object itself in any way.

Does that answer the question?

more ▼

answered Mar 09 '16 at 01:57 PM

avatar image

6k 291 86 293

avatar image Zedrophobe Mar 09 '16 at 02:43 PM

Well the casting makes sense to me thank you. The event calls I'm still unsure about. If you have a shared event that gets called is the a way of buffering them. Or does the event tick as it were, so it completes everything in the chain every tick (cast to) of an event?

avatar image Erasio Mar 09 '16 at 03:43 PM

You can't call event tick (or shouldn't anyway).

And as long as you don't have anything that delays anything else there is no issue with Events either as the code will be run though and then another possible call will happen.

BUT if you use something like delay, load asset or such. Something that runs asynchronously and can not be completely immediately this becomes a problem.

For example:

You have a shooter. As not too experienced programmer you set up each projectile to include all possible things that could happen including a value for damage over time.

A projectile which deals fire damage hits you. You call your own event "FireDoT" which includes a self written loop and a delay so it will deal the fire damage once every second until a timer finished.

A frame later another projectile hits you, calls the FireDoT event as well but with less damage per second.

Your first event is canceled and only the second event runs now.

(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