Lune:独立运行的 Luau 运行时
Lune: Standalone Luau Runtime

原始链接: https://github.com/lune-org/lune

Lune是一个用Rust构建的独立Luau运行时,它提供了一种快速、安全且轻量级的替代方案,可以替代其他基于Lua的环境,例如Node或Luvit。它优先考虑异步API,并拥有一个小的可执行文件大小(压缩后约5MB),同时包含许多功能。这些功能包括全面的文件系统、网络和标准I/O功能。 Lune为Roblox开发者提供了熟悉的运行时体验,其中包含一个忠实的任务调度器移植。它还提供了一个可选的库,用于处理Roblox场景和模型文件。Lune强调可读性和易用性,并通过优秀的文档和强大的自动补全功能提供支持。 虽然它不能完全兼容运行完整的Roblox游戏,但Lune旨在提供一个高性能且易于访问的Luau环境,从而能够在Roblox生态系统之外高效地开发和执行Luau脚本。

Hacker News 正在讨论 Lune,一个独立的 Luau 运行时。Luau 是 Roblox 开发的一种基于 Lua 的语言,它拥有改进的速度、向量支持和类型检查器。Dekkonot,Lune 和 Luau 的贡献者,强调了 Lune 对于脚本需求的适用性,它在 API 的完美性和实用性之间取得了平衡。 讨论要点包括 Luau 用于不受信任代码执行的安全特性及其 WebAssembly 编译能力。一些人对选择 Rust 来实现 Lune 进行了辩论,指出与 Go 或 Zig 等语言相比,它可能存在进入门槛。还提到了其他替代方案,例如 Luau 团队的 C++ 运行时 Lute。讨论还涉及 Rust 的编译时间与其他语言的对比,以及是否应该将 Go 视为遗留语言。最后,还讨论了实际用途,例如序列化 Roblox 资源,以及它的 VS Code 集成和类型检查器。

原文

Lune logo

A standalone Luau runtime.

Write and run programs, similar to runtimes for other languages such as Node, Deno, Bun, or Luvit for vanilla Lua.

Lune provides fully asynchronous APIs wherever possible, and is built in Rust 🦀 for speed, safety and correctness.

  • 🌙 Strictly minimal but powerful interface that is easy to read and remember, just like Luau itself
  • 🧰 Fully featured APIs for the filesystem, networking, stdio, all included in the small (~5mb zipped) executable
  • 📚 World-class documentation, on the web or directly in your editor, no network connection necessary
  • 🏡 Familiar runtime environment for Roblox developers, with an included 1-to-1 task scheduler port
  • ✏️ Optional built-in library for manipulating Roblox place & model files, and their instances
  • Making programs short and terse - proper autocomplete / intellisense make using Lune just as quick, and readability is important
  • Running full Roblox games outside of Roblox - there is some compatibility, but Lune is meant for different purposes

Head over to the Installation page to get started using Lune!

联系我们 contact @ memedata.com