• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!
  • Hello [name]! Thanks for joining the GMC. Before making any posts in the Tech Support forum, can we suggest you read the forum rules? These are simple guidelines that we ask you to follow so that you can get the best help possible for your issue.

Question - Code timelines - get active moments?

babyjeans

Member
I've been messing with using timelines, and while it's not a requirement I've run into quite yet, I noticed there seems to be a lack of a "get_active_moment(timeline_index, moment_index)" since we do have timeline_size. I imagine it'd return a 'position' value for the active moment specified.

Are there plans for something like that?

For example, you might want to "timeout' timelines and force the position to the next 'active' moment position.
 

babyjeans

Member
I meant active moments in the sense that the manual defines them: "an "active" moment is one which has code or DnD™ added to it"
timeline_size apparently returns the count of those, but we have no 'index' to correlate to those, just how many there are.

I do suppose you can manually manage this for most cases (maintain a list of step # to active moment #), but you could avoid hard-coding and allow more dynamic situations if you don't need to know what specific step the moments are at.
 

babyjeans

Member
In addition to this, it'd be nice to be able to force a timeline to rerun its current position as well... like ev_perform(step) but for timelines? timeline_perform(position) or timeline_perform() using timeline_position... or at least allow you to remain on the same position from within a timeline:

if (conditionNotMet) timeline_dontincrementposition();
 
Top