neural networks fully set up for velocity
This commit is contained in:
@@ -5,6 +5,8 @@ import com.jonahseguin.drink.annotation.OptArg;
|
||||
import com.jonahseguin.drink.annotation.Sender;
|
||||
import net.nuggetmc.ai.TerminatorPlus;
|
||||
import net.nuggetmc.ai.bot.BotManager;
|
||||
import net.nuggetmc.ai.bot.agent.Agent;
|
||||
import net.nuggetmc.ai.bot.agent.legacyagent.ai.NetworkType;
|
||||
import net.nuggetmc.ai.command.CommandHandler;
|
||||
import net.nuggetmc.ai.command.CommandInstance;
|
||||
import org.bukkit.command.CommandSender;
|
||||
@@ -13,11 +15,13 @@ import org.bukkit.entity.Player;
|
||||
public class AICommand extends CommandInstance {
|
||||
|
||||
private final BotManager manager;
|
||||
private final Agent agent;
|
||||
|
||||
public AICommand(CommandHandler commandHandler) {
|
||||
super(commandHandler);
|
||||
|
||||
this.manager = TerminatorPlus.getInstance().getManager();
|
||||
this.agent = manager.getAgent();
|
||||
}
|
||||
|
||||
@Command(
|
||||
@@ -30,9 +34,9 @@ public class AICommand extends CommandInstance {
|
||||
@Command(
|
||||
name = "random",
|
||||
desc = "Create bots with random neural networks, collecting feed data.",
|
||||
usage = "<name> [skin]"
|
||||
usage = "<amount> <name> [skin]"
|
||||
)
|
||||
public void create(@Sender Player sender, String name, @OptArg String skin) {
|
||||
manager.createBots(sender, name, skin, 1);
|
||||
public void random(@Sender Player sender, int n, String name, @OptArg String skin) {
|
||||
manager.createBots(sender, name, skin, n, NetworkType.RANDOM);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -11,7 +11,6 @@ import net.nuggetmc.ai.bot.BotManager;
|
||||
import net.nuggetmc.ai.command.CommandHandler;
|
||||
import net.nuggetmc.ai.command.CommandInstance;
|
||||
import net.nuggetmc.ai.utils.Debugger;
|
||||
import org.apache.commons.lang.StringUtils;
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.ChatColor;
|
||||
import org.bukkit.Location;
|
||||
|
||||
Reference in New Issue
Block a user