LuaCraft
LuaCraft 使用 LuaJ 为 Paper/Bukkit 服务器带来轻量、快速的 Lua 脚本支持,使服务器开发者无需构建完整插件即可创建游戏逻辑。
LuaCraft 致力于提供简洁且易于理解的语法元素,让作为服务器开发者的你更加轻松。
它不仅追求简洁,还力求尽可能快速运行,并通过最大程度的沙箱隔离来确保服务器的安全性。
主要特性
- Lua 脚本集成:零编译开销,直接在 Paper/Bukkit 服务器中嵌入 Lua
- 轻量且快速:LuaJ 提供高效的脚本执行,对性能影响极小
- 简单 API:使用直观的 Lua 语法和服务器事件钩子编写服务端逻辑
- 快速开发:跳过传统插件样板代码,更快地迭代服务器机制
入门指南
LuaCraft 非常适合希望用自定义脚本扩展服务器的服务器所有者和开发者。只需将插件放入 /plugins 文件夹即可开始脚本编写。
你可以前往 /plugins/LuaCraft/scripts 放置你的 Lua 脚本。
通过创建 helloworld.lua 并将以下脚本放入其中,开始编写你的第一个脚本!
function ServerEvent.OnPlayerJoin(event)
local player = event.Player
local white = "&#FFFFFF"
local component = Component(white, "Hello world")
Chat.Broadcast(component)
end
然后在游戏中输入 /lua reloadall,当你重新加入服务器时,聊天栏中应该会显示清晰漂亮的 “Hello world”。
依赖要求
- Paper(最新版本 1.21.4+)
- Vault 软依赖 (可选)
- Skript 软依赖 (可选)
项目类型
插件类型:Paper/Bukkit 插件
分类:脚本工具、开发工具、实用程序
用途:服务器开发
LuaCraft
LuaCraft brings lightweight, fast Lua scripting to Paper/Bukkit servers using LuaJ, enabling server developers to create game logic without building full plugins.
LuaCraft strives for simplistic yet understandable syntax elements that make your life as a server developer easier.
It doesn't only strive for simplistic, it strives to be as fast as possible, and keep your server as safe as possible by sandboxing as much as possible
Key Features
-
Lua Scripting Integration: Embed Lua directly into your Paper/Bukkit server with zero compilation overhead
-
Lightweight & Fast: LuaJ provides efficient script execution with minimal performance impact
-
Simple API: Write server-side logic using intuitive Lua syntax and server event hooks
Quick Development: Skip traditional plugin boilerplate and iterate faster on server mechanics
Getting Started
LuaCraft is perfect for server owners and developers who want to extend their server with custom scripts. Simply drop the plugin in your /plugins folder and start scripting.
You can find where to place your Lua scripts by heading to /plugins/LuaCraft/scripts.
Start by creating your first script by creating helloworld.lua and placing this script into it!
function ServerEvent.OnPlayerJoin(event)
local player = event.Player
local white = "&#FFFFFF"
local component = Component(white, "Hello world")
Chat.Broadcast(component)
end
You can then do /lua reloadall in game and bam when you rejoin you should see a clear nice "Hello world" in your chat.
Requirements
- Paper (latest versions 1.21.4+)
- Vault soft dependency (OPTIONAL)
- Skript soft dependency (OPTIONAL)
Project Type
Plugin Type: Paper/Bukkit Plugin
Categories: Scripting, Development Tools, Utilities
Usage: Server development
评论 0
登录后参与评分
还没有评论,来抢沙发吧