Return of the evil Hierarchy/Timeline bug!

Not favoritedFavorited Favorited 0 favourites
  • 4 posts
From the Asset Store
Game "Little Dino Adventure Returns" with complete Source-Code (Construct3 / .c3p) + HTML5 Exported.
  • Hello everyone!

    Ran into something weird while working on a rig using Hierarchy + Timeline. I've got two 4-level leg chains (Body > Leg_[L/R]_Seg1 > Seg2 > Seg3 > Seg4), with an Angle track on each segment in my "Idle" Timeline.

    The issue: if I replay the same Timeline multiple times (Stop then Play again), the angle on the deeper segments drifts on its own. Even when the Angle keyframe values never change between plays.

    What's weird: the drift isn't limited to the hierarchy children, even Body itself (the root, no parent) drifts downward over repeated plays in this example, so this doesn't seem to be purely a parent-child composition issue. Severity is also inconsistent between the two leg chains and between segments at different depths, even though Leg_L and Leg_R have the exact same structure and Angle track setup.

    I already dug around before posting this and found a few older bug reports (issues #7132, #7291, #5943 on Scirra's tracker) that looked like the exact same issue...

    I'm on r495.2, well past those fix versions, so this looks like either a regression or an edge case that slipped through. Maybe?

    I also tried switching the Angle track's Result mode to Absolute, it does stop the drift, but it also completely breaks the composition with the parent's rotation (the child stops following the parent's transform at all). At that point it kind of defeats the whole purpose of using Hierarchy in the first place, since you're back to manually setting every child's absolute transform yourself instead of letting the parent-child relationship do the work.

    I attached the c3p file exemple there: dropbox.com/scl/fi/fui3c4egyy6snywlrn7q6/TimelineHierarchyLegsTest.c3p.zip

    If any of you have the solution for this, I'll really appreciate as I'm blocked on my project with this issue…

    Thanks!

  • No one can help me about this issue?

    It's really a big trouble for me as I'm actually blocked on my project now. The only other solution I have is to make my animation in Spine and then export it using a pluging for Construct but it's really annoying because the timeline was supposed to works fine. Especially because of Construct Animate development…

    At least that was what I though.

  • What is happening is that when you stop a timeline all of it's state is discarded and the instances are left at their ending position. If you then start playing it again all of it's values are applied to the corresponding instances relative to their new transformation which is different to the initial transformation in the editor.

    In this case the initial editor state is the spider with the legs in a flat position. That is why the timeline works the first time, all of it's values are applied in relation to that initial transformation, when you play it again though, that is not the case any more so it starts looking strange.

    What you can do in this particular case is pausing and resuming the timeline, rather than stopping it and playing it again. When you pause it, the state is not thrown away altogether, so resuming it works as you would expect.

    Will likely add another action to give the option to reset a hierarchy in a timeline to it's initial pose.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Hi DiegoM,

    Thanks for your explanation. I tried your suggestion of pausing/resuming, but I didn't go into enough detail in my first message to explain the problem properly, my mistake.

    I actually have multiple timeline for my character (a boss) like appear, idle, crush, attack A, attack B, death, etc…

    It seemed easier for me that way as I want its actions to be randomized. So when I switch to another timeline, the offset happens. It happens exactly once I load a timeline for the first time. Once that first switch happens, the offset stays stable if I go back to a previous timeline that's already been played.

    I changed a bit my example: dropbox.com/scl/fi/v73ffcvmnzlexpym6o08g/TimelineHierarchyLegsTest.c3p

    I also tried several things but it didn't fix anything:

    • Stop all (I expected this to reset to the initial editor state per the tooltip, but the drift is still there)

    • Set time to 0 on the paused timeline before switching

    • Adding Wait 0 between Play/Pause calls to force different ordering across ticks (this actually changes which transition the offset shows up on, but never removes it)

    • "Warming up" every timeline once with Play all before ever using them for real gameplay

    I noticed in your segmented boss fight example that all the different timelines are played from inside a function. Is using a function a requirement for timelines to work correctly, or just a structural choice in that example?

Jump to:
Active Users
There are 0 visitors browsing this topic (0 users and 0 guests)