What is the smart way to make a blueprint that animates a bridge of steps into place? I don’t want to do it as a block but rather as a rolling motion for several blocks.
The method I’ve tried for now looks tedious and maybe computationally expensive.
I guess I’m lost as to how to make an array with offset timing for the animation. (to make the movement of objects roll in a uniform way.) If I use a delay, it just delays everything evenly.
I could do something like this. But this is ugly and I have to make a bunch of duplicate float tracks that are all offset. And if I have 30 objects… That is also tedious.
The thing is I was going to have a variety of rippling effects. Are you suggesting this can be done with construction scripts? Here is another video that might be helpful. (notice how the objecs are rotating freely before they lock into place. But they get sent back and start rotating freely once mario moves away.) So it is two things. The path can assemble itself as the player progresses. So the player controls the pacing of the assembling of the bridge. But at some point. The difficulty of the game increases and the player is no longer controlling the pacing of the bridge being assembled. That the game then assembles the bridge at a predetermined pace and the player just has to keep up with the pace of the assembling of the bridge. So I guess…
Easy Bridge level: Player based pace would just be lerps based on distance from the bridge piece?
Hard bridge level: Should I take the Easy bridge level and instead using the player position have a custom animation null object that runs through easy bridge level to facilitate the automated assembling process of the hard bridge level? (sorry I’ve been so difficult to explain this.)
3 actors: 1 that will be the trigger (puller) for when the player is approaching, 1 that wil hover in X position to hold the tile hovering, 1 that is the tile/floor itself.
Only place the trigger in the level; on begin play this trigger spawns the hover tile in a defined vector and the tile attached to the hover. The hover will have random rotation + nice hover effect.
when the trigger is active, attach the tile to the trigger and lerp the transform. on end overlap attach back to the hover actor and lerp the tile to it.
Change the trigger overlap to take another actor and move it through a spline so that the player has to follow its pace (but player wont see this actor).
This is just to get it working… you could save yourself the each instance with a timeline and have 1 actor manage all the lerps and hovers, but that tales a bit more time to put together.
Yep, I was thinking of this same thing. Using overlap in combination with move component. I don’t know if “move component” is the right way to do things. But that is what came to mind when CWO mentioned “lerp”.
(out the top of my head) If you want to make it work so that a single actor manages the transitions, I suggest considering the following:
Create the actor that will manage the transition. This will be the only class that will have tick enabled.
Have each trigger tell that actor that the player has overlapped. This will add them in an array so that this actor can manage the states.
Each platform should have a variable that holds current state (enum) and alpha (float). This class calls the a function that handles the lerp of each platform.
The way it would work is:
If trigger is overlapping pawn: Trigger informs manager and gets added to an array that is looping. Change state to “pull”, increment the alpha of the lerp (0 platform hovers, 1 platform is in bridge position). If alpha == 1.0, change state to “docked” (e.g.).
If trigger ends overlap with pawn: if its in array in manager, change state to “push” and decrement alpha calling the function of the lerp. If alpha == 0, change state to “floating” and remove from array.
Now, in c++ you can use custom float curves without timelines. Don’t remember if you can access their values in bp without a timeline node.
As alternative if you want all platforms to be in the loop and offset activate them from start → last with a delay: you could use MapRangedClamped.