PyFish (python)
Allows to execute python 3.12 scripts, add content, etc. in minecraft and also to make minecraft mod using GraalPy so no python installation is needed to play
介绍
A mod that allows you to execute python scripts or to make your own mods using python.
It has a “Minecraft” API that allows you to set blocks, summon entities, listen to events, etc. and since the last update you can also register items, blocks, creative tabs, tags, etc. under the namespace you want.
You can do whatever you want from adding blocks and crafts to your modpack to connecting your LLM API key to your server.
The user don’t have to have anything installed for Python to work.
This mod has GraalPy (a java Python) and pip integrated in its jar.
You can install every python package that is pure python you want in your mod.
Some Native packages are recoded in Java and included in PyFish. Native libs built-in now :
requests, sqlite3, asyncio, logging, pathlib, and websocket
You have to put your scripts in <your_mc_instance>/pyfish/<your_folder>/scripts/ (the name of “your_folder” will be the namespace used to register items, etc.) or in <your_mc_instance>/pyfish/scripts/ (if you put in pyfish/scripts it will register under pyfish’s namespace), they are executed automatically.
You can also make .jar mods and also .pyz (100% python) mods.
Fully detailed Documentation (IDE Support now !) here and Support on Discord
(the documentation contains the list of every functions available from the MCAPI and how to use them and also all needed informations)
常见问题
PyFish (python) 支持哪些 Minecraft 版本?
PyFish (python) 支持 Minecraft Java 版 1.21.1–1.21.11,共 2 个版本,可用的加载器:Fabric / NeoForge。下载时注意选择和你游戏版本一致的文件。
PyFish (python) 怎么安装?
先用 PCL2 或 HMCL 启动器安装对应版本的 Fabric / NeoForge,再把下载的 .jar 文件放进游戏目录的 mods 文件夹,重新启动游戏即可。开启了版本隔离的,mods 文件夹在 versions/版本名 下面。运行环境:客户端和服务端都要装。
评论
登录后评论和评分