How to transform for each instance over time

Hello

I have a vehicle that carries a hitbox in the front.

Objects that overlap shall elevate 3 meters above the ground and then vanish.

At the moment, if i use a timeline, then the timeline plays down one time and after that all new items just snap to the end position of the timeline instead of getting their own timeline and lerp.

How can i aply a transform over time for each element seperatly?


i know that i could use “play from start” but that stops the moving of all other actors if a new one interrupts their movement.

I guess it is because i do not use object-oriented programming the intended way. A hint in the right direction would be lovely.

i hope my infos are sufficient, else please tell me what additional information is needed or helpful
thanks a lot

1 Like

image

:slight_smile:

Yes, you need ‘play from start’, but you also need one of two other things

  1. An array of actors that you are transforming with this timeline, on the update pin, you have to perform the action for each actor in a loop

  2. Make the actors blueprints that can manage their own timeline

PS 2 is the OO method… :smiley: You make a parent BP that knows how to reduce itself, and make the mesh configurable.

hi there. thanks for helping

something like this?:

this lets still move each object further up, every time a new objects gets added.

i think if i can remove the objects from the array after if reached it end position then it would be good.

i allready tested if the timeline needs to be inside the loop but i think then is still one timeline running for each object.

i feel like i oversee the obvious. sry.

and the OO way… i think i need more time untiol i get that. thx for telling <3

OO is much easier

Make a BP like this

Put 3 in the level

and go

shapes1

Doesn’t matter how many etc

shapes2

Set the mesh in construction

and choose your mesh in the level

Hi there and thanks a lot!

With your solution, i made it work.

Sadly there is a lot more down the rabbit hole that hinders me in making it clean OO like you said but at least each BP now manages its own timeline.

in my project the player can collect the foliage. for that i destroy the instanced foliage static mesh and spawn a bp one to transform it with a nice animation. this question was the solution for this last part.

i will definitely be back sooner or later to change the whole project from “if A then a ELSE if B then b ELSE if C then c” etc etc to a clean OO layout.

But for the moment this worked out nicely. Thanks a lot!!!

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.