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"

Instance bool var in instanced blueprint

Hello,

I have single blueprint which i copied 10 times in editor.So i want set to true Instanced bool before timeline start and when animation is finished i want set this variable to false.So as far i can see for my 10 copies of this blueprint timeline works independent for each one instance of blueprint. The problem comes when i want to play animation for 2 or more copies of this blueprint. And if 1st copy finish animation when the second just sit there with bool value true and wait to be executed from custom event, the first one will set bool to false for all copies of this blueprint.

Is there any way to keep bool value independent for each copy of blueprint, so when 1 copy finish timeline animation will set bool to false only or its self and not the rest copies ?

Regards!

alt text

Product Version: UE 4.17
Tags:
instancedbool.png (94.8 kB)
more ▼

asked Oct 26 '17 at 11:07 AM in Blueprint Scripting

avatar image

MosPetrov
33 1 5 13

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

1 answer: sort voted first

It should work independent for any instance. I think you just have its value as false by default.

more ▼

answered Oct 26 '17 at 11:14 AM

avatar image

redbox
4.3k 81 19 104

avatar image MosPetrov Oct 26 '17 at 11:28 AM

Hello, Redbox

Thanks for fast reply, i appreciate it! Yes my default value is false, but i need to be false, since this custom event is triggered from another branch.Simply in my case i have another blueprint when it overlap on something set this bool to true,then from another blueprint i check if this bool is true and if it is i call this custom event which triggers the timeline and set this bool to false on anim finish, but the problem is when i already overlapped and triggered the anim of 1 copy and during the animation if i overlap second actor also this bool will be true( the animation for the first one is not finished) and when the anim for the first finish will set the bool to false for its self and also for the second overlapped actor.I wonder if there is a way to keep the second actor bool to true even when the first finish anim and set it to false.

Regards!

avatar image redbox Oct 27 '17 at 06:21 AM

What do you trying to achieve? I cant get purpose of this setup.

avatar image MosPetrov Oct 27 '17 at 06:46 AM

Hello, Redbox

I have an some kind of car track which is vector, and i have 10 cars which wait to be overlapped to trigger vector anim from Point A( where the trigger is) to point B.I have second blueprint which is some kind of button and whit get all actors of class and cast to car blueprint i get this bool variable and if its true fires the custom event inside of car BP which trigger the timeline anim for the car.

The cars are blueprint which i duplicate 10 times in the editor. So when i overlap one car set this bool variable to true and when timeline anim finish to set it false.The problem is when there is already a car in the track and if i overlap a second car and if i trigger the second car animation after the first car is finish i cant because the first car already set the bool variable to false.

Regards!

(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