mirror of
https://github.com/libretro/scummvm.git
synced 2025-02-23 04:33:09 +00:00
Some indentation and format changes. Mostly replacing spaces with tabs.
svn-id: r25654
This commit is contained in:
parent
9ab2ca5bc7
commit
f33da9e412
@ -673,7 +673,8 @@ void jobRunScripts(void *parm, Job *j) {
|
||||
a->_program->_ip = (Instruction*)inst->_node._next;
|
||||
|
||||
label1:
|
||||
if (a->_zone._flags & kFlagsCharacter) a->_z = a->_zone.pos._position._y + a->_cnv._height;
|
||||
if (a->_zone._flags & kFlagsCharacter)
|
||||
a->_z = a->_zone.pos._position._y + a->_cnv._height;
|
||||
}
|
||||
|
||||
sortAnimations();
|
||||
@ -685,8 +686,10 @@ label1:
|
||||
void wrapLocalVar(LocalVariable *local) {
|
||||
// printf("wrapLocalVar(v: %i, min: %i, max: %i)\n", local->_value, local->_min, local->_max);
|
||||
|
||||
if (local->_value >= local->_max) local->_value = local->_min;
|
||||
if (local->_value < local->_min) local->_value = local->_max - 1;
|
||||
if (local->_value >= local->_max)
|
||||
local->_value = local->_min;
|
||||
if (local->_value < local->_min)
|
||||
local->_value = local->_max - 1;
|
||||
|
||||
return;
|
||||
}
|
||||
|
@ -42,7 +42,8 @@ static uint32 _handle = MAX_ARCHIVE_ENTRIES;
|
||||
void openArchive(const char *file) {
|
||||
debugC(1, kDebugDisk, "open archive '%s'", file);
|
||||
|
||||
if (_archive.isOpen()) closeArchive();
|
||||
if (_archive.isOpen())
|
||||
closeArchive();
|
||||
|
||||
|
||||
uint32 offset = DIRECTORY_OFFSET_IN_FILE;
|
||||
@ -167,7 +168,8 @@ char *readArchivedFileText(char *buf, uint16 size, void*) {
|
||||
|
||||
char *t = _archive.readLine(buf, size);
|
||||
|
||||
if (_archive.eof() || t == NULL) return NULL;
|
||||
if (_archive.eof() || t == NULL)
|
||||
return NULL;
|
||||
|
||||
return t;
|
||||
}
|
||||
|
@ -47,7 +47,8 @@ void _c_play_boogie(void *parm) {
|
||||
|
||||
static uint16 flag = 1;
|
||||
|
||||
if (flag == 0) return;
|
||||
if (flag == 0)
|
||||
return;
|
||||
flag = 0;
|
||||
|
||||
stopMusic();
|
||||
@ -174,7 +175,8 @@ static uint16 num_foglie = 0;
|
||||
void _c_contaFoglie(void *parm) {
|
||||
|
||||
num_foglie++;
|
||||
if (num_foglie != 6) return;
|
||||
if (num_foglie != 6)
|
||||
return;
|
||||
|
||||
_commandFlags |= 0x1000;
|
||||
|
||||
@ -264,7 +266,8 @@ void _c_finito(void *parm) {
|
||||
Common::File stream;
|
||||
|
||||
stream.open(_vm->_characterName, Common::File::kFileWriteMode);
|
||||
if (stream.isOpen()) stream.close();
|
||||
if (stream.isOpen())
|
||||
stream.close();
|
||||
|
||||
Common::File streamDino, streamDough, streamDonna;
|
||||
|
||||
|
@ -366,8 +366,10 @@ void Graphics::flatBlit(uint16 w, uint16 h, int16 x, int16 y, byte *data, Graphi
|
||||
int16 left = 0, top = 0;
|
||||
int16 right = w, bottom = h;
|
||||
|
||||
if (x + w > SCREEN_WIDTH) right = SCREEN_WIDTH - x;
|
||||
if (y + h > SCREEN_HEIGHT) bottom = SCREEN_HEIGHT - y;
|
||||
if (x + w > SCREEN_WIDTH)
|
||||
right = SCREEN_WIDTH - x;
|
||||
if (y + h > SCREEN_HEIGHT)
|
||||
bottom = SCREEN_HEIGHT - y;
|
||||
|
||||
if (x < 0) { // partially left clipped
|
||||
left = -x;
|
||||
@ -467,7 +469,8 @@ void jobDisplayLabel(void *parm, Job *j) {
|
||||
ZoneLabel *label = (ZoneLabel*)parm;
|
||||
debugC(1, kDebugLocation, "jobDisplayLabel (%p)", (const void*) label);
|
||||
|
||||
if (label->_cnv._width == 0) return;
|
||||
if (label->_cnv._width == 0)
|
||||
return;
|
||||
_vm->_graphics->flatBlitCnv(&label->_cnv, Graphics::_labelPosition[0]._x, Graphics::_labelPosition[0]._y, Graphics::kBitBack, label->_cnv._data1);
|
||||
|
||||
return;
|
||||
@ -631,7 +634,8 @@ void Graphics::restoreCnvBackground(StaticCnv *cnv, int16 x, int16 y) {
|
||||
// strings
|
||||
//
|
||||
void Graphics::displayString(uint16 x, uint16 y, const char *text) {
|
||||
if (text == NULL) return;
|
||||
if (text == NULL)
|
||||
return;
|
||||
|
||||
uint16 len = strlen(text);
|
||||
StaticCnv tmp;
|
||||
|
@ -119,7 +119,8 @@ int16 pickupItem(Zone *z) {
|
||||
|
||||
uint16 _si;
|
||||
for (_si = 0; _inventory[_si]._id != 0; _si++) ;
|
||||
if (_si == INVENTORY_MAX_ITEMS) return -1;
|
||||
if (_si == INVENTORY_MAX_ITEMS)
|
||||
return -1;
|
||||
|
||||
_inventory[_si]._id = (z->u.get->_icon << 16) & 0xFFFF0000;
|
||||
_inventory[_si]._index = z->u.get->_icon;
|
||||
|
@ -748,7 +748,8 @@ void Parallaction::saveGame() {
|
||||
|
||||
// strcpy(v30, asc_1C91A);
|
||||
|
||||
if (!scumm_stricmp(_location, "caveau")) return;
|
||||
if (!scumm_stricmp(_location, "caveau"))
|
||||
return;
|
||||
|
||||
int slot = selectSaveFile( 1, "Save file", "Save" );
|
||||
if (slot == -1) {
|
||||
|
@ -193,7 +193,8 @@ void Menu::newGame() {
|
||||
if (_mouseButtons == kMouseRightUp) break;
|
||||
}
|
||||
|
||||
if (_mouseButtons != kMouseRightUp) return; // show intro
|
||||
if (_mouseButtons != kMouseRightUp)
|
||||
return; // show intro
|
||||
|
||||
_vm->_graphics->freeCnv(&Graphics::_font);
|
||||
closeArchive();
|
||||
|
@ -967,7 +967,8 @@ void runJobs() {
|
||||
(*j->_fn)(j->_parm, j);
|
||||
Job *v4 = (Job*)j->_node._next;
|
||||
|
||||
if (j->_finished == 1) removeJob(j);
|
||||
if (j->_finished == 1)
|
||||
removeJob(j);
|
||||
|
||||
j = v4;
|
||||
}
|
||||
|
@ -69,7 +69,8 @@ char *parseComment(ArchivedFile *file) {
|
||||
v194 = parseNextLine(v190, 400);
|
||||
|
||||
v194[strlen(v194)-1] = '\0';
|
||||
if (!scumm_stricmp(v194, "endtext")) break;
|
||||
if (!scumm_stricmp(v194, "endtext"))
|
||||
break;
|
||||
|
||||
strcat(_tmp_comment, v194);
|
||||
strcat(_tmp_comment, " ");
|
||||
|
@ -352,8 +352,10 @@ void jobWalk(void *parm, Job *j) {
|
||||
node->_y - _yourself._zone.pos._position._y
|
||||
};
|
||||
|
||||
if (dist._x < 0) dist._x = -dist._x;
|
||||
if (dist._y < 0) dist._y = -dist._y;
|
||||
if (dist._x < 0)
|
||||
dist._x = -dist._x;
|
||||
if (dist._y < 0)
|
||||
dist._y = -dist._y;
|
||||
|
||||
walkData1++;
|
||||
|
||||
|
@ -637,25 +637,36 @@ Zone *hitZone(uint32 type, uint16 x, uint16 y) {
|
||||
(((z->_type & 0xFFFF0000) == kZoneGet) && ((_si == z->u.get->_icon) || (_di == z->u.get->_icon)))) {
|
||||
|
||||
// special Zone
|
||||
if ((type == 0) && ((z->_type & 0xFFFF0000) == 0)) return z;
|
||||
if (z->_type == type) return z;
|
||||
if ((z->_type & 0xFFFF0000) == type) return z;
|
||||
if ((type == 0) && ((z->_type & 0xFFFF0000) == 0))
|
||||
return z;
|
||||
if (z->_type == type)
|
||||
return z;
|
||||
if ((z->_type & 0xFFFF0000) == type)
|
||||
return z;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
if (z->_limits._left != -1) continue;
|
||||
if (_si < _yourself._zone.pos._position._x) continue;
|
||||
if (_si > (_yourself._zone.pos._position._x + _yourself._cnv._width)) continue;
|
||||
if (_di < _yourself._zone.pos._position._y) continue;
|
||||
if (_di > (_yourself._zone.pos._position._y + _yourself._cnv._height)) continue;
|
||||
if (z->_limits._left != -1)
|
||||
continue;
|
||||
if (_si < _yourself._zone.pos._position._x)
|
||||
continue;
|
||||
if (_si > (_yourself._zone.pos._position._x + _yourself._cnv._width))
|
||||
continue;
|
||||
if (_di < _yourself._zone.pos._position._y)
|
||||
continue;
|
||||
if (_di > (_yourself._zone.pos._position._y + _yourself._cnv._height))
|
||||
continue;
|
||||
|
||||
}
|
||||
|
||||
// normal Zone
|
||||
if ((type == 0) && ((z->_type & 0xFFFF0000) == 0)) return z;
|
||||
if (z->_type == type) return z;
|
||||
if ((z->_type & 0xFFFF0000) == type) return z;
|
||||
if ((type == 0) && ((z->_type & 0xFFFF0000) == 0))
|
||||
return z;
|
||||
if (z->_type == type)
|
||||
return z;
|
||||
if ((z->_type & 0xFFFF0000) == type)
|
||||
return z;
|
||||
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user