批处理文本粘贴/停止 [英] Batch text pasteing/stoping

查看:135
本文介绍了批处理文本粘贴/停止的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个问题可以用两种方法之一解决.我正在运行Minecraft 1.8.5服务器.我要启动它,停止它,然后每小时重新启动它.之所以说这两种方式之一,是因为我可以制作一个在控制台输入中键入停止"的批处理(我认为这样做会更好),或者只是在这里一起停止程序,这就是我到目前为止所做的(我打算在乘法帮助器文件中运行此命令以使其关闭,但任何事情都会有所帮助.

I have one problem that could work one of two ways. I am running a Minecraft 1.8.5 server. I want to start it stop it and restart it every hour. The reason why I said one of two ways it because I could either make a batch that types "stop" in the console input (I think this would work better) or Just stop the program all together here is what I have made so far ( I am planning to run this in multiply helper files to close only but any thing will help.

这将打开Minecraft服务器:

This opens the Minecraft server:

echo.

echo Waiting For One Hour...

TIMEOUT /T 3600 /NOBREAK

echo.

start minecraft_server.1.8.5

echo Minecraft Opened! pause >nul

我无法开始工作(我最终将其集成到第一个脚本中的单独文件):

This I can not get to work (separate file that I will eventually integrate into the first script):

@echo on

TASKKILL /F /IM Minecraft server /T

echo killed!

推荐答案

在运行Minecraft服务器时,您突然不想像这样强制杀死它(以经验丰富的Minecraft服务器所有者的身份交谈) .数据将不会被大量保存,玩家和整个世界将会损失​​最多,即使自上一次 probber 重新启动以来并非所有数据.

When running a Minecraft server, you serdenly do not want to force kill it like that (talking as an experienced Minecraft server owner). The data will not be saved probberly, and players+the world will lose most, if not all data since last probber restart.

我建议为此使用一个简单的插件...因为确实需要 从控制台或游戏中/stop停止服务器以使其停止. 这可能起作用: http://dev.bukkit.org/bukkit-plugins/auto-shutdown/

I recommend using a simple plugin for this... As it really is needed to stop a server with 'stop' from the console, or /stop in-game. This might work: http://dev.bukkit.org/bukkit-plugins/auto-shutdown/

如果不是,或者它也不适合您的服务器,只需搜索"Bukkit自动重启"或"Spigot自动重启"

If not, or if it doesn't suit your server either, just search up 'Bukkit automatic restart' or 'Spigot automatic restart'

我不能说太多: 不要 停止使用除程序外直接与您的Minecraft服务器交互的服务器-在这种情况下,只有您一个插件选项.

I cannot say it to much: do not stop a server using anything but a program interacting directly with your Minecraft server - in this case, a plugin is your only good option.

这篇关于批处理文本粘贴/停止的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆