diff options
| author | Max Horn | 2005-03-15 21:48:06 +0000 | 
|---|---|---|
| committer | Max Horn | 2005-03-15 21:48:06 +0000 | 
| commit | 6e33b3f0a7b80a5d84c277bed05ee376b4ebb517 (patch) | |
| tree | f60fb92ebe795c540b443474594d0b9de6fb89c6 /scumm/costume.cpp | |
| parent | deca1352524cfc4ba32fedf85b9863f119f70063 (diff) | |
| download | scummvm-rg350-6e33b3f0a7b80a5d84c277bed05ee376b4ebb517.tar.gz scummvm-rg350-6e33b3f0a7b80a5d84c277bed05ee376b4ebb517.tar.bz2 scummvm-rg350-6e33b3f0a7b80a5d84c277bed05ee376b4ebb517.zip  | |
Some cleanup/costume code unification. Note: NES costume code probably should be using subclasses; and maybe we should add AKOSLoadedCostume and NESLoadedCostume ?
svn-id: r17161
Diffstat (limited to 'scumm/costume.cpp')
| -rw-r--r-- | scumm/costume.cpp | 10 | 
1 files changed, 3 insertions, 7 deletions
diff --git a/scumm/costume.cpp b/scumm/costume.cpp index 36b5bd9866..27c5a4ce5b 100644 --- a/scumm/costume.cpp +++ b/scumm/costume.cpp @@ -808,7 +808,7 @@ byte CostumeRenderer::drawLimb(const Actor *a, int limb) {  } -extern void DecodeNESTileData(const byte *src, byte *dest); +extern void decodeNESTileData(const byte *src, byte *dest);  void ScummEngine::cost_decodeNESCostumeGfx() {  	for (int n = 0; n < 2; n++) { @@ -817,16 +817,12 @@ void ScummEngine::cost_decodeNESCostumeGfx() {  		if (maxSprites == 0)  			maxSprites = 256;  		_v1MMNESCostumeGfx[n] = (byte *)calloc(maxSprites * 16, 1); -		DecodeNESTileData(patTable,_v1MMNESCostumeGfx[n]); +		decodeNESTileData(patTable,_v1MMNESCostumeGfx[n]);  		// We will not need it anymore  		nukeResource(rtCostume, v1MMNEScostTables[n][4]);  	}  } -int ScummEngine::cost_frameToAnim(Actor *a, int frame) { -	return newDirToOldDir(a->getFacing()) + frame * 4; -} -  void ScummEngine::cost_decodeData(Actor *a, int frame, uint usemask) {  	const byte *r;  	uint mask, j; @@ -837,7 +833,7 @@ void ScummEngine::cost_decodeData(Actor *a, int frame, uint usemask) {  	lc.loadCostume(a->_costume); -	anim = cost_frameToAnim(a, frame); +	anim = newDirToOldDir(a->getFacing()) + frame * 4;  	if (anim > lc._numAnim) {  		return;  | 
