This commit is contained in:
2025-08-01 18:56:22 +09:00
parent d0e1d01de1
commit 15a1b37646
5 changed files with 52 additions and 1 deletions

View File

@@ -1 +1,52 @@
# onecommand-hs # OneCommand
![capsule](https://capsule-render.vercel.app/api?type=waving&height=300&color=gradient&text=One%20Command)
Simple Minecraft one command generator written in Haskell
![overview](./docs/image0.png)
## Installation
### Prerequisites
- Stack
- Cabal
- Glasgow Haskell Compiler
### Installation Guide
Run the following command.
```bash
stack build
```
## Usage
### MCF Format
`.mcf` is a simple format to define minecraft command blocks. A single `.mcf` file corresponds to a single impulse/repeating command block, which is chained by multiple chain command blocks. The format is consisted with commands delimited by lines. The first line is chain type identifier, which can be one of `!IMPULSE` or `!REPEATING`.
Example of MCF
```plain
!IMPULSE
command1
command2
# comment
```
### Generating
To generate the one command, put all `.mcf` files in a directory. And run the executable with path pointing at the directory.
```bash
ocmd ~/my-commands
```
There's also a sample commands directory at `/sample-cmd`
### Making Structure
Put generated command into a impulse command block on a flat surface, in _always active_ mode. The command structure will appear immediately.

BIN
docs/image0.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 369 KiB