Added customization documentation
This commit is contained in:
parent
7097952928
commit
631de995dd
25
readme.md
25
readme.md
|
@ -44,3 +44,28 @@ In the root directory of the repository run:
|
||||||
```
|
```
|
||||||
python server/main.py
|
python server/main.py
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Customizing
|
||||||
|
|
||||||
|
A way to change the equation may be implemented in the future, but currently it
|
||||||
|
is hard coded.
|
||||||
|
|
||||||
|
You can change the function `YTDServerFactory.func(x: int, y: int, z: int)` in
|
||||||
|
`server/main.py` to implement your own equation. This function accepts the world
|
||||||
|
coordinates and returns a dictionary representing the block at that location.
|
||||||
|
|
||||||
|
Here are examples of block representations accepted by quarry. These definitions
|
||||||
|
are from the top of `server/main.py`.
|
||||||
|
|
||||||
|
```
|
||||||
|
BLOCK_EMPTY = {'name': 'minecraft:air'}
|
||||||
|
BLOCK_SURFACE = {'name': 'minecraft:grass_block', 'snowy': 'false'}
|
||||||
|
BLOCK_SUBSURFACE = {'name': 'minecraft:dirt'}
|
||||||
|
BLOCK_UNDERGROUND = {'name': 'minecraft:stone'}
|
||||||
|
BLOCK_DEFAULT = {'name': 'minecraft:cobblestone'}
|
||||||
|
```
|
||||||
|
|
||||||
|
Information about blocks and block states can be found in
|
||||||
|
`generate_data\generated\reports\blocks.json` if the data generator has been
|
||||||
|
ran. You can also find this information online from the
|
||||||
|
[Minecraft Wiki](https://minecraft.wiki/).
|
||||||
|
|
Loading…
Reference in New Issue