This commit is contained in:
Expand-sys 2021-10-12 20:21:09 +11:00
parent 57645e2e09
commit 472e3b7792

View file

@ -17,14 +17,13 @@ module.exports = {
function spawnMC(channel) {
let options = {
shell: true,
cwd: "~/minecraft/",
cwd: "/root/minecraft/",
};
const minecraft = spawn(
"java",
["-Xmx4096M", "-Xms1024M", "-jar", "server.jar", "-nogui"],
options
);
minecraftin = minecraft;
minecraft.stdout.on("data", (data) => {
try {
channel.send(`${data}`);