Moved out akos_compare (no reason for it to be member of class Scumm)
svn-id: r8660
This commit is contained in:
parent
eec095a72d
commit
1ec54d032e
2 changed files with 17 additions and 18 deletions
|
@ -95,6 +95,23 @@ enum AkosOpcodes {
|
||||||
AKC_EndSeq = 0xC0FF
|
AKC_EndSeq = 0xC0FF
|
||||||
};
|
};
|
||||||
|
|
||||||
|
static bool akos_compare(int a, int b, byte cmd) {
|
||||||
|
switch (cmd) {
|
||||||
|
case 0:
|
||||||
|
return a == b;
|
||||||
|
case 1:
|
||||||
|
return a != b;
|
||||||
|
case 2:
|
||||||
|
return a < b;
|
||||||
|
case 3:
|
||||||
|
return a <= b;
|
||||||
|
case 4:
|
||||||
|
return a > b;
|
||||||
|
default:
|
||||||
|
return a >= b;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
bool Scumm::akos_hasManyDirections(Actor *a) {
|
bool Scumm::akos_hasManyDirections(Actor *a) {
|
||||||
byte *akos;
|
byte *akos;
|
||||||
const AkosHeader *akhd;
|
const AkosHeader *akhd;
|
||||||
|
@ -1348,23 +1365,6 @@ void Scumm::akos_queCommand(byte cmd, Actor *a, int param_1, int param_2) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
bool Scumm::akos_compare(int a, int b, byte cmd) {
|
|
||||||
switch (cmd) {
|
|
||||||
case 0:
|
|
||||||
return a == b;
|
|
||||||
case 1:
|
|
||||||
return a != b;
|
|
||||||
case 2:
|
|
||||||
return a < b;
|
|
||||||
case 3:
|
|
||||||
return a <= b;
|
|
||||||
case 4:
|
|
||||||
return a > b;
|
|
||||||
default:
|
|
||||||
return a >= b;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
#ifdef __PALM_OS__
|
#ifdef __PALM_OS__
|
||||||
#include "scumm_globals.h" // init globals
|
#include "scumm_globals.h" // init globals
|
||||||
void Akos_initGlobals() {
|
void Akos_initGlobals() {
|
||||||
|
|
|
@ -797,7 +797,6 @@ public:
|
||||||
bool akos_increaseAnims(const byte *akos, Actor *a);
|
bool akos_increaseAnims(const byte *akos, Actor *a);
|
||||||
bool akos_increaseAnim(Actor *a, int i, const byte *aksq, const uint16 *akfo, int numakfo);
|
bool akos_increaseAnim(Actor *a, int i, const byte *aksq, const uint16 *akfo, int numakfo);
|
||||||
void akos_queCommand(byte cmd, Actor *a, int param_1, int param_2);
|
void akos_queCommand(byte cmd, Actor *a, int param_1, int param_2);
|
||||||
bool akos_compare(int a, int b, byte cmd);
|
|
||||||
void akos_decodeData(Actor *a, int frame, uint usemask);
|
void akos_decodeData(Actor *a, int frame, uint usemask);
|
||||||
int akos_frameToAnim(Actor *a, int frame);
|
int akos_frameToAnim(Actor *a, int frame);
|
||||||
bool akos_hasManyDirections(Actor *a);
|
bool akos_hasManyDirections(Actor *a);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue