SCI: Renamed global array 'formats' to the slightly more descriptive g_opcode_formats

svn-id: r40031
This commit is contained in:
Max Horn 2009-04-20 19:28:33 +00:00
parent d567482818
commit 5325f9b76e
4 changed files with 10 additions and 10 deletions

View File

@ -33,7 +33,7 @@ namespace Sci {
#define END Script_None
opcode_format formats[128][4] = {
opcode_format g_opcode_formats[128][4] = {
/*00*/
{Script_None}, {Script_None}, {Script_None}, {Script_None},
/*04*/
@ -99,8 +99,8 @@ void script_adjust_opcode_formats(int res_version) {
case SCI_VERSION_1_EARLY:
case SCI_VERSION_1_LATE:
case SCI_VERSION_1_1:
formats[op_lofsa][0] = Script_Offset;
formats[op_lofss][0] = Script_Offset;
g_opcode_formats[op_lofsa][0] = Script_Offset;
g_opcode_formats[op_lofss][0] = Script_Offset;
break;
default:
sciprintf("script_adjust_opcode_formats(): Unknown script version %d\n", res_version);

View File

@ -209,7 +209,7 @@ enum sci_opcodes { /* FIXME */
op_minusspi
};
extern opcode_format formats[128][4];
extern opcode_format g_opcode_formats[128][4];
void script_adjust_opcode_formats(int res_version);

View File

@ -1262,8 +1262,8 @@ reg_t disassemble(EngineState *s, reg_t pos, int print_bw_tag, int print_bytecod
sciprintf(PREG": ", PRINT_REG(pos));
if (print_bytecode) {
while (formats[opcode][i]) {
switch (formats[opcode][i++]) {
while (g_opcode_formats[opcode][i]) {
switch (g_opcode_formats[opcode][i++]) {
case Script_SByte:
case Script_Byte:
@ -1311,8 +1311,8 @@ reg_t disassemble(EngineState *s, reg_t pos, int print_bw_tag, int print_bytecod
sciprintf("%s", s->opcodes[opcode].name);
i = 0;
while (formats[opcode][i]) {
switch (formats[opcode][i++]) {
while (g_opcode_formats[opcode][i]) {
switch (g_opcode_formats[opcode][i++]) {
case Script_Invalid:
sciprintf("-Invalid operation-");
break;

View File

@ -737,8 +737,8 @@ void run_vm(EngineState *s, int restoring) {
opnumber = opcode >> 1;
for (temp = 0; formats[opnumber][temp]; temp++)
switch (formats[opnumber][temp]) {
for (temp = 0; g_opcode_formats[opnumber][temp]; temp++)
switch (g_opcode_formats[opnumber][temp]) {
case Script_Byte:
opparams[temp] = GET_OP_BYTE();