From: Speed D. <no...@so...> - 2013-10-26 17:26:44
|
#692: Replay, Ghost Cars and Flashback -------------------------+-------------------------------------------------- Reporter: mungewell | Owner: somebody Type: enhancement | Status: new Priority: major | Milestone: to be defined Component: Whole game | Version: 2.0.0 Keywords: | -------------------------+-------------------------------------------------- Comment(by mungewell): Found the problem with replay sometime failing to start, it seems that the database file was being 'blocked' in that that 'EXCLUSIVE' pragma was not being clear. {{{ Default Info Replay: Database Opened 0x808909620 Default Info Replay: Playback from file Default Info Replay: Unable to create table car0: database is locked Default Info Replay: Unable to create index car0: database is locked Default Info Replay SimInit Default Info Unable to prepare car0: database is locked }}} {{{ sqlite3_exec(replayDB, "PRAGMA synchronous = OFF", NULL, NULL, NULL); sqlite3_exec(replayDB, "PRAGMA journal_mode = OFF", NULL, NULL, NULL); sqlite3_exec(replayDB, "PRAGMA count_changes = OFF", NULL, NULL, NULL); #if 0 sqlite3_exec(replayDB, "PRAGMA locking_mode = EXCLUSIVE", NULL, NULL, NULL); #endif sqlite3_exec(replayDB, "PRAGMA default_temp_store = MEMORY", NULL, NULL, NULL); }}} Attached patch (8th) fixes this and allows all races to be replayed after they have finished. During replay the '+' and '-' buttons can reverse time. I've not implemented clear the data base at the start of race as it aids testing to be able to manually set SIMU_REPLAY, so file ('/tmp/race.sqlite') may need to be deleted by hand before each real race. Apart from fixing visual glitches I think that the next stage it to provide a mechanism to allow long term storage of replay - ie. clean up/minimise database and wrap up all config files into one zip/tar file so they can be replayed anytime (after the race configs have been change). -- Ticket URL: <http://sourceforge.net/apps/trac/speed-dreams/ticket/692#comment:33> Speed Dreams <http://sourceforge.net/projects/speed-dreams> An Open Motor-sport Simulator featuring high-quality 3D graphics and an accurate physics engine, all targeting maximum realism as well as exciting new features, cars, tracks and AI opponents to make a more enjoyable game for the player. |