It was backwards when calling fastdwarf with just one argument. Also made it print the current status of fastdwarf when no arguments are given.

develop
expwnent 2012-09-28 16:36:37 -04:00
parent 76cd941084
commit 79ac1a81b9
1 changed files with 3 additions and 2 deletions

@ -72,10 +72,10 @@ static command_result fastdwarf (color_ostream &out, vector <string> & parameter
{ {
if (parameters.size() == 1) { if (parameters.size() == 1) {
if ( parameters[0] == "0" ) { if ( parameters[0] == "0" ) {
enable_fastdwarf = true; enable_fastdwarf = false;
enable_teledwarf = false; enable_teledwarf = false;
} else if ( parameters[0] == "1" ) { } else if ( parameters[0] == "1" ) {
enable_fastdwarf = false; enable_fastdwarf = true;
enable_teledwarf = false; enable_teledwarf = false;
} else { } else {
out.print("Incorrect usage.\n"); out.print("Incorrect usage.\n");
@ -100,6 +100,7 @@ static command_result fastdwarf (color_ostream &out, vector <string> & parameter
} }
} else if (parameters.size() == 0) { } else if (parameters.size() == 0) {
//print status //print status
out.print("Current state: fast = %d, teleport = %d.\n", enable_fastdwarf, enable_teledwarf);
} else { } else {
out.print("Incorrect usage.\n"); out.print("Incorrect usage.\n");
return CR_OK; return CR_OK;