Updated Addons (markdown)

IntegratedQuantum 2020-06-07 19:13:01 +02:00
parent 82dd579069
commit a5d6664814

@ -6,11 +6,11 @@ Here you can find an instruction on how to make addon files. At the end of this
## How to make your own Addon: ## How to make your own Addon:
1. Locate the `addons` folder(should be inside the location you installed Cubyz in) 1. Locate the `addons` folder(should be inside the location you installed Cubyz in)
2. Create a new folder with the name(should not contain any spaces) of your Addon. 2. Create a new folder with the name(should not contain any spaces) of your Addon.
3. Decide what things you want to add and add the corresponding folder(`items`, `blocks`, `recipes`, `biomes`). 3. Decide what things you want to add and add the corresponding folder(`items`, `blocks`, `recipes`, `biomes`, `materials`).
4. Create a text file in the folder that represent the item/block/biome name(`name.any_extension` or just `name`). 4. Create a text file in the folder that represent the item/block/biome/material name(`name.any_extension` or just `name`).
<br> For recipes the file name is not used anywhere in the game and can be used for structuring. <br> For recipes the file name is not used anywhere in the game and can be used for structuring.
5. Check the following examples on how to fill the file: 5. Check the following examples on how to fill the file:
#### Items ### Items
There is not much to do here. All you can do is add a texture path. There will come more possibilities in later versions, if requested. There is not much to do here. All you can do is add a texture path. There will come more possibilities in later versions, if requested.
<br> Put the texture of your item in `*cubyz install path*/addons/*addon name*/items/textures`. <br> Put the texture of your item in `*cubyz install path*/addons/*addon name*/items/textures`.
<br> Copy the texture path(relative to the `textures` folder) into the file you made for your item:<br> <br> Copy the texture path(relative to the `textures` folder) into the file you made for your item:<br>
@ -25,7 +25,7 @@ texture materials/coal.png
``` ```
Item IDs are generated as `addon_name:item_name`. That's also the name that has to be used for recipes and block drops. Item IDs are generated as `addon_name:item_name`. That's also the name that has to be used for recipes and block drops.
#### Blocks ### Blocks
Each block has the following attributes: Each block has the following attributes:
- a block class which can be one of the following: `wood`, `stone`, `sand`, `unbreakable`, `leaf`, `fluid` and `ore`.<br> - a block class which can be one of the following: `wood`, `stone`, `sand`, `unbreakable`, `leaf`, `fluid` and `ore`.<br>
The block class determine if the block can be broken and with what tool you can break it.<br> The block class determine if the block can be broken and with what tool you can break it.<br>
@ -88,7 +88,7 @@ model cubyz:block.obj
texture cubyz:coal_ore texture cubyz:coal_ore
``` ```
#### Recipes ### Recipes
In each file you can define shortcuts for item names like this: In each file you can define shortcuts for item names like this:
``` ```
L = cubyz:oak_log L = cubyz:oak_log
@ -112,7 +112,7 @@ P P
result cubyz:workbench result cubyz:workbench
``` ```
#### Biomes ### Biomes
biome files are seperated in two parts: biome files are seperated in two parts:
##### 1. general attributes ##### 1. general attributes
- temperature in an arbitrary unit(0 meaning super cold, 360 meaning super hot)<br> - temperature in an arbitrary unit(0 meaning super cold, 360 meaning super hot)<br>
@ -156,6 +156,74 @@ structures:
cubyz:simple_vegetation cubyz:grass_vegetation 0.3 1 0 cubyz:simple_vegetation cubyz:grass_vegetation 0.3 1 0
``` ```
### Materials
Materials define what properties a tool has depending on what parts of it are made from this material.
##### Base properties
- head durability: how much durability is added to the tool if the head is made of this material. Negative values are also possible.<br>
Default value: 0<br>
Syntax Example: `head 20`
- binding durability: how much durability is added to the tool if the binding is made of this material. Negative values are also possible.<br>
Default value: 0<br>
Syntax Example: `binding 10`
- handle durability: how much durability is added to the tool if the handle is made of this material. Negative values are also possible.<br>
Default value: 0<br>
Syntax Example: `handle 10`
- damage: how much damage is dealt by the tool if the head is made of this material.<br>
Default value: 0<br>
Syntax Example: `damage 7.5`
- speed: how fast the tool breaks blocks if the head is made of this material.<br>
Default value: 0<br>
Syntax Example: `speed 2.5`
- level: what mining level the tool can break if the head is made of this material.<br>
Default value: 0<br>
Syntax Example: `level 2`
##### Modifiers
Each material can also add certain modifiers to the tool. These can have active(on use) and passive(per tick) effects. Currently there are only a few modifiers(cubyz:falling_apart and cubyz:regrowth).<br>
Modifers have also a strength value which determine how strong the effect is. If multiple parts add the same modifier, the effect will get stacked.<br>
Modifiers can be added like this:<br>
`modifier cubyz:falling_apart 2`<br>
Or more general:<br>
`modifier *mod*:*modifier name* *strength*`
You can add as many modifiers as you want.
##### Crafting Items
These are the items from which you can make the parts of the tool.<br>
Each item also has an associated material value which determines how many items are needed to create head/binding/handle of certain tools. Here is a list of how much material value is needed for each tool part:
Part|Material Value
-|-
Binding|50
Handle|50
Sword Blade|200
Axe Head|300
Pickaxe Head|300
Shovel Head|100
New items can be added like this:<br>
`cubyz:stick 50`<br>
or more general:<br>
`*mod*:*item name* *material value*`
Example file(`addons/cubyz/materials/wood`):
```
head -20
binding 50
handle 20
damage 0.1
speed 1
level 1
modifier cubyz:regrowth 1
modifier cubyz:falling_apart 5
cubyz:stick 50
cubyz:oak_planks 100
cubyz:oak_log 150
cubyz:oak_top 150
```
## Existing Addons ## Existing Addons
If you made an addon and want it to appear on this list, contact us on [discord](https://discord.gg/XtqCRRG) so we can see if it contains any inappropiate content and if it doesn't, we'll add it to the list. If you made an addon and want it to appear on this list, contact us on [discord](https://discord.gg/XtqCRRG) so we can see if it contains any inappropiate content and if it doesn't, we'll add it to the list.