Re: [Alephmodular-devel] A note on films
Status: Pre-Alpha
Brought to you by:
brefin
From: Woody Z. I. <woo...@sb...> - 2003-01-18 18:41:21
|
Might I suggest that it may be more practical to have a facility for dumping and another for comparing against an existing "checkfile", so that the game can automatically detect and warn you about inconsistencies? To help ensure the checkfile's integrity, the game would probably generate a checkfile with a name based on the film file's name, and it would refuse to create a new checkfile - which is something you'd have to explicitly ask it to do anyway - if one already exists. On playback it could automatically detect the presence of the checkfile and use it if it's there. You could even alter get_heartbeat_count() to always return a really high value when you're in 'checking vs. checkfile' mode so that the engine effectively only does the state updates and doesn't waste time rendering and waiting for the next tick-time etc. Or maybe that's pretty unnecessary since you can just crank up the replay speed manually. :) Something like simply dumping out the get_random_seed() each tick (and comparing to that dumped value when playing back) would go a long way toward detecting inconsistencies. It's a very tiny piece of state that is very likely to get messed up if things go awry (since changes in other parts of the state will likely result in different numbers of calls to global_random(), at least at some point). This is effectively how I found the A1 out-of-sync problem... though, my code actually only dumped, and I had to manually shuffle files around to produce multiple copies, and run command-line diff on them. (Since I knew I was going to be 'diff'ing, I dumped a textual representation out, one tick per line - more choices that would likely be incorrect for an automated dump-n-check scheme.) Random thought: A1 films seem to stop after the last recording "chunk" is put into the action_queues, rather than once the machine gets a chance to read and render the results - so the end of the film is sort of clipped off. I think. Does M2 (and thus AM) exhibit this behavior as well? Woody On Saturday, January 18, 2003, at 12:12 PM, Aaron Davies wrote: > I believe there's already a prog for doing film->mov conversion; > perhaps you could just run them through that to get a canonical version > you can compare them to. |