You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Laylua is a .NET 7 Lua wrapper that allows you to easily embed and sandbox Lua in your application.
3
-
It offers several advantages that make it stand out:
4
-
-**Performance**
5
-
Lua operations can be performed in a "zero-alloc" manner, i.e. without any needless allocations, and utilizing entity pooling for referenced Lua entities. The lifetime of the referenced entities is controlled by your code. Values can be passed to and from Lua without being boxed.
6
-
-**Flexible API Access**
7
-
Both low and high-level API is available. With a simple `global using static Laylua.Moon.LuaNative;` you essentially get 1:1 Lua C API experience.
8
-
-**Preventing Panic Aborts**
9
-
Unlike other similar libraries, Laylua prevents the Lua panic handler from aborting the application even on Linux, making Lua interactions completely safe and far more error-forgiving.
10
-
-**Proper Sandbox Capabilities**
11
-
Laylua does not impose any restrictions on you, allowing you to initialize a clean Lua state without any preloaded libraries. You have the freedom to selectively load specific libraries of your preference. Additionally, Laylua comes with built-in features for memory allocation and instruction count limiting.
2
+
Laylua allows you to easily embed [Lua 5.4](https://www.lua.org/manual/5.4/manual.html) in your .NET application.
12
3
13
-
## Example
4
+
Highlights:
5
+
- plug and play
6
+
- proper handling of exceptions and Lua errors
7
+
- built-in memory allocation and instruction count limiting
8
+
- control over what gets exposed to Lua code
9
+
- optimized, zero-alloc, poolable Lua entities, no value type boxing
10
+
11
+
## Examples
14
12
```cs
15
13
using (varlua=newLua())
16
14
{
@@ -23,4 +21,4 @@ using (var lua = new Lua())
23
21
```
24
22
25
23
## Documentation
26
-
Documentation is available on [Laylua's wiki](https://github.com/Quahu/Laylua/wiki).
24
+
[Check out the wiki](https://github.com/Quahu/Laylua/wiki).
0 commit comments