forked from ChomeNS/chomens-bot-java
limit the size because it crashes the bot
This commit is contained in:
parent
5a0483b139
commit
940c1760dc
1 changed files with 2 additions and 0 deletions
|
@ -48,6 +48,8 @@ public class GenerateMazeCommand implements Command {
|
|||
final int width = Integer.parseInt(args[3]);
|
||||
final int height = Integer.parseInt(args[4]);
|
||||
|
||||
if (width > 100 || height > 100) return Component.text("Size is too big").color(NamedTextColor.RED);
|
||||
|
||||
final MazeGenerator generator = new MazeGenerator(width, height);
|
||||
|
||||
generator.generateMaze();
|
||||
|
|
Loading…
Reference in a new issue