[Scummvm-cvs-logs] CVS: scummvm/scumm script_v6.cpp,1.365,1.366
Max Horn
fingolfin at users.sourceforge.net
Sat Jul 31 19:04:03 CEST 2004
- Previous message: [Scummvm-cvs-logs] CVS: scummvm/saga actionmap.cpp,1.11,1.12 actor.cpp,1.13,1.14 animation.cpp,1.11,1.12 console.cpp,1.6,1.7 cvar.cpp,1.7,1.8 events.cpp,1.13,1.14 expr.cpp,1.4,1.5 font.cpp,1.9,1.10 game.cpp,1.15,1.16 gfx.cpp,1.20,1.21 gfx_mod.h,1.6,1.7 ihnm_introproc.cpp,1.8,1.9 image.cpp,1.11,1.12 input.cpp,1.4,1.5 interface.cpp,1.10,1.11 isomap.cpp,1.7,1.8 ite_introproc.cpp,1.11,1.12 music.cpp,1.19,1.20 objectmap.cpp,1.10,1.11 palanim.cpp,1.8,1.9 palanim.h,1.4,1.5 render.cpp,1.16,1.17 rscfile.cpp,1.5,1.6 saga.cpp,1.26,1.27 saga.h,1.18,1.19 scene.cpp,1.15,1.16 sceneproc.cpp,1.10,1.11 script.cpp,1.9,1.10 sdata.cpp,1.6,1.7 sdebug.cpp,1.4,1.5 sfuncs.cpp,1.6,1.7 sndres.cpp,1.16,1.17 sound.cpp,1.8,1.9 sprite.cpp,1.9,1.10 sstack.cpp,1.3,1.4 sthread.cpp,1.9,1.10 text.cpp,1.2,1.3 timer.cpp,1.3,1.4 transitions.cpp,1.5,1.6 ys_dl_list.cpp,1.3,1.4 reinherit.h,1.22,NONE
- Next message: [Scummvm-cvs-logs] CVS: scummvm/scumm script_v6he.cpp,2.80,2.81
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /cvsroot/scummvm/scummvm/scumm
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv534
Modified Files:
script_v6.cpp
Log Message:
More array code cleanup
Index: script_v6.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/script_v6.cpp,v
retrieving revision 1.365
retrieving revision 1.366
diff -u -d -r1.365 -r1.366
--- script_v6.cpp 1 Aug 2004 01:54:36 -0000 1.365
+++ script_v6.cpp 1 Aug 2004 02:03:07 -0000 1.366
@@ -407,18 +407,17 @@
if (_heversion >= 60) {
- // FIXME: Fingolfin asks: What is this change good for? It doesn't hurt,
- // but it also has no effect whatsoever...
- if (type == 1 || type == 2)
- type = 3;
+ if (type == kBitArray || type == kNibbleArray)
+ type = kByteArray;
} else {
- // The following code basically turn all arrays except string arrays
- // into integer arrays. There seems to be no purpose in this, and it
- // wastes space. However, we can't just change this either, as that
- // would break savegame compatibility. So do not touch this unless you
- // are adding code which updated old savegames, too.
- if (type != 4)
- type = 5;
+ // NOTE: The following code turns all arrays except string arrays into
+ // integer arrays. There seems to be no reason for this, and it wastes
+ // space. However, we can't just remove this either, as that would
+ // break savegame compatibility. So do not touch this unless you are
+ // also adding code which updated old savegames, too. And of course
+ // readArray() and writeArray() would have to be updated, too...
+ if (type != kStringArray)
+ type = kIntArray;
}
nukeArray(array);
@@ -514,7 +513,7 @@
array, base, idx, FROM_LE_16(ah->dim1), FROM_LE_16(ah->dim2));
}
- if (FROM_LE_16(ah->type) == 4 || (_heversion >= 60 && FROM_LE_16(ah->type) == rtCostume)) {
+ if (FROM_LE_16(ah->type) != kIntArray) {
return ah->data[offset];
} else if (_version == 8) {
return (int32)READ_LE_UINT32(ah->data + offset * 4);
@@ -535,7 +534,7 @@
array, base, idx, FROM_LE_16(ah->dim1), FROM_LE_16(ah->dim2));
}
- if (FROM_LE_16(ah->type) == rtSound || (_heversion >= 60 && FROM_LE_16(ah->type) == rtCostume)) {
+ if (FROM_LE_16(ah->type) != kIntArray) {
ah->data[offset] = value;
} else if (_version == 8) {
WRITE_LE_UINT32(ah->data + offset * 4, value);
- Previous message: [Scummvm-cvs-logs] CVS: scummvm/saga actionmap.cpp,1.11,1.12 actor.cpp,1.13,1.14 animation.cpp,1.11,1.12 console.cpp,1.6,1.7 cvar.cpp,1.7,1.8 events.cpp,1.13,1.14 expr.cpp,1.4,1.5 font.cpp,1.9,1.10 game.cpp,1.15,1.16 gfx.cpp,1.20,1.21 gfx_mod.h,1.6,1.7 ihnm_introproc.cpp,1.8,1.9 image.cpp,1.11,1.12 input.cpp,1.4,1.5 interface.cpp,1.10,1.11 isomap.cpp,1.7,1.8 ite_introproc.cpp,1.11,1.12 music.cpp,1.19,1.20 objectmap.cpp,1.10,1.11 palanim.cpp,1.8,1.9 palanim.h,1.4,1.5 render.cpp,1.16,1.17 rscfile.cpp,1.5,1.6 saga.cpp,1.26,1.27 saga.h,1.18,1.19 scene.cpp,1.15,1.16 sceneproc.cpp,1.10,1.11 script.cpp,1.9,1.10 sdata.cpp,1.6,1.7 sdebug.cpp,1.4,1.5 sfuncs.cpp,1.6,1.7 sndres.cpp,1.16,1.17 sound.cpp,1.8,1.9 sprite.cpp,1.9,1.10 sstack.cpp,1.3,1.4 sthread.cpp,1.9,1.10 text.cpp,1.2,1.3 timer.cpp,1.3,1.4 transitions.cpp,1.5,1.6 ys_dl_list.cpp,1.3,1.4 reinherit.h,1.22,NONE
- Next message: [Scummvm-cvs-logs] CVS: scummvm/scumm script_v6he.cpp,2.80,2.81
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the Scummvm-git-logs
mailing list