cc-haxe/README.md
2023-03-22 00:57:41 +01:00

46 lines
1.4 KiB
Markdown

General purpose "operation system" for [ComputerCraft](https://tweaked.cc/) build with [Haxe](https://haxe.org/).
# Features
- TCP like rednet messages
- Rednet message routing
- Hardware abstraction
- Virtual screens to switch between multiple GUI apps
- Reactive UI framework
- Solid base to easily add applications
# Building
Requirements:
- `haxe` compiler
- `haxelib` for dependencies
- `nodejs` and package manager like `yarn`
- `make`
run `make deps && make`. The `bundle.min.lua` inside the `build` dir is the final file.
# Useful links
[CC lua code](https://github.com/cc-tweaked/CC-Tweaked/tree/mc-1.16.x/src/main/resources/data/computercraft/lua)
[CC wiki](https://tweaked.cc/)
[Tinkerbell Core Library](https://haxetink.github.io/tink_core/#/)
# Development
There are a couple of tool to your disposal that makes working easier.
## Watch
Run `make watch` to recompile when a file changed.
## Emulator
You could use Minecraft to run the program or you could use [craftos pc](https://www.craftos-pc.cc/) as an emulator. Just install it and run `make emulator`.
## Websconsole
Use `make webconsole` to run a http server that prints the log output of the program to the terminal. Run `haxe` with the `-D webconsole` flag.
You may need to [allow connections](https://github.com/cc-tweaked/CC-Tweaked/wiki/Allowing-access-to-local-IPs) to any ip when using webconsole ingame.