aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul Gilbert2019-08-17 19:27:31 -0700
committerPaul Gilbert2019-08-18 15:18:57 -0700
commit1f38a8239f5fb5b6c9a89b299cd9de1694176df6 (patch)
tree82335cede0c71897cfebacf06ad83745ad73c6b7
parent34f842e4b828b1aaf0149a67bf1ad3bc04c26b09 (diff)
downloadscummvm-rg350-1f38a8239f5fb5b6c9a89b299cd9de1694176df6.tar.gz
scummvm-rg350-1f38a8239f5fb5b6c9a89b299cd9de1694176df6.tar.bz2
scummvm-rg350-1f38a8239f5fb5b6c9a89b299cd9de1694176df6.zip
GLK: FROTZ: Whitespace fixes
-rw-r--r--engines/glk/frotz/processor_screen.cpp30
-rw-r--r--engines/glk/frotz/processor_streams.cpp46
-rw-r--r--engines/glk/frotz/processor_text.cpp4
3 files changed, 46 insertions, 34 deletions
diff --git a/engines/glk/frotz/processor_screen.cpp b/engines/glk/frotz/processor_screen.cpp
index 0d6023ef52..1dcd78afa8 100644
--- a/engines/glk/frotz/processor_screen.cpp
+++ b/engines/glk/frotz/processor_screen.cpp
@@ -451,8 +451,8 @@ void Processor::z_show_status() {
brief = true;
// Print the object description for the global variable 0
- print_char (' ');
- print_object (global0);
+ print_char(' ');
+ print_object(global0);
// A header flag tells us whether we have to display the current
// time or the score/moves information
@@ -462,34 +462,34 @@ void Processor::z_show_status() {
pad_status_line (brief ? 15 : 20);
- print_string ("Time: ");
+ print_string("Time: ");
if (hours < 10)
- print_char (' ');
- print_num (hours);
+ print_char(' ');
+ print_num(hours);
- print_char (':');
+ print_char(':');
if (global2 < 10)
- print_char ('0');
- print_num (global2);
+ print_char('0');
+ print_num(global2);
- print_char (' ');
+ print_char(' ');
- print_char ((global1 >= 12) ? 'p' : 'a');
- print_char ('m');
+ print_char((global1 >= 12) ? 'p' : 'a');
+ print_char('m');
} else {
// print score and moves
pad_status_line (brief ? 15 : 30);
- print_string (brief ? "S: " : "Score: ");
- print_num (global1);
+ print_string(brief ? "S: " : "Score: ");
+ print_num(global1);
pad_status_line (brief ? 8 : 14);
- print_string (brief ? "M: " : "Moves: ");
- print_num (global2);
+ print_string(brief ? "M: " : "Moves: ");
+ print_num(global2);
}
// Pad the end of the status line with spaces
diff --git a/engines/glk/frotz/processor_streams.cpp b/engines/glk/frotz/processor_streams.cpp
index 68099985f2..3b414afae8 100644
--- a/engines/glk/frotz/processor_streams.cpp
+++ b/engines/glk/frotz/processor_streams.cpp
@@ -155,7 +155,7 @@ continue_input:
// Handle timeouts
if (key == ZC_TIME_OUT)
- if (direct_call (routine) == 0)
+ if (direct_call(routine) == 0)
goto continue_input;
// Return key
@@ -490,22 +490,34 @@ void Processor::z_output_stream() {
flush_buffer();
switch ((short) zargs[0]) {
- case 1: ostream_screen = true;
- break;
- case -1: ostream_screen = false;
- break;
- case 2: if (!ostream_script) script_open();
- break;
- case -2: if (ostream_script) script_close();
- break;
- case 3: memory_open(zargs[1], zargs[2], zargc >= 3);
- break;
- case -3: memory_close();
- break;
- case 4: if (!ostream_record) record_open();
- break;
- case -4: if (ostream_record) record_close();
- break;
+ case 1:
+ ostream_screen = true;
+ break;
+ case -1:
+ ostream_screen = false;
+ break;
+ case 2:
+ if (!ostream_script)
+ script_open();
+ break;
+ case -2:
+ if (ostream_script)
+ script_close();
+ break;
+ case 3:
+ memory_open(zargs[1], zargs[2], zargc >= 3);
+ break;
+ case -3:
+ memory_close();
+ break;
+ case 4:
+ if (!ostream_record)
+ record_open();
+ break;
+ case -4:
+ if (ostream_record)
+ record_close();
+ break;
default:
break;
}
diff --git a/engines/glk/frotz/processor_text.cpp b/engines/glk/frotz/processor_text.cpp
index 97957aca59..22dc8851e3 100644
--- a/engines/glk/frotz/processor_text.cpp
+++ b/engines/glk/frotz/processor_text.cpp
@@ -253,7 +253,7 @@ void Processor::encode_text(int padding) {
// Search character in the alphabet
for (set = 0; set < 3; set++)
for (index = 0; index < 26; index++)
- if (c == alphabet (set, index))
+ if (c == alphabet(set, index))
goto letter_found;
// Character not found, store its ZSCII value
@@ -871,7 +871,7 @@ void Processor::z_print_form() {
}
void Processor::z_print_num() {
- print_num (zargs[0]);
+ print_num(zargs[0]);
}
void Processor::z_print_obj() {