Fixed setting the difficulty via command

This commit is contained in:
Shoghi Cervantes 2013-06-17 03:29:44 +02:00
parent ce1e95195b
commit 5a168836c5

View File

@ -97,7 +97,7 @@ class ConsoleAPI{
break; break;
case "difficulty": case "difficulty":
$s = trim(array_shift($params)); $s = trim(array_shift($params));
if($s == "" or (((int) $s) !== 0 and ((int) $s) !== 1)){ if($s == "" or (((int) $s) <= 3 and ((int) $s) >= 0)){
$output .= "Usage: /difficulty <0|1|2|3>\n"; $output .= "Usage: /difficulty <0|1|2|3>\n";
break; break;
} }