https://github.com/paladin-t/bitty.luax_plugin
A Lua-extension plugin for Bitty Engine.
https://github.com/paladin-t/bitty.luax_plugin
bitty bitty-engine compiler lua
Last synced: about 1 year ago
JSON representation
A Lua-extension plugin for Bitty Engine.
- Host: GitHub
- URL: https://github.com/paladin-t/bitty.luax_plugin
- Owner: paladin-t
- License: mit
- Created: 2021-08-24T13:13:33.000Z (almost 5 years ago)
- Default Branch: main
- Last Pushed: 2021-08-25T09:25:12.000Z (almost 5 years ago)
- Last Synced: 2025-01-30T20:43:53.178Z (over 1 year ago)
- Topics: bitty, bitty-engine, compiler, lua
- Language: Lua
- Homepage:
- Size: 4.88 KB
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Luax compiler plugin for Bitty Engine
This repository implements a custom compiler/transpiler plugin for [Bitty Engine](https://github.com/paladin-t/bitty) with an extended Lua syntex.
This plugin implements `+=` and `-=` operators which the original Lua doesn't support.
```lua
local a = 0
for i = 1, 42 do
a += 1 -- Extended operator "+=".
end
print(a)
for i = 1, 42 do
a -= 1 -- Extended operator "-=".
end
print(a)
```
Seealso [paladin-t/bitty.compiler_plugin](https://github.com/paladin-t/bitty.compiler_plugin) for details.
## Installing
1. Clone or download this repository.
2. Click "Project", "Browse Data Directory..." from the menu bar.
3. Ensure there is a "plugins" directory under that directory.
4. Put the "plugin.bit" into the new created "plugins" directory. And name it properly.
5. Reopen Bitty Engine.
## Injecting
1. Create a new asset, select the registered "luax" type.
2. Click "Install" to inject necessary assets to the target project.
3. Write and run Luax code.