diff options
| author | Magnus Auvinen <magnus.auvinen@gmail.com> | 2007-09-09 18:21:14 +0000 |
|---|---|---|
| committer | Magnus Auvinen <magnus.auvinen@gmail.com> | 2007-09-09 18:21:14 +0000 |
| commit | 3f4587ede831760b2f6976960658d202c9d847ff (patch) | |
| tree | 6c3a22251906673e5e7491dcd86faec23887691b /src/engine/snapshot.c | |
| parent | 350e968f514a00d4a89395ed13e415103390b9d9 (diff) | |
| download | zcatch-3f4587ede831760b2f6976960658d202c9d847ff.tar.gz zcatch-3f4587ede831760b2f6976960658d202c9d847ff.zip | |
a lot of changes. client side prediction added
Diffstat (limited to 'src/engine/snapshot.c')
| -rw-r--r-- | src/engine/snapshot.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/engine/snapshot.c b/src/engine/snapshot.c index b9c832a2..b42b0157 100644 --- a/src/engine/snapshot.c +++ b/src/engine/snapshot.c @@ -21,7 +21,7 @@ int snapshot_get_item_datasize(SNAPSHOT *snap, int index) int snapshot_get_item_index(SNAPSHOT *snap, int key) { - /* TODO: this should not be a linear search. very bad */ + /* TODO: OPT: this should not be a linear search. very bad */ int i; for(i = 0; i < snap->num_items; i++) { @@ -135,6 +135,8 @@ static void undiff_item(int *past, int *diff, int *out, int size) } } + +// TODO: OPT: this should be made much faster int snapshot_create_delta(SNAPSHOT *from, SNAPSHOT *to, void *dstdata) { SNAPSHOT_DELTA *delta = (SNAPSHOT_DELTA *)dstdata; |