用Python操控Minecraft我的世界 1.安装Spigot服务器并添加RaspberryJuice插件
这次,我们要学习如何用Python程序,连接并操控自己的服务器
前几篇文章,我们创建的服务器都是从mcversions.net获取的,是原汁原味的服务端,这一次,我们要创建另外一种服务器——Spigot,Spigot服务器有一个小小的缺点,就是没办法装模组,但是它比原版服务端好的地方就是它可以安装插件,这次我们要让python来操控我的世界,就需要用到一个插件——RaspberryJuice
让我们开始吧!
首先,我们先下载服务器的jar文件,来到getBukkit网站
Get Bukkit | Download CraftBukkit 1.19.1 | Download Spigot 1.19.1Download the latest version of CraftBukkit and Spigot for your Minecraft server!https://getbukkit.org/这次,我们还是以1.16.3的版本为例,点击右上角download中的spigot,或者直接进入下方链接直达
SpigotDownload the latest version of Spigot for your Minecraft server!https://getbukkit.org/download/spigot
点击对应版本的download按键
然后点击Spigot-1.16.3.jar这个文字(注意不是Create a Server)进行下载
然后把jar放入一个文件夹中
创建一个bat文件,写入以下内容
@echo off
java -jar spigot-1.16.3.jar
pause
第一次运行,服务器自动终止(正常)
将eula.txt的eula=false改为true
再次运行
输出以下内容就是成功运行啦!
*** Error, this build is outdated ***
*** Please download a new build as per instructions from https://www.spigotmc.org/go/outdated-spigot ***
*** Server will start in 20 seconds ***
Loading libraries, please wait...
[14:04:00] [main/INFO]: Environment: authHost='https://authserver.mojang.com', accountsHost='https://api.mojang.com', sessionHost='https://sessionserver.mojang.com', name='PROD'
[14:04:00] [main/INFO]: Found new data pack file/bukkit, loading it automatically
[14:04:01] [main/INFO]: Reloading ResourceManager: Default, bukkit
[14:04:01] [Worker-Main-12/INFO]: Loaded 7 recipes
[14:04:00] [main/INFO]: Environment: authHost='https://authserver.mojang.com', accountsHost='https://api.mojang.com', sessionHost='https://sessionserver.mojang.com', name='PROD'
[14:04:00] [main/INFO]: Found new data pack file/bukkit, loading it automatically
[14:04:01] [main/INFO]: Reloading ResourceManager: Default, bukkit
[14:04:01] [Worker-Main-12/INFO]: Loaded 7 recipes
[14:04:01] [Server thread/INFO]: Starting minecraft server version 1.16.3
[14:04:01] [Server thread/INFO]: Loading properties
[14:04:02] [Server thread/INFO]: This server is running CraftBukkit version git-Spigot-2740d5a-890130b (MC: 1.16.3) (Implementing API version 1.16.3-R0.1-SNAPSHOT)
[14:04:02] [Server thread/INFO]: Debug logging is disabled
[14:04:02] [Server thread/INFO]: Server Ping Player Sample Count: 12
[14:04:02] [Server thread/INFO]: Using 4 threads for Netty based IO
[14:04:02] [Server thread/INFO]: Default game type: SURVIVAL
[14:04:02] [Server thread/INFO]: Generating keypair
[14:04:02] [Server thread/INFO]: Starting Minecraft server on *:25565
[14:04:02] [Server thread/INFO]: Using default channel type
[14:04:02] [Server thread/INFO]: Preparing level "world"
[14:04:02] [Server thread/INFO]: -------- World Settings For [world] --------
[14:04:02] [Server thread/INFO]: Arrow Despawn Rate: 1200 Trident Respawn Rate:1200
[14:04:02] [Server thread/INFO]: Entity Tracking Range: Pl 48 / An 48 / Mo 48 / Mi 32 / Other 64
[14:04:02] [Server thread/INFO]: Allow Zombie Pigmen to spawn from portal blocks: true
[14:04:02] [Server thread/INFO]: Item Despawn Rate: 6000
[14:04:02] [Server thread/INFO]: Item Merge Radius: 2.5
[14:04:02] [Server thread/INFO]: View Distance: 10
[14:04:02] [Server thread/INFO]: Zombie Aggressive Towards Villager: true
[14:04:02] [Server thread/INFO]: Cactus Growth Modifier: 100%
[14:04:02] [Server thread/INFO]: Cane Growth Modifier: 100%
[14:04:02] [Server thread/INFO]: Melon Growth Modifier: 100%
[14:04:02] [Server thread/INFO]: Mushroom Growth Modifier: 100%
[14:04:02] [Server thread/INFO]: Pumpkin Growth Modifier: 100%
[14:04:02] [Server thread/INFO]: Sapling Growth Modifier: 100%
[14:04:02] [Server thread/INFO]: Beetroot Growth Modifier: 100%
[14:04:02] [Server thread/INFO]: Carrot Growth Modifier: 100%
[14:04:02] [Server thread/INFO]: Potato Growth Modifier: 100%
[14:04:02] [Server thread/INFO]: Wheat Growth Modifier: 100%
[14:04:02] [Server thread/INFO]: NetherWart Growth Modifier: 100%
[14:04:02] [Server thread/INFO]: Vine Growth Modifier: 100%
[14:04:02] [Server thread/INFO]: Cocoa Growth Modifier: 100%
[14:04:02] [Server thread/INFO]: Bamboo Growth Modifier: 100%
[14:04:02] [Server thread/INFO]: SweetBerry Growth Modifier: 100%
[14:04:02] [Server thread/INFO]: Kelp Growth Modifier: 100%
[14:04:02] [Server thread/INFO]: Entity Activation Range: An 32 / Mo 32 / Ra 48 / Mi 16 / Tiv true
[14:04:02] [Server thread/INFO]: Hopper Transfer: 8 Hopper Check: 1 Hopper Amount: 1
[14:04:02] [Server thread/INFO]: Experience Merge Radius: 3.0
[14:04:02] [Server thread/INFO]: Mob Spawn Range: 6
[14:04:02] [Server thread/INFO]: Nerfing mobs spawned from spawners: false
[14:04:02] [Server thread/INFO]: Custom Map Seeds: Village: 10387312 Desert: 14357617 Igloo: 14357618 Jungle: 14357619 Swamp: 14357620 Monument: 10387313 Ocean: 14357621 Shipwreck: 165745295 End City: 10387313 Slime: 987234911 Bastion: 30084232 Fortress: 30084232 Mansion: 10387319 Fossil: 14357921 Portal: 34222645
[14:04:02] [Server thread/INFO]: Tile Max Tick Time: 50ms Entity max Tick Time: 50ms
[14:04:02] [Server thread/INFO]: Max TNT Explosions: 100
[14:04:04] [Server thread/INFO]: -------- World Settings For [world_nether] --------
[14:04:04] [Server thread/INFO]: Arrow Despawn Rate: 1200 Trident Respawn Rate:1200
[14:04:04] [Server thread/INFO]: Entity Tracking Range: Pl 48 / An 48 / Mo 48 / Mi 32 / Other 64
[14:04:04] [Server thread/INFO]: Allow Zombie Pigmen to spawn from portal blocks: true
[14:04:04] [Server thread/INFO]: Item Despawn Rate: 6000
[14:04:04] [Server thread/INFO]: Item Merge Radius: 2.5
[14:04:04] [Server thread/INFO]: View Distance: 10
[14:04:04] [Server thread/INFO]: Zombie Aggressive Towards Villager: true
[14:04:04] [Server thread/INFO]: Cactus Growth Modifier: 100%
[14:04:04] [Server thread/INFO]: Cane Growth Modifier: 100%
[14:04:04] [Server thread/INFO]: Melon Growth Modifier: 100%
[14:04:04] [Server thread/INFO]: Mushroom Growth Modifier: 100%
[14:04:04] [Server thread/INFO]: Pumpkin Growth Modifier: 100%
[14:04:04] [Server thread/INFO]: Sapling Growth Modifier: 100%
[14:04:04] [Server thread/INFO]: Beetroot Growth Modifier: 100%
[14:04:04] [Server thread/INFO]: Carrot Growth Modifier: 100%
[14:04:04] [Server thread/INFO]: Potato Growth Modifier: 100%
[14:04:04] [Server thread/INFO]: Wheat Growth Modifier: 100%
[14:04:04] [Server thread/INFO]: NetherWart Growth Modifier: 100%
[14:04:04] [Server thread/INFO]: Vine Growth Modifier: 100%
[14:04:04] [Server thread/INFO]: Cocoa Growth Modifier: 100%
[14:04:04] [Server thread/INFO]: Bamboo Growth Modifier: 100%
[14:04:04] [Server thread/INFO]: SweetBerry Growth Modifier: 100%
[14:04:04] [Server thread/INFO]: Kelp Growth Modifier: 100%
[14:04:04] [Server thread/INFO]: Entity Activation Range: An 32 / Mo 32 / Ra 48 / Mi 16 / Tiv true
[14:04:04] [Server thread/INFO]: Hopper Transfer: 8 Hopper Check: 1 Hopper Amount: 1
[14:04:04] [Server thread/INFO]: Experience Merge Radius: 3.0
[14:04:04] [Server thread/INFO]: Mob Spawn Range: 6
[14:04:04] [Server thread/INFO]: Nerfing mobs spawned from spawners: false
[14:04:04] [Server thread/INFO]: Custom Map Seeds: Village: 10387312 Desert: 14357617 Igloo: 14357618 Jungle: 14357619 Swamp: 14357620 Monument: 10387313 Ocean: 14357621 Shipwreck: 165745295 End City: 10387313 Slime: 987234911 Bastion: 30084232 Fortress: 30084232 Mansion: 10387319 Fossil: 14357921 Portal: 34222645
[14:04:04] [Server thread/INFO]: Tile Max Tick Time: 50ms Entity max Tick Time: 50ms
[14:04:04] [Server thread/INFO]: Max TNT Explosions: 100
[14:04:04] [Server thread/WARN]: Unable to find spawn biome
[14:04:05] [Server thread/INFO]: -------- World Settings For [world_the_end] --------
[14:04:05] [Server thread/INFO]: Arrow Despawn Rate: 1200 Trident Respawn Rate:1200
[14:04:05] [Server thread/INFO]: Entity Tracking Range: Pl 48 / An 48 / Mo 48 / Mi 32 / Other 64
[14:04:05] [Server thread/INFO]: Allow Zombie Pigmen to spawn from portal blocks: true
[14:04:05] [Server thread/INFO]: Item Despawn Rate: 6000
[14:04:05] [Server thread/INFO]: Item Merge Radius: 2.5
[14:04:05] [Server thread/INFO]: View Distance: 10
[14:04:05] [Server thread/INFO]: Zombie Aggressive Towards Villager: true
[14:04:05] [Server thread/INFO]: Cactus Growth Modifier: 100%
[14:04:05] [Server thread/INFO]: Cane Growth Modifier: 100%
[14:04:05] [Server thread/INFO]: Melon Growth Modifier: 100%
[14:04:05] [Server thread/INFO]: Mushroom Growth Modifier: 100%
[14:04:05] [Server thread/INFO]: Pumpkin Growth Modifier: 100%
[14:04:05] [Server thread/INFO]: Sapling Growth Modifier: 100%
[14:04:05] [Server thread/INFO]: Beetroot Growth Modifier: 100%
[14:04:05] [Server thread/INFO]: Carrot Growth Modifier: 100%
[14:04:05] [Server thread/INFO]: Potato Growth Modifier: 100%
[14:04:05] [Server thread/INFO]: Wheat Growth Modifier: 100%
[14:04:05] [Server thread/INFO]: NetherWart Growth Modifier: 100%
[14:04:05] [Server thread/INFO]: Vine Growth Modifier: 100%
[14:04:05] [Server thread/INFO]: Cocoa Growth Modifier: 100%
[14:04:05] [Server thread/INFO]: Bamboo Growth Modifier: 100%
[14:04:05] [Server thread/INFO]: SweetBerry Growth Modifier: 100%
[14:04:05] [Server thread/INFO]: Kelp Growth Modifier: 100%
[14:04:05] [Server thread/INFO]: Entity Activation Range: An 32 / Mo 32 / Ra 48 / Mi 16 / Tiv true
[14:04:05] [Server thread/INFO]: Hopper Transfer: 8 Hopper Check: 1 Hopper Amount: 1
[14:04:05] [Server thread/INFO]: Experience Merge Radius: 3.0
[14:04:05] [Server thread/INFO]: Mob Spawn Range: 6
[14:04:05] [Server thread/INFO]: Nerfing mobs spawned from spawners: false
[14:04:05] [Server thread/INFO]: Custom Map Seeds: Village: 10387312 Desert: 14357617 Igloo: 14357618 Jungle: 14357619 Swamp: 14357620 Monument: 10387313 Ocean: 14357621 Shipwreck: 165745295 End City: 10387313 Slime: 987234911 Bastion: 30084232 Fortress: 30084232 Mansion: 10387319 Fossil: 14357921 Portal: 34222645
[14:04:05] [Server thread/INFO]: Tile Max Tick Time: 50ms Entity max Tick Time: 50ms
[14:04:05] [Server thread/INFO]: Max TNT Explosions: 100
[14:04:05] [Server thread/WARN]: Unable to find spawn biome
[14:04:05] [Server thread/INFO]: Preparing start region for dimension minecraft:overworld
[14:04:05] [Worker-Main-11/INFO]: Preparing spawn area: 0%
[14:04:05] [Worker-Main-11/INFO]: Preparing spawn area: 4%
[14:04:06] [Worker-Main-10/INFO]: Preparing spawn area: 15%
[14:04:06] [Worker-Main-11/INFO]: Preparing spawn area: 24%
[14:04:07] [Worker-Main-13/INFO]: Preparing spawn area: 44%
[14:04:07] [Worker-Main-9/INFO]: Preparing spawn area: 57%
[14:04:08] [Worker-Main-12/INFO]: Preparing spawn area: 69%
[14:04:08] [Worker-Main-11/INFO]: Preparing spawn area: 89%
[14:04:09] [Server thread/INFO]: Time elapsed: 3837 ms
[14:04:09] [Server thread/INFO]: Preparing start region for dimension minecraft:the_nether
[14:04:09] [Worker-Main-10/INFO]: Preparing spawn area: 0%
[14:04:09] [Worker-Main-10/INFO]: Preparing spawn area: 5%
[14:04:10] [Worker-Main-14/INFO]: Preparing spawn area: 17%
[14:04:10] [Worker-Main-14/INFO]: Preparing spawn area: 30%
[14:04:11] [Worker-Main-14/INFO]: Preparing spawn area: 43%
[14:04:11] [Worker-Main-9/INFO]: Preparing spawn area: 58%
[14:04:12] [Worker-Main-8/INFO]: Preparing spawn area: 75%
[14:04:12] [Worker-Main-12/INFO]: Preparing spawn area: 90%
[14:04:12] [Server thread/INFO]: Time elapsed: 3751 ms
[14:04:12] [Server thread/INFO]: Preparing start region for dimension minecraft:the_end
[14:04:12] [Worker-Main-12/INFO]: Preparing spawn area: 0%
[14:04:13] [Worker-Main-12/INFO]: Preparing spawn area: 66%
[14:04:13] [Server thread/INFO]: Time elapsed: 684 ms
[14:04:13] [Server thread/INFO]: Done (10.612s)! For help, type "help"
>
但是这样还不够,输入stop并回车,终止服务器
为了将python和服务器关联起来,我们需要用到一个插件RaspberryJuice
进入这个网站,看到如下页面
点击Download Now开始下载,这里不推荐大家使用迅雷,因为文件太小,迅雷一直卡在连接资源,所以浏览器有迅雷扩展程序的话把它先关了然后才下载,这样用了不到1秒就能成功下载啦!
下载完毕后,将jar文件复制到服务器目录下的plugins文件夹中
然后启动服务器即可
从输出中不难发现,RaspberryJuice已经成功被我们添加进去啦!
好了,安装Spigot服务器并添加RaspberryJuice的教程就到这里!
下一篇文章我们就来详细了解如何用Python的第三方库对Minecraft进行编程~
喜欢的话就点赞关注吧!
用Python操控Minecraft我的世界 1.安装Spigot服务器并添加RaspberryJuice插件相关推荐
- 我的世界在自建的服务器中装mod,《我的世界》中国版服务器MOD添加教程
我的世界中国版怎么加MOD 中国版功能组件怎么安装 <我的世界中国版>加MOD方法详解 1.首先右键你的MC中国版启动器找到打开文件夹位置,(如果右键中没有打开文件夹位置的话可以点击属性- ...
- 我的世界linux联机游戏,MineCraft 我的世界 – PC 端联机服务器搭建 ( Linux )
1.安装 Screen 任务时间:时间未知 MineCraft 是长期运行的,但是 Linux 下只要关闭连接,所有运行在该窗口下的服务都是被 kill,所以我们需要 Screen 来保持我们的 Mi ...
- MC我的世界Windows安装forge服务器教程(一)
目录 一.前置环境搭建 1.配置安全组 2.配置阿里云网络源 3.安装JAVA17 二.安装Minecraft服务端 三.整合包补充 一.前置环境搭建 高校计划 - 免费学生云服务器 未参与过高校学生 ...
- 我的世界(2)-服务器菜单(Chestcommands插件)
文章目录 前言 相关介绍 上一篇笔记 下一篇笔记 一.指令 二.权限 三.菜单设置 四.按钮设置 五.其他的按钮配置项 前言 Minecraft沙盒游戏,它不单单可以让玩家游戏,玩家还能自己创建MC的 ...
- python 扫描仪_玩《Minecraft我的世界》学python编程,可领|取电子学习版本
为何选择学习python python是一种解释型.面向对象.动态数据类型的高级程序设计语言,它具有丰富和强大的库,能够把其它语言(尤其是c++)制作的各种模块很轻松地联结在一起.pyton在编程语言 ...
- python如何连接创建我的世界_我的Python世界 玩《Minecraft我的世界》学Python编程...
1 Python 基础 1 1.1 Python 的历史 1 1.2 Python 的发展 1 1.3 Python 的优缺点 2 1.3.1 Python 的优点 2 1.3.2 Python 的缺 ...
- python玩转我的世界_PYTHON玩转我的世界——批量生成铁傀儡
原标题:PYTHON玩转我的世界--批量生成铁傀儡 坐标系统 我的世界是由一个个方块构成的,每个方块边长都是1米.方块的位置由X,Y,Z三维坐标表示.其中X和Z表示水平面的坐标,Y表示垂直高度坐标. ...
- python做运动控制_第一课:用Python操控小龟小车运动
欢迎来到小龟的课堂,今天我们讲如何用小龟小车的车载Python控制小车运动. 如果小伙伴还不会使用小龟小车的Python编辑器的话,可以阅读这篇教程<如何使用小龟小车的Python编辑器> ...
- 自动化办公 Python 操控 Word
虽然Word不好用, 但还必须得用它, python-docx是专门用于编辑Word文档的一个工具库, 它有两大用途, 自动化生成word文档 and 自动化修改文档 python word 1. 自 ...
最新文章
- 《转》 ImportError: No module named caffe 的解决方案
- 华为固件解包工具linux,华为解包工具官方下载
- CCPC-Wannafly Winter Camp Day8 (Div2, onsite) 补题
- import win32com.client在python中报错及其解决办法
- mathematica 8.0.0 激活方法
- G312高速公路S标段路线设计--金陵科技学院道路毕业设计
- UNet++ 论文翻译
- phpstudy修改mysql账户名_phpstudy怎么更改用户名
- 《数学之美》读后感与商榷
- Kettle对非结构化数据进行分类
- 游戏开发学习路线(需要学什么)
- Spherical Harmonics Lighting in DirectX
- vue打包导致浏览器崩溃的解决方法
- *Algs4-1.4.26-三点共线-(未解决)
- 【贪玩巴斯】Unity3D初学圣经(一)——学习要求 Unity简单介绍 游戏引擎介绍 课程体系介绍 「1-1 到 1-4 」—— 2021年12月9日
- 项目干系人包括的人群
- beyond-谁伴我闯荡-国语谐音
- 论文笔记——基于多传感器融合的定位建图及导航研究
- 如果暴力不是为了杀戮,那就毫无意义
- hadoop本地模式部署_您需要HADOOP来运行SPARK吗?