#You mean like go back and furth along a

1 messages · Page 1 of 1 (latest)

merry kindle
#

yeah, the timeline-ing sounds right! Here's a clip of what seems typical in fighting games
Manually advancing frames might be okay, and maybe I can find a way to store the gamestate in a map, so as to walk back frames...

#

oh, interesting - you mentioned the word "timeline", and I found the "Timeline" Window in Unity, which has reference to gametime frames and such - I might be able to get what I want with this!

supple quail
#

I see, yeah the only way would be if you stored the state you needed per-frame. And wrote a custom editor to play it back. Or potentially write it to a AnimationClip and then you could play it in the Timeline

merry kindle
#

Yeah, I kept coming across the concept of "Animation" in Unity in my google searches, and I have the impression that the concept pertains purely to visual rendering (as opposed to game state)

supple quail
#

You can create animations for properties

#

So you can animate an object moving, or a light's intensity changing, or anything else with a numeric value

brisk nest
#

Fwiw, unity is not great at doing frame perfect things

supple quail
#

Yeah, that too ^

merry kindle
#

@brisk nest in what sense? In the sense that it's unwieldy to work on that kind of thing in the editor, or that the game engine doesn't do well with it?

brisk nest
#

It's hard to do things with the right frame timing

merry kindle
#

Hmm, from the programming side, it's honestly been fine! 🙂

brisk nest
#

Depends what you're building of course

dusky rivet
#

Using FixedUpdate should avoid any annoying stuff regarding frame-perfect stuff no?

#

like MechWarrior said you can indeed have things happen during certain parts of an animation.

supple quail
#

I mean yeah, but what I was talking about is being able to scrub back and forth through frames. Not events being triggered by animations.

merry kindle
#

Yeah, as it relates to game state, the memory space would blow up if I wanted to undo game interactions, or I would need to provide some sort of rollback code to undo game engine timesteps. For my usecase, though, Given a game object and a frame count, I can O(1) calculate the state of the object that I want, so I just need to find a way to pass some sort of game frame counter to the objects being handled in the editor