在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
开源软件名称(OpenSource Name):PrismarineJS/flying-squid开源软件地址(OpenSource Url):https://github.com/PrismarineJS/flying-squid开源编程语言(OpenSource Language):JavaScript 99.8%开源软件介绍(OpenSource Introduction):flying-squidCreate Minecraft servers with a powerful, stable, and high level JavaScript API. Features
Building / RunningBefore running or building it is recommended that you configure the server in npm install
node app.js You can also install flying-squid globally with DockerDocker allows a higer level of isolation, compatibily and consistency. You can learn how to install Docker here. Quick start a simple server to test out flying-squid: docker run -p 25565:25565 prismarinejs/flying-squid With specific configuration and a container name: docker run -p 25565:25565 -v $(pwd)/config:/config --name my-flying-squid prismarinejs/flying-squid docker-compose is useful to quickly launch & stop a single container with a specific configuration.
version: '3.8'
services:
flying-squid:
image: prismarinejs/flying-squid
volumes:
- ${PWD}/config:/config
ports:
- "25565:25565"
volumes:
flying-squid: docker-compose -f path/to/docker-compose.yaml up Or do it all locally: docker build -t local-flying-squid .
docker run -p 25565:25565 local-flying-squid or docker-compose up World generationThere are several modules than can be used to generate the world. The default one is called diamond-square
To install a world generation, all you have to do is npm install it and then change the generation option in settings.json. Plugins
DocumentationFor development see the API documentation, CONTRIBUTE.md and HISTORY.md Using as a libflying-squid is also a server lib. Here is a basic example of usage: const mcServer = require('flying-squid')
mcServer.createMCServer({
'motd': 'A Minecraft Server \nRunning flying-squid',
'port': 25565,
'max-players': 10,
'online-mode': true,
'logging': true,
'gameMode': 1,
'difficulty': 1,
'worldFolder': 'world',
'generation': {
'name': 'diamond_square',
'options': {
'worldHeight': 80
}
},
'kickTimeout': 10000,
'plugins': {
},
'modpe': false,
'view-distance': 10,
'player-list-text': {
'header': 'Flying squid',
'footer': 'Test server'
},
'everybody-op': true,
'max-entities': 100,
'version': '1.16.1'
}) You can add server plugins and player plugins in your package, following CONTRIBUTE.md. For further examples, see the examples page. Contributors
|
2023-10-27
2022-08-15
2022-08-17
2022-09-23
2022-08-13
请发表评论