[Scummvm-cvs-logs] CVS: scummvm/scumm costume.cpp,1.183,1.184 costume.h,1.35,1.36 scumm.cpp,1.525,1.526
Eugene Sandulenko
sev at users.sourceforge.net
Fri May 20 20:31:54 CEST 2005
Update of /cvsroot/scummvm/scummvm/scumm
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31725
Modified Files:
costume.cpp costume.h scumm.cpp
Log Message:
Stubs for C64 MM costume code. Content will follow. Fixes crash in intro
script
Index: costume.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/costume.cpp,v
retrieving revision 1.183
retrieving revision 1.184
diff -u -d -r1.183 -r1.184
--- costume.cpp 18 May 2005 23:17:04 -0000 1.183
+++ costume.cpp 21 May 2005 03:30:22 -0000 1.184
@@ -1003,6 +1003,30 @@
return (a->_cost.curpos[slot] != oldframe);
}
+byte C64CostumeRenderer::drawLimb(const Actor *a, int limb) {
+ return 0;
+}
+
+void C64CostumeRenderer::setCostume(int costume) {
+ _loaded.loadCostume(costume);
+}
+
+void C64CostumeLoader::loadCostume(int id) {
+ _id = id;
+ _baseptr = _vm->getResourceAddress(rtCostume, id);
+}
+
+void C64CostumeLoader::costumeDecodeData(Actor *a, int frame, uint usemask) {
+}
+
+byte C64CostumeLoader::increaseAnims(Actor *a) {
+ return 0;
+}
+
+byte C64CostumeLoader::increaseAnim(Actor *a, int slot) {
+ return 0;
+}
+
} // End of namespace Scumm
Index: costume.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/costume.h,v
retrieving revision 1.35
retrieving revision 1.36
diff -u -d -r1.35 -r1.36
--- costume.h 27 Mar 2005 00:42:53 -0000 1.35
+++ costume.h 21 May 2005 03:30:23 -0000 1.36
@@ -67,6 +67,22 @@
byte increaseAnim(Actor *a, int slot);
};
+class C64CostumeLoader : public BaseCostumeLoader {
+public:
+ int _id;
+ const byte *_baseptr;
+ const byte *_dataOffsets;
+ byte _numAnim;
+
+ C64CostumeLoader(ScummEngine *vm) : BaseCostumeLoader(vm) {}
+ void loadCostume(int id);
+ void costumeDecodeData(Actor *a, int frame, uint usemask);
+ byte increaseAnims(Actor *a);
+
+protected:
+ byte increaseAnim(Actor *a, int slot);
+};
+
class ClassicCostumeRenderer : public BaseCostumeRenderer {
protected:
ClassicCostumeLoader _loaded;
@@ -108,6 +124,21 @@
byte drawLimb(const Actor *a, int limb);
};
+class C64CostumeRenderer : public BaseCostumeRenderer {
+protected:
+ C64CostumeLoader _loaded;
+
+public:
+ C64CostumeRenderer(ScummEngine *vm) : BaseCostumeRenderer(vm), _loaded(vm) {}
+
+ void setPalette(byte *palette) {}
+ void setFacing(const Actor *a) {}
+ void setCostume(int costume);
+
+protected:
+ byte drawLimb(const Actor *a, int limb);
+};
+
} // End of namespace Scumm
#endif
Index: scumm.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/scumm.cpp,v
retrieving revision 1.525
retrieving revision 1.526
diff -u -d -r1.525 -r1.526
--- scumm.cpp 21 May 2005 00:27:41 -0000 1.525
+++ scumm.cpp 21 May 2005 03:30:23 -0000 1.526
@@ -1462,6 +1462,9 @@
if (_features & GF_NEW_COSTUMES) {
_costumeRenderer = new AkosRenderer(this);
_costumeLoader = new AkosCostumeLoader(this);
+ } else if (_platform == Common::kPlatformC64) {
+ _costumeRenderer = new C64CostumeRenderer(this);
+ _costumeLoader = new C64CostumeLoader(this);
} else if (_platform == Common::kPlatformNES) {
_costumeRenderer = new NESCostumeRenderer(this);
_costumeLoader = new NESCostumeLoader(this);
More information about the Scummvm-git-logs
mailing list