mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-20 11:39:43 +00:00
Adventure Mode
This commit is contained in:
parent
eaa3006d51
commit
d24d826ffd
5 changed files with 32 additions and 14 deletions
|
|
@ -90,12 +90,12 @@ class ConsoleAPI{
|
|||
break;
|
||||
case "gamemode":
|
||||
$s = trim(array_shift($params));
|
||||
if($s == "" or (((int) $s) !== 0 and ((int) $s) !== 1)){
|
||||
console("[INFO] Usage: /gamemode <0 | 1>");
|
||||
if($s == "" or (((int) $s) !== 0 and ((int) $s) !== 1 and ((int) $s) !== 2)){
|
||||
console("[INFO] Usage: /gamemode <0 | 1 | 2>");
|
||||
break;
|
||||
}
|
||||
$this->server->api->setProperty("gamemode", (int) $s);
|
||||
console("[INFO] Gamemode changed to ".$this->server->gamemode);
|
||||
console("[INFO] Gamemode changed to ".$this->server->getGamemode());
|
||||
break;
|
||||
case "difficulty":
|
||||
$s = trim(array_shift($params));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue