Timeline question

0 favourites
  • 5 posts
  • Is it possible to move a sprite with Timeline, if I don't know the exact target position? For example, I want to move a camera from the player to the Big Boss, then back to the player. Positions of the sprites are not fixed, both the player and the Big Boss may be anywhere on the layout.

    (I know I can use MoveTo or other behaviors, I'm just curious if this can be done with Timelines)

    Tagged:

  • This is not possible, as there is no way of modifying a timeline at runtime.

  • Thanks, DiegoM !

    Is it possible to use relative values in key frames? Say, move the player sprite to (player.x+100, player.y+200)

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Yes, in fact, that is the default behaviour for position properties.

    When an X or Y property track (or one of it parents) is set to use default result mode or explicitly relative result mode and you click on a property keyframe the value you see in the properties bar is relative.

    So in a relative timeline it is common for the first keyframe to hold a value of 0 for they X and Y property tracks. 0 meaning, no changes from it's current place. The subsequent property keyframes will hold values relative to the initial one.

    But I don't think you need to worry about those details.

    To sum it up, if you play a timeline, the animation will be relative to the instance's current position, as long as you are using default or relative result mode.

  • Thanks for the detailed explanation! I still haven't had an opportunity to play with timelines. I'm making a game for a jam, so thought I should finally give it a try.

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