Modding:Block Json Properties: Difference between revisions

From Vintage Story Wiki
No edit summary
(39 intermediate revisions by 3 users not shown)
Line 1: Line 1:
__NOTOC__
== Overview ==
== Overview ==
A complete list of all available properties:
A complete list of all available properties


<table id="treeviewtable" class="table table-bordered tt-table" style='table-layout: fixed'>
<table id="treeviewtable" class="table table-bordered tt-table" style='table-layout: fixed'>
Line 6: Line 7:
     <th width='300' align='left'>Property</th>
     <th width='300' align='left'>Property</th>
     <th width='200' align='left'>Type</th>
     <th width='200' align='left'>Type</th>
     <th width='80' align='left'>Default</th>
     <th width='120' align='left'>Default</th>
     <th align='left'>Usage</th>
     <th align='left'>Usage</th>
   </tr>
   </tr>
Line 16: Line 17:
   </tr>
   </tr>
   <tr>
   <tr>
     <td colspan="4" style='font-size: 14pt; border-bottom: 2pt solid black; padding-left: 100px;'><b>Common</b></td>
     <td colspan="4" style='font-size: 14pt; border-bottom: 2pt solid black; padding-left: 100px;'><b>Core (no byType available)</b></td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_code" data-tt-parent="root">code</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_code" data-tt-parent="root">Code</div></td>
     <td>string</td>
     <td>string</td>
     <td>-</td>
     <td>required</td>
     <td>A unique identifier for the block.</td>
     <td>A unique identifier for the block.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_maxstacksize" data-tt-parent="root">maxstacksize</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_code_info" data-tt-parent="p_code" data-invisible="true"></div></td>
     <td>number</td>
     <td colspan="3">
    <td>64</td>
A '''domain prefix''' will be added dynamically depending on the location of the file. Every mod and VintageStory itself have a unique prefix.
     <td>Determines the maximum amount you can stack the block in one slot.</td>
 
For example the code '''<code>stone</code>''' turns into '''<code>game:stone</code>'''.
 
The code identifier has to be unique inside its domain. In theory there could be equal identifiers with different domain prefixes.
Find out more about [[Basic Modding#Domains|Domains]].
     </td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_enabled " data-tt-parent="root">enabled</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_enabled" data-tt-parent="root">Enabled</div></td>
     <td>boolean</td>
     <td>boolean</td>
     <td>true</td>
     <td>true</td>
     <td>If the block will be added to game or not.</td>
     <td>If the block will be loaded or not. Can be used to temporarily remove the block.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_variantgroups" data-tt-parent="root">VariantGroups</div></td>
    <td>array of object</td>
    <td>-</td>
    <td>Allows you define multiple variants of the same block.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_variantgroups_info" data-tt-parent="p_variantgroups" data-invisible="true"></div></td>
    <td colspan="3">
The variantgroups property allows you to define multiple variants of this block. All of them will have their unique pattern, which will be added to the block code.
 
An easy example would be a bowl, which can either be raw or burned:
<syntaxhighlight lang="json">
variantgroups: [
{ code:"type", states: ["raw", "burned"] },
],
</syntaxhighlight>
 
Meaning there will be two blocks <code>bowl-raw</code> and <code>bowl-burned</code>.
 
----
 
It's also possible to define multiple groups.
 
<syntaxhighlight lang="json">
variantgroups: [
{ code:"state", states: ["closed", "opened"] },
{ code:"contents", states: ["empty", "cabbage"] },
],
</syntaxhighlight>
 
As a result you will have 2x2 groups, which will be added one after each other: <code>barrel-closed-empty</code>, <code>barrel-closed-cabbage</code>, <code>barrel-opened-empty</code> and <code>barrel-opened-cabbage</code>.
 
----
 
Additionally it is possible to refer to external lists that are found in the worldproperties folder, such as <code>block/rock</code>, which contains all states of all rock types. This used for <code>gravel</code>, <code>sand</code> and <code>rock</code>. It's a good way to keep everything organized:
<syntaxhighlight lang="json">
variantgroups: [
{ loadFromProperties: "block/rock" },
],
</syntaxhighlight>
 
Here is a full list of all groups and their variants (you can also find them in the <code>assets/worldproperties</code> folder):
{{:json:block:worldvariantgroups}}
----
 
Furthermore there are two ways of combining groups together. So far we covered the default combination mode, which is <code>multiplicative</code> (the total count of variants is the product of all states).
 
Let's take a look at a different example (flowerpot), which uses the <code>additive</code> combination mode:
<syntaxhighlight lang="json">
variantgroups: [
{ code: "type", states: ["raw"] },
{ code: "empty", states: ["empty"], combine: "additive" },
{ code: "flower", loadFromProperties: "block/flower", combine: "additive" },
{ code: "mushroom", loadFromProperties: "block/mushroom", combine: "additive" },
{ code: "sapling", loadFromProperties: "block/wood", combine: "additive" },
],
</syntaxhighlight>
 
The variants are <code>flowerpot-raw</code>, <code>flowerpot-empty</code>, <code>flowerpot-{all flowers}</code>, <code>flowerpot-{all mushrooms}</code> and <code>flowerpot-{all saplings}</code>.
 
<code>Additive</code> mode could also be called separate, since it defines a variant separate from all the other groups:
 
<syntaxhighlight lang="json">
variantgroups: [
{ code: "something", states: ["same", "different"] },
{ code: "type", states: ["raw", "baked"] },
{ code: "empty", states: ["red", "green"], "combine": "additive" },
],
</syntaxhighlight>
 
In this case, the result would be <code>same-raw</code>, <code>same-baked</code>, <code>different-raw</code>, <code>different-baked</code>, <code>red</code> and <code>green</code>
    </td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_byType" data-tt-parent="root">(any) byType</div></td>
    <td>key: string; value: object</td>
    <td>-</td>
    <td>You can create properties for certain variants of the block.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_class" data-tt-parent="root">class</div></td>
    <td scope="row"><div class="tt" data-tt-id="p_byType_info" data-tt-parent="p_byType" data-invisible="true"></div></td>
    <td colspan="3">
In order to define properties for specific variants you can add '''byType''' to the property name. This allows you to define it depending on the type and always follows the same syntax:
<syntaxhighlight lang="json">
(property)ByType: {
"selector": property,
"selector2": property2,
...
}
</syntaxhighlight>
 
If the selector matches the name of the variant the given property will be used. Keep in mind that only the first matching one will be used (everything below will be ignored).
 
A slab for example has two variants ('''up''', '''down'''), which have different collision boxes:
<syntaxhighlight lang="json">
collisionboxByType: {
"*-down": { x1: 0, y1: 0, z1: 0,  x2: 1, y2: 0.5, z2: 1 },
"*-up": { x1: 0, y1: 0.5, z1: 0,  x2: 1, y2: 1, z2: 1 }
},
</syntaxhighlight>
 
The char '''<code>*</code>''' stands for anything. In this case it ignores the code of the block.
 
Furthermore this opens up even more possbilities for more advanced selectors like this one for doors:
<code>*-north-*-opened-left</code>. This will ignore the second variantgroup. Additionally ByType can also be used for child properties:
<syntaxhighlight lang="json">
collisionboxnbox: {
x1: 0, y1: 0, z1: 0.875, x2: 1, y2: 1, z2: 1,
rotateYByType: {
"*-north-*-opened-left": 90,
"*-north-*-closed-left": 0,
"*-west-*-opened-left": 180,
"*-west-*-closed-left": 90,
 
"*-east-*-opened-left": 0,
"*-east-*-closed-left": 270,
"*-south-*-opened-left": 270,
"*-south-*-closed-left": 180,
 
"*-north-*-opened-right": 270,
"*-north-*-closed-right": 0,
"*-west-*-opened-right": 0,
"*-west-*-closed-right": 90,
 
"*-east-*-opened-right": 180,
"*-east-*-closed-right": 270,
"*-south-*-opened-right": 90,
"*-south-*-closed-right": 180
}
},
</syntaxhighlight>
 
Since Vintagestory v1.8 it is also possible to use the variantgroup as a placeholder:
<syntaxhighlight lang="json">
variantgroups: [
{ code: "type", states: ["normal", "bamboo"] },
],
textures: {
horizontals: { base: "block/hay/{type}-side" },
verticals: { base: "block/hay/{type}-top" },
},
</syntaxhighlight>
</td>
  </tr>
  <tr>
    <td colspan="4" style='font-size: 14pt; border-bottom: 2pt solid black; padding-left: 100px;'><b>Specific</b></td>
  </tr>
  <tr>
     <td scope="row"><div class="tt" data-tt-id="p_class" data-tt-parent="root">Class</div></td>
    <td>string</td>
    <td>&quot;block&quot;</td>
    <td>The block class can add special functionalities for the block.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_class_info" data-tt-parent="p_class" data-invisible="true"></div></td>
    <td colspan="3">
It can be used to open guis or adding other extra functionality to the block. A complete tutorial of how to add your own class to the game can be found [[Advanced Blocks|here]].
</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_entityclass" data-tt-parent="root">EntityClass</div></td>
     <td>string</td>
     <td>string</td>
     <td>block</td>
     <td>-</td>
     <td></td>
    <td>The block entity class is able to tick and to store extra data.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_entityclass_info" data-tt-parent="p_entityclass" data-invisible="true"></div></td>
     <td colspan="3">
A chest for example uses the BlockEntity to store the inventory. A tutorial of creating your own entityclass can be found [[Block Entity|here]].
</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_behaviors" data-tt-parent="root">behaviors</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_behaviors" data-tt-parent="root">Behaviors</div></td>
     <td>array of strings</td>
     <td>array of object</td>
     <td>empty</td>
     <td>-</td>
     <td></td>
     <td>A behavior adds custom abilities such as falling block.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_behaviors_info" data-tt-parent="p_behaviors" data-invisible="true"></div></td>
     <td scope="row"><div class="tt" data-tt-id="p_behaviors_info" data-tt-parent="p_behaviors" data-invisible="true"></div></td>
     <td colspan="3">{{:json:block:behavior}}</td>
     <td colspan="3">
Here is an overview of all exisiting behaviors, if you want to create your own custom behavior you can read [[Adding Block Behavior]].
{{:json:block:behavior}}
</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_blockmaterial" data-tt-parent="root">BlockMaterial</div></td>
    <td>string</td>
    <td>-</td>
    <td>A behavior adds custom abilities such as falling block.</td>
  </tr>
  <tr>
    <td scope="row">
  <div class="tt" data-tt-id="p_blockmaterial_soil" data-tt-parent="p_blockmaterial">Soil</div><br>
  <div class="tt" data-tt-id="p_blockmaterial_gravel" data-tt-parent="p_blockmaterial">Gravel</div><br>
  <div class="tt" data-tt-id="p_blockmaterial_sand" data-tt-parent="p_blockmaterial">Sand</div><br>
  <div class="tt" data-tt-id="p_blockmaterial_wood" data-tt-parent="p_blockmaterial">Wood</div><br>
  <div class="tt" data-tt-id="p_blockmaterial_leaves" data-tt-parent="p_blockmaterial">Leaves</div><br>
  <div class="tt" data-tt-id="p_blockmaterial_stone" data-tt-parent="p_blockmaterial">Stone</div><br>
  <div class="tt" data-tt-id="p_blockmaterial_liquid" data-tt-parent="p_blockmaterial">Liquid</div><br>
  <div class="tt" data-tt-id="p_blockmaterial_snow" data-tt-parent="p_blockmaterial">Snow</div><br>
  <div class="tt" data-tt-id="p_blockmaterial_ice" data-tt-parent="p_blockmaterial">Ice</div><br>
  <div class="tt" data-tt-id="p_blockmaterial_metal" data-tt-parent="p_blockmaterial">Metal</div><br>
  <div class="tt" data-tt-id="p_blockmaterial_mantle" data-tt-parent="p_blockmaterial">Mantle</div><br>
  <div class="tt" data-tt-id="p_blockmaterial_plant" data-tt-parent="p_blockmaterial">Plant</div><br>
  <div class="tt" data-tt-id="p_blockmaterial_glass" data-tt-parent="p_blockmaterial">Glass</div><br>
  <div class="tt" data-tt-id="p_blockmaterial_ceramic" data-tt-parent="p_blockmaterial">Ceramic</div><br>
  <div class="tt" data-tt-id="p_blockmaterial_cloth" data-tt-parent="p_blockmaterial">Cloth</div><br>
  <div class="tt" data-tt-id="p_blockmaterial_lava" data-tt-parent="p_blockmaterial">Lava</div><br>
  <div class="tt" data-tt-id="p_blockmaterial_brick" data-tt-parent="p_blockmaterial">Brick</div><br>
  <div class="tt" data-tt-id="p_blockmaterial_fire" data-tt-parent="p_blockmaterial">Fire</div><br>
  <div class="tt" data-tt-id="p_blockmaterial_other" data-tt-parent="p_blockmaterial">Other</div>
</td>
    <td colspan="3" valign="top">
Materials are hardcoded and currently only used to determine mining speed with a specific tool.
</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_matterstate" data-tt-parent="root">MatterState</div></td>
    <td>array of object</td>
    <td>&quot;block&quot;</td>
    <td>Determines whether the block is in a '''''solid''''', a '''''liquid''''', a '''''gas''''' or a '''''plasma''''' state.</td>
  </tr>
  <tr>
    <td scope="row">
  <div class="tt" data-tt-id="p_matterstate_solid" data-tt-parent="p_matterstate">solid</div><br><br>
  <div class="tt" data-tt-id="p_matterstate_liquid" data-tt-parent="p_matterstate">liquid</div><br><br>
  <div class="tt" data-tt-id="p_matterstate_gas" data-tt-parent="p_matterstate">gas</div><br><br>
  <div class="tt" data-tt-id="p_matterstate_plasma" data-tt-parent="p_matterstate">plasma</div><br><br>
</td>
    <td colspan="3">
Used for special collision behavior and rendering. Currently used for:
 
Liquid:
*Lava
*Water
*Water with particles
 
Gas/Plasma:
none added yet
</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_resistance" data-tt-parent="root">Resistance</div></td>
    <td>decimal number</td>
    <td>6</td>
    <td>How long it takes to break this block in seconds (with a mining speed of 1).</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_resistance_info" data-tt-parent="p_resistance" data-invisible="true"></div></td>
    <td colspan="3">
Same examples of resistance's values used in VintageStory:
<table class="wikitable">
  <tr style="background-color: grey;">
    <th style="background-color: grey;">Block</th>
    <th style="background-color: grey;">Value</th>
  </tr>
  <tr>
    <td>'''leave'''</td>
<td>''0.5''</td>
  </tr>
  <tr>
    <td>'''wool'''</td>
<td>''1.0''</td>
  </tr>
  <tr>
    <td>'''bowl'''</td>
<td>''1.5''</td>
  </tr>
  <tr>
    <td>'''obsidian'''</td>
<td>''2''</td>
  </tr>
  <tr>
    <td>'''plank'''</td>
<td>''3.5''</td>
  </tr>
  <tr>
    <td>'''log'''</td>
<td>''4.5''</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_variantgroups" data-tt-parent="root">variantgroups</div></td>
    <td>'''rock'''</td>
     <td>arrays</td>
<td>''6''</td>
     <td></td>
  </tr>
     <td>Allows you define multiple variants of the same block.</td>
</table>
</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_requiredminingtier" data-tt-parent="root">RequiredMiningTier</div></td>
    <td>integer</td>
    <td>0</td>
    <td>Minimum required mining tier to get the drop out of the block.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_requiredminingtier_info" data-tt-parent="p_requiredminingtier" data-invisible="true"></div></td>
    <td colspan="3">
<table class="wikitable">
  <tr style="background-color: grey;">
    <th style="background-color: grey;">Tier</th>
    <th style="background-color: grey;">Ores</th>
  </tr>
  <tr>
    <td>'''1'''</td>
<td>'''''gelena''''' and '''''rocksalt_sylvite'''''</td>
  </tr>
  <tr>
    <td>'''2'''</td>
<td>'''''lignite''''', '''''cassiterite''''', '''''sphalerite''''', '''''rocksalt''''', '''''sulfur''''' and '''''nativecopper'''''</td>
  </tr>
  <tr>
    <td>'''3'''</td>
<td>'''''bituminouscoal''''', '''''quartz_nativegold''''', '''''quartz_nativesilver''''', '''''lapislazuli''''', '''''bismuthinite''''', '''''quartz''''', '''''magnetite''''' and '''''limonite'''''</td>
  </tr>
  <tr>
    <td>'''4'''</td>
<td>'''''diamond''''' and '''''emerald'''''</td>
  </tr>
  <tr>
    <td>'''5'''</td>
<td>'''''chromite''''', '''''platinum''''' and '''''ilmenite'''''</td>
  </tr>
</table>
</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_climbable" data-tt-parent="root">Climbable</div></td>
    <td>boolean</td>
    <td>false</td>
    <td>If true, walking against this block will make the player climb (used for ladders).</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_rainpermeable" data-tt-parent="root">RainPermeable</div></td>
    <td>boolean</td>
    <td>false</td>
    <td>If rain can fall through this block.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_snowcoverage" data-tt-parent="root">SnowCoverage</div></td>
    <td>boolean</td>
    <td>-</td>
    <td>Whether snow may rest on top of this block.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_snowcoverage_info" data-tt-parent="p_snowcoverage" data-invisible="true"></div></td>
    <td colspan="3">
All none solid blocks can't be covered by snow unless it's defined different:
*Leaves (also branchy): '''true''',
*Water with particles, Lakeice: '''false'''
</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_collisionbox" data-tt-parent="root">CollisionBox</div></td>
    <td>object</td>
    <td>box (0,0,0 -> 1,1,1)</td>
    <td>Defines a box with which the player collides with.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_collisionbox_info" data-tt-parent="p_collisionbox" data-invisible="true"></div></td>
    <td colspan="3">
A '''half slab''' for example, has either a box going from 0,0,0 to 1,0.5,1 or going from 0,0.5,0 to 1,1,1, depending on whether it is a slab is down or up:
<syntaxhighlight lang="json">
collisionboxByType: {
"*-down": { x1: 0, y1: 0, z1: 0,  x2: 1, y2: 0.5, z2: 1 },
"*-up": { x1: 0, y1: 0.5, z1: 0,  x2: 1, y2: 1, z2: 1 }
},
</syntaxhighlight>
 
Collision and selection boxes are most likely equal.
</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_collisionboxes" data-tt-parent="root">CollisionBoxes</div></td>
    <td>array of object</td>
    <td>-</td>
    <td>Defines multiple boxes with which the player collides with.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_collisionboxes_info" data-tt-parent="p_collisionboxes" data-invisible="true"></div></td>
    <td colspan="3">
A '''crate''' for example requires multiple collision boxes:
<syntaxhighlight lang="json">
collisionboxesByType: {
"*-opened": [
{ x1: 0, y1: 0, z1: 0, x2: 1, y2: 0.0625, z2: 1 },
{ x1: 0, y1: 0, z1: 0, x2: 1, y2: 1, z2: 0.0625 },
{ x1: 0, y1: 0, z1: 0, x2: 1, y2: 1, z2: 0.0625, rotateY: 90 },
{ x1: 0, y1: 0, z1: 0, x2: 1, y2: 1, z2: 0.0625, rotateY: 180 },
{ x1: 0, y1: 0, z1: 0, x2: 1, y2: 1, z2: 0.0625, rotateY: 270 },
]
},
</syntaxhighlight>
</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_selectionbox" data-tt-parent="root">SelectionBox</div></td>
    <td>object</td>
    <td>box (0,0,0 -> 1,1,1)</td>
    <td>Defines a box which the player's mouse pointer collides with for selection.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_selectionbox_info" data-tt-parent="p_selectionbox" data-invisible="true"></div></td>
    <td colspan="3">
A '''half slab''' for example, has either a box going from 0,0,0 to 1,0.5,1 or going from 0,0.5,0 to 1,1,1, depending on whether it is a slab is down or up:
<syntaxhighlight lang="json">
selectionboxByType: {
"*-down": { x1: 0, y1: 0, z1: 0,  x2: 1, y2: 0.5, z2: 1 },
"*-up": { x1: 0, y1: 0.5, z1: 0,  x2: 1, y2: 1, z2: 1 }
},
</syntaxhighlight>
 
Collision and selection boxes are most likely equal.
</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_selectionboxes" data-tt-parent="root">SelectionBoxes</div></td>
    <td>array of object</td>
    <td>-</td>
    <td>Defines multiple boxes which the player's mouse pointer collides with for selection.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_selectionboxes_info" data-tt-parent="p_selectionboxes" data-invisible="true"></div></td>
    <td colspan="3">
A '''crate''' for example requires multiple selection boxes:
<syntaxhighlight lang="json">
selectionboxesByType: {
"*-opened": [
{ x1: 0, y1: 0, z1: 0, x2: 1, y2: 0.0625, z2: 1 },
{ x1: 0, y1: 0, z1: 0, x2: 1, y2: 1, z2: 0.0625 },
{ x1: 0, y1: 0, z1: 0, x2: 1, y2: 1, z2: 0.0625, rotateY: 90 },
{ x1: 0, y1: 0, z1: 0, x2: 1, y2: 1, z2: 0.0625, rotateY: 180 },
{ x1: 0, y1: 0, z1: 0, x2: 1, y2: 1, z2: 0.0625, rotateY: 270 },
]
},
</syntaxhighlight>
</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_replaceable" data-tt-parent="root">Replaceable</div></td>
    <td>integer</td>
    <td>0</td>
    <td>A value usually between 0-9999 that indicates which blocks may be replaced with others.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_replaceable_info" data-tt-parent="p_replaceable" data-invisible="true"></div></td>
    <td colspan="3">
<table class="wikitable">
  <tr style="background-color: grey;">
    <th style="background-color: grey;">Value</th>
    <th style="background-color: grey;">Effect (Blocks)</th>
  </tr>
  <tr>
    <td>'''0'''</td>
<td>'''''ordinary blocks''''' (stone for example)</td>
  </tr>
  <tr>
    <td>'''5000'''</td>
<td>Everything equal or above will be washed away by water (such as '''''Fruit''''').</td>
  </tr>
  <tr>
    <td>'''6000'''</td>
<td>Everything equal or above wwill replaced when the player tries to place a block (such as '''''Tallgrass''''').</td>
  </tr>
  <tr>
    <td>'''9000'''</td>
<td>'''''Lava'''''</td>
  </tr>
  <tr>
    <td>'''9500'''</td>
<td>'''''Water'''''</td>
  </tr>
  <tr>
    <td>'''9999'''</td>
<td>'''''Air'''''</td>
  </tr>
</table>
</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_fertility" data-tt-parent="root">Fertility</div></td>
    <td>integer</td>
    <td>0</td>
    <td>Which plants can grow on top of this block.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_fertility_info" data-tt-parent="p_fertility" data-invisible="true"></div></td>
    <td colspan="3">
<table class="wikitable">
  <tr style="background-color: grey;">
    <th style="background-color: grey;">Value</th>
    <th style="background-color: grey;">Effect</th>
  </tr>
  <tr>
    <td>'''0'''</td>
<td>''nothing can grow.''</td>
  </tr>
  <tr>
    <td>'''10'''</td>
<td>''some tallgrass and small trees can be grow on it.''</td>
  </tr>
  <tr>
    <td>'''100'''</td>
<td>''all grass and trees can grow on it.''</td>
  </tr>
</table>
</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_glowlevel" data-tt-parent="root">GlowLevel</div></td>
    <td>0 ... 255</td>
    <td>0</td>
    <td>Causes the block to visually glow if Bloom is enabled. Basic glow level for all the blocks model elements.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_glowlevel_info" data-tt-parent="p_glowlevel" data-invisible="true"></div></td>
    <td colspan="3">
<table class="wikitable">
  <tr style="background-color: grey;">
    <th style="background-color: grey;">Blocks</th>
    <th style="background-color: grey;">Value</th>
  </tr>
  <tr>
    <td>''Glacierice''</td>
<td>'''8'''</td>
  </tr>
  <tr>
    <td>''Paperlantern''</td>
<td>'''32'''</td>
  </tr>
  <tr>
    <td>''Ember''</td>
<td>'''48'''</td>
  </tr>
  <tr>
    <td>''Fire'', ''Firepit'', ''Oillamp'', ''Torch''</td>
<td>'''64'''</td>
  </tr>
  <tr>
    <td>''Lava''</td>
<td>'''128'''</td>
  </tr>
</table>
</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_lightabsorption" data-tt-parent="root">LightAbsorption</div></td>
    <td>0 ... 32</td>
    <td>0</td>
    <td>For light blocking blocks. Any value above 32 will completely block all light.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_walkspeedmultiplier" data-tt-parent="root">WalkspeedMultiplier</div></td>
    <td>decimal number</td>
    <td>1.0</td>
    <td>Percentage walk-speed when standing on or inside this block.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_walkspeedmultiplier_info" data-tt-parent="p_walkspeedmultiplier" data-invisible="true"></div></td>
    <td colspan="3">
<table class="wikitable">
  <tr style="background-color: grey;">
    <th style="background-color: grey;">Blocks</th>
    <th style="background-color: grey;">Value</th>
  </tr>
  <tr>
    <td>''Spiderweb''</td>
<td>'''0.25'''</td>
  </tr>
  <tr>
    <td>''Stonepath''</td>
<td>'''1.15'''</td>
  </tr>
</table>
</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_dragmultiplier" data-tt-parent="root">DragMultiplier</div></td>
    <td>decimal number</td>
    <td>1.0</td>
    <td>Drag multiplier applied to entities standing on it (slipperiness factor).</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_dragmultiplier_info" data-tt-parent="p_dragmultiplier" data-invisible="true"></div></td>
    <td colspan="3">
<table class="wikitable">
  <tr style="background-color: grey;">
    <th style="background-color: grey;">Blocks</th>
    <th style="background-color: grey;">Value</th>
  </tr>
  <tr>
    <td>''Glacierice'', ''Lakeice''</td>
<td>'''0.02'''</td>
  </tr>
</table>
</td>
  </tr>
  <tr>
     <td scope="row"><div class="tt" data-tt-id="p_drops" data-tt-parent="root">Drops</div></td>
    <td>array of object</td>
    <td>-</td>
    <td>The items that should drop from breaking this block.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_drops_info" data-tt-parent="p_drops" data-invisible="true"></div></td>
    <td colspan="3">
 
'''Drop itself'''
 
If this property does not exist the block will drop itself.
 
----
 
'''No drop'''
 
A '''firepit''' for example doesn't drop anything. You can do so if you specify an empty array:
<syntaxhighlight lang="json">
drops: [],
</syntaxhighlight>
 
----
 
'''Special drop'''
 
You can also specify a special item/ block. Therefore you need to define an '''ItemStack''', with the given properties:
 
<table class="wikitable">
  <tr style="background-color: grey;">
    <th style="background-color: grey;">Property</th>
    <th style="background-color: grey;">Default</th>
<th style="background-color: grey;">Explanation</th>
  </tr>
  <tr>
    <td>'''type'''</td>
<td>''block''</td>
<td>Can either be '''''block''''' or '''''item'''''.</td>
  </tr>
  <tr>
    <td>'''code''' (required)</td>
<td>-</td>
<td>The complete code (can also include domain) of the item or block.</td>
  </tr>
  <tr>
    <td>'''lastdrop'''</td>
<td>false</td>
<td>If true and the quantity dropped is >=1 any subsequent drop in the list will be ignored.</td>
  </tr>
  <tr>
    <td>'''attributes'''</td>
<td>-</td>
<td>Tree Attributes that will be attached to the resulting itemstack.</td>
  </tr>
  <tr>
    <td>'''tool'''</td>
<td>-</td>
<td>If specified then given tool is required to break this block.</td>
  </tr>
  <tr>
    <td>'''quantity'''</td>
<td>- (one)</td>
<td>Determines the quantity of items which will be dropped.</td>
  </tr>
</table>
 
For example, the drop of a '''charcoalpile''' looks like this:
 
<syntaxhighlight lang="json">
drops: [
{ type: "item", code: "charcoal" }
],
</syntaxhighlight>
 
'''Tallgrass''' will only drop something if it's mined by a knife:
 
<syntaxhighlight lang="json">
drops: [
{ type: "item", code: "drygrass", tool: "knife"  },
],
</syntaxhighlight>
 
----
 
'''Chance drops'''
 
Let's take a look at an example. This is the drop property of rock:
 
<syntaxhighlight lang="json">
drops: [
{
type: "item",
code: "stone-{rock}",
quantity: { avg: 2.5, var: 0.5 }
},
]
</syntaxhighlight>
 
This will drop 2-3 blocks.
 
'''''avg''''': Stands for the default drop quantity. If var is 0 or not specified it will always drop the given average.
 
'''''var''''': How much the drop rate can vary. Meaning the drop rate can be <code>avg - var</code> at minimum and <code>age + var</code> at maximum.
 
Furthermore you can also switch between different distribution modes using the '''''dist''''' property.
 
<table class="wikitable mw-collapsible mw-collapsed">
  <tr>
<th colspan="2">Overview - Distribution modes</th>
  </tr>
  <tr style="background-color: grey;">
    <th style="background-color: grey;">Name</th>
<th style="background-color: grey;">Explanation</th>
  </tr>
  <tr>
    <td>'''uniform'''</td>
<td>''Select completely random numbers within avg-var until avg+var.''</td>
  </tr>
  <tr>
    <td>'''triangle'''</td>
<td>''Select random numbers with numbers near avg being the most commonly selected ones, following a triangle curve.''</td>
  </tr>
  <tr>
    <td>'''gaussian'''</td>
<td>''Select random numbers with numbers near avg being the most commonly selected ones, following a gaussian curve.''</td>
  </tr>
  <tr>
    <td>'''narrowgaussian'''</td>
<td>''Select random numbers with numbers near avg being the most commonly selected ones, following a narrow gaussian curve.''</td>
  </tr>
  <tr>
    <td>'''inversegaussian'''</td>
<td>''Select random numbers with numbers near avg being the least commonly selected ones, following an upside down gaussian curve.''</td>
  </tr>
  <tr>
    <td>'''narrowinversegaussian'''</td>
<td>''Select random numbers with numbers near avg being the least commonly selected ones, following an upside down gaussian curve.''</td>
  </tr>
  <tr>
    <td>'''invexp'''</td>
<td>''Select numbers in the form of avg + var, wheras low value of var are preferred.''</td>
  </tr>
  <tr>
     <td>'''stronginvexp'''</td>
<td>''Select numbers in the form of avg + var, wheras low value of var are strongly preferred.''</td>
  </tr>
  <tr>
     <td>'''strongerinvexp'''</td>
<td>''Select numbers in the form of avg + var, wheras low value of var are very strongly preferred.''</td>
  </tr>
<tr>
     <td>'''dirac'''</td>
<td>''Select completely random numbers within avg-var until avg+var only ONCE and then always 0.''</td>
  </tr>
</table>
 
----
'''Multiple Drops'''
 
Of course you can also define multiple drops at once. '''Sapling''' can drop a sapling and a stick:
 
<syntaxhighlight lang="json">
drops: [
{
type: "block",
code: "sapling-{wood}",
quantity: { avg: 0.02, var: 0 },
},
{
type: "item",
code: "stick",
quantity: { avg: 0.02, var: 0 },
}
],
</syntaxhighlight>
 
----
 
'''Last Drop'''
 
In order to add a special drop, which (if dropped) prevents all other drops, you can use the lastDrop property:
 
<syntaxhighlight lang="json">
dropsByType: {
"ore-quartz-*": [
{ type: "item", code: "clearquartz",  quantity: { avg: 0.2, var: 0 }, lastDrop: true },
{ type: "item", code: "ore-{ore}",  quantity: { avg: 1.25, var: 0 }  }
],
"*": [
{ type: "item", code: "ore-{ore}",  quantity: { avg: 1.25, var: 0 }  }
],
}
</syntaxhighlight>
 
Quartz ore will drop with a 20% chance clearquartz, if not it will drop the regular ore. If lastDrop wouldn't be true it could drop both at the same time.
</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_particleproperties" data-tt-parent="root">ParticleProperties</div></td>
    <td>array of object</td>
    <td>-</td>
    <td>Particles that should spawn in regular intervals from this block.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_particleproperties_info" data-tt-parent="p_particleproperties" data-invisible="true"></div></td>
    <td colspan="3">
{{:json:block:particle}}
</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_liquidlevel" data-tt-parent="root">LiquidLevel</div></td>
    <td>0 ... 7</td>
    <td>0</td>
    <td>Value between 0...7 for Liquids to determine the height of the liquid.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_cropprops" data-tt-parent="root">CropProps</div></td>
    <td>object</td>
    <td>-</td>
    <td>Information about the block as a crop.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_sounds" data-tt-parent="root">Sounds</div></td>
    <td>key: string, value: string</td>
    <td>-</td>
    <td>The sounds played for this block during step, break, build and walk.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_sounds_walk" data-tt-parent="p_sounds">Walk</div></td>
    <td colspan="3">An entity walks over it.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_sounds_inside" data-tt-parent="p_sounds">Inside</div></td>
    <td colspan="3">The player is inside the block.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_sounds_break" data-tt-parent="p_sounds">Break</div></td>
    <td colspan="3">Breaking the block.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_sounds_place" data-tt-parent="p_sounds">Place</div></td>
    <td colspan="3">Placing the block.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_sounds_hit" data-tt-parent="p_sounds">Hit</div></td>
    <td colspan="3">While mining the block.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_blockmaterial" data-tt-parent="root">blockmaterial</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_sounds_ambient" data-tt-parent="p_sounds">Ambient</div></td>
     <td>string</td>
     <td colspan="3">Played from time to time if the player is close to it.</td>
    <td></td>
    <td>The blocks material. Amongst others, it will determine how quickly a specific tool can mine it.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_blockmaterial_info" data-tt-parent="p_blockmaterial" data-invisible="true"></div></td>
     <td scope="row"><div class="tt" data-tt-id="p_sounds_info" data-tt-parent="p_sounds" data-invisible="true"></div></td>
     <td colspan="3">{{:json:block:material}}</td>
     <td colspan="3">
'''Anvil''':
<syntaxhighlight lang="json">
    sounds: {
        "place": "block/anvil",
        "break": "block/anvil"
    }
</syntaxhighlight>
 
'''Rails''':
<syntaxhighlight lang="json">
    sounds: {
        place": "block/planks",
        "walk": "walk/wood"
    }
</syntaxhighlight>
 
'''Water''':
<syntaxhighlight lang="json">
    sounds: {
        place: "block/water",
        inside: "walk/water",
        ambient: "environment/creek"
    },
</syntaxhighlight>
</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_resistance" data-tt-parent="root">resistance</div></td>
     <td colspan="4" style='font-size: 14pt; border-bottom: 2pt solid black; padding-left: 100px;'><b>Common</b></td>
    <td></td>
    <td></td>
    <td>How many seconds it takes to break the block (excluding speed mining bonus). Decimal numbers are allowed.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_creativeinventory" data-tt-parent="root">creativeinventory</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_creativeinventory" data-tt-parent="root">CreativeInventory</div></td>
     <td>arrays</td>
     <td>key: string, value: string[]</td>
     <td></td>
     <td>-</td>
     <td>In which creative inventory tabs the block should be visible in.</td>
     <td>In which creative inventory tabs the block should be visible in.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td colspan="4" style='font-size: 14pt; border-bottom: 2pt solid black; padding-left: 100px;'><b>Rendering</b></td>
    <td scope="row"><div class="tt" data-tt-id="p_creativeinventory_info" data-tt-parent="p_creativeinventory" data-invisible="true"></div></td>
     <td colspan="3">
There are several tabs to you can add your stuff. Note that general should always be included, since it should contain everything.
 
*general
*terrain
*flora
*construction
*decorative
*items
 
'''Rock''' adds all of it's variantions to general, terrain and construction:
<syntaxhighlight lang="json">
creativeinventory: { "general": ["*"], "terrain": ["*"], "construction": ["*"] },
</syntaxhighlight>
 
'''<code>*</code>''' reprents the variants which will be added. You can specify multiple and separate them with a comma. It follows the same way as the '''byType''' property.
 
A '''Torch''' on the other hand only adds the variation '''<code>up</code>''':
<syntaxhighlight lang="json">
creativeinventory: { "general": ["*-up"], "decorative": ["*-up"] },
</syntaxhighlight>
</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_maxstacksize" data-tt-parent="root">MaxStackSize</div></td>
    <td>integer</td>
    <td>64</td>
    <td>Determines the maximum amount you can stack the block in one slot.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_attackpower" data-tt-parent="root">AttackPower</div></td>
    <td>decimal number</td>
    <td>0.5</td>
    <td>The damage the deals when hitting an entity.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_attackrange" data-tt-parent="root">AttackRange</div></td>
    <td>decimal number</td>
    <td>1.5</td>
    <td>The maximum distance you can hit an entity.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_materialdensity" data-tt-parent="root">MaterialDensity</div></td>
    <td>integer</td>
    <td>9999</td>
    <td>Determines on whether an object floats on liquids or not.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_materialdensity_info" data-tt-parent="p_materialdensity" data-invisible="true"></div></td>
    <td colspan="3">
Water has a density of 1000, meaning everything below or equal will float on water. The same goes for lava which has a density of 5000.
</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_liquidselectable" data-tt-parent="root">LiquidSelectable</div></td>
    <td>boolean</td>
    <td>false</td>
    <td>If the block can select a liquid while holding it in hand.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_liquidselectable_info" data-tt-parent="p_liquidselectable" data-invisible="true"></div></td>
    <td colspan="3">
Used for buckets in order to fill it with water and to place waterlily on top of water.
</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_renderpass" data-tt-parent="root">renderpass</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_miningspeed" data-tt-parent="root">MiningSpeed</div></td>
     <td>string (of enum)</td>
     <td>key: string, value: decimal number</td>
     <td>opaque</td>
     <td>-</td>
     <td>Determines how the block will be drawn.</td>
     <td>The mining speed for each material.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_opaque" data-tt-parent="p_renderpass">opaque</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_miningspeed" data-tt-parent="root">MiningTier</div></td>
     <td></td>
     <td>integer</td>
     <td>0</td>
     <td>0</td>
     <td>Used for solid blocks with no half transparency.</td>
     <td>Determines which blocks it can break. If the required miningtier is above the defined one there will be no drop from it.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_attributes" data-tt-parent="root">Attributes</div></td>
    <td>key: string, value: object</td>
    <td>-</td>
    <td>Custom Attributes associated with this block.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_attributes_info" data-tt-parent="p_attributes" data-invisible="true"></div></td>
    <td colspan="3">
Extra attributes added to a block. Those are final and cannot be modified. It's a good way to keep things organized and and modifiable. The '''oreblastingbomb''' for example has attributes, which define its radius and type. These can be used by behaviors and blockentities:
<syntaxhighlight lang="json">
    attributes: {
"blastRadius": 4,
"blastType": 0,
},
</syntaxhighlight>
</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_combustibleprops" data-tt-parent="root">CombustibleProps</div></td>
    <td>object</td>
    <td>-</td>
    <td>Information about the blocks burnable states.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_burntemperature" data-tt-parent="p_combustibleprops">BurnTemperature</div></td>
    <td>integer</td>
    <td>-</td>
    <td>The temperature at which it burns in degrees Celsius.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_burnduration" data-tt-parent="p_combustibleprops">BurnDuration</div></td>
    <td>decimal number</td>
    <td>-</td>
    <td>For how long it burns in seconds.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_heatresistance" data-tt-parent="p_combustibleprops">HeatResistance</div></td>
    <td>integer</td>
    <td>500</td>
    <td>How many degrees celsius it can resists before it ignites (not implemented yet).</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_meltingpoint" data-tt-parent="p_combustibleprops">MeltingPoint</div></td>
    <td>integer</td>
    <td>-</td>
    <td>How many degrees celsius it takes to smelt/transform this into another. Only used when put in a stove and SmeltedStack is set.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_meltingduration" data-tt-parent="p_combustibleprops">MeltingDuration</div></td>
    <td>decimal number</td>
    <td>-</td>
    <td>For how many seconds the temperature has to be above the melting point until the item is smelted.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_smokelevel" data-tt-parent="p_combustibleprops">SmokeLevel</div></td>
    <td>decimal number</td>
    <td>1</td>
    <td>How much smoke this item produces when being used as fuel.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_opaquenocull" data-tt-parent="p_renderpass">opaquenocull</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_smeltedratio" data-tt-parent="p_combustibleprops">SmeltedRatio</div></td>
     <td></td>
     <td>integer</td>
     <td>1</td>
     <td>1</td>
     <td>Used for non-solid single faced blocks, such as tall grass.</td>
     <td>How many ores are required to produce one output stack.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_transparent" data-tt-parent="p_renderpass">transparent</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_liquidlevel" data-tt-parent="p_combustibleprops">SmeltedStack</div></td>
     <td></td>
     <td>object</td>
     <td>2</td>
     <td>-</td>
     <td>Use for solid halftransparent blocks, such as glass</td>
     <td>If set, the block/item is smeltable in a furnace and this is the resulting itemstack once the MeltingPoint has been reached for the supplied duration.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_liquid" data-tt-parent="p_renderpass">liquid</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_requirescontainer" data-tt-parent="p_combustibleprops">RequiresContainer</div></td>
     <td></td>
     <td>boolean</td>
     <td>3</td>
     <td>true</td>
     <td>Used for liquids, produces waves.</td>
     <td>If set to true, the block/item requires a smelting/cooking/baking container such as the Crucible. If false, it can be directly baked/melted without smelting/cooking/baking container.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_topsoil" data-tt-parent="p_renderpass">topsoil</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_combustibleprops_info" data-tt-parent="p_combustibleprops" data-invisible="true"></div></td>
     <td></td>
     <td colspan="3">
     <td>4</td>
This property can be used to define a burning material. '''Plank''' for example can get on fire:
     <td>Used for grass covered blocks. Allows for a smooth transition from grass to soil, while still allowing climate tinting of grass.</td>
<syntaxhighlight lang="json">
     combustibleProps: {
        burnTemperature: 800,
        burnDuration: 12,
    },
</syntaxhighlight>
 
Furthermore it can be used to define smelting processes. An example would be an '''ingotmold''' which turns into an ingotmold-burned:
<syntaxhighlight lang="json">
     combustiblePropsByType: {
        "ingotmold-raw": {
            meltingPoint: 600,
            meltingDuration: 30,
            smeltedRatio: 1,
            smeltedStack: { type: "block", code: "ingotmold-burned" },
            requiresContainer: false
        }
    },
</syntaxhighlight>
</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_shape" data-tt-parent="root">shape</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_nutritionprops" data-tt-parent="root">NutritionProps</div></td>
     <td>shape</td>
     <td>object</td>
     <td></td>
     <td>-</td>
     <td>For the json drawtype, the shape definition of the block as shown in the world, dropped on the ground or held in hand.</td>
     <td>Information about the blocks nutrients.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_base" data-tt-parent="p_shape">base</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_nutritionprops_foodcategory" data-tt-parent="p_nutritionprops">FoodCategory</div></td>
     <td></td>
     <td>string</td>
     <td></td>
     <td>-</td>
     <td>The path to the shape json file, the base dir is ''assets/shapes/''.</td>
     <td>Defines the type of food. It can be '''''fruit''''', '''''vegetable''''', '''''protein''''', '''''grain''''' and '''''dairy'''''.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_rotateX" data-tt-parent="p_shape">rotateX</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_nutritionprops_saturation" data-tt-parent="p_nutritionprops">Saturation</div></td>
     <td>float</td>
     <td>decimal number</td>
     <td>0</td>
     <td>0</td>
     <td></td>
     <td>How much saturation it can restore.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_rotateY" data-tt-parent="p_shape">rotateY</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_nutritionprops_health" data-tt-parent="p_nutritionprops">Health</div></td>
     <td>float</td>
     <td>decimal number</td>
     <td>0</td>
     <td>0</td>
    <td>How much health it can restore.</td>
  </tr>
  <tr>
    <td colspan="4" style='font-size: 14pt; border-bottom: 2pt solid black; padding-left: 100px;'><b>Rendering</b></td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_textures" data-tt-parent="root">Textures</div></td>
    <td>key: string, value: object</td>
     <td></td>
     <td></td>
    <td>The texture definitions for the block as seen in the world, when dropped on the ground or held in the hand.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_rotateZ" data-tt-parent="p_shape">rotateZ</div></td>
     <td scope="row" valign="top"><div class="tt" data-tt-id="p_textures_base" data-tt-parent="p_textures">base</div><br><br><div class="tt" data-tt-id="p_textures_overlays" data-tt-parent="p_textures">overlays</div><br><br><div class="tt" data-tt-id="p_textures_base" data-tt-parent="p_textures">alternates</div></td>
     <td>float</td>
     <td colspan="3">{{:json:block:texture}}</td>
     <td>0</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_texturesinventory" data-tt-parent="root">TexturesInventory</div></td>
     <td>key: string, value: object</td>
     <td></td>
     <td></td>
    <td>The texture definitions for the block as seen in the player inventory. Overrides the textures.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_shapeinventory" data-tt-parent="root">shapeinventory</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_shape" data-tt-parent="root">Shape</div></td>
     <td>shape</td>
     <td>object</td>
     <td></td>
     <td>-</td>
     <td>For the json drawtype, the shape definition of the block as shown in the players inventory.</td>
     <td>For the json drawtype, the shape definition of the block as shown in the world, dropped on the ground or held in hand.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_invbase" data-tt-parent="p_shapeinventory">base</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_base" data-tt-parent="p_shape">base</div></td>
     <td></td>
     <td></td>
     <td></td>
     <td></td>
Line 162: Line 1,168:
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_invrotateX" data-tt-parent="p_shapeinventory">rotateX</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_rotateX" data-tt-parent="p_shape">rotateX</div></td>
     <td>float</td>
     <td>float</td>
     <td>0</td>
     <td>0</td>
     <td></td>
     <td>Only 90 degree rotations are possible.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_invrotateY" data-tt-parent="p_shapeinventory">rotateY</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_rotateY" data-tt-parent="p_shape">rotateY</div></td>
     <td>float</td>
     <td>float</td>
     <td>0</td>
     <td>0</td>
     <td></td>
     <td>Only 90 degree rotations are possible.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_invrotateZ" data-tt-parent="p_shapeinventory">rotateZ</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_rotateZ" data-tt-parent="p_shape">rotateZ</div></td>
     <td>float</td>
     <td>float</td>
     <td>0</td>
     <td>0</td>
     <td></td>
     <td>Only 90 degree rotations are possible.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_shapebytype" data-tt-parent="root">shapebytype</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_shapeinventory" data-tt-parent="root">ShapeInventory</div></td>
     <td>key: string, value: shape</td>
     <td>object</td>
     <td></td>
     <td>-</td>
     <td>When defining multiple block variants, use this property to selectively choose the shape of a variant.</td>
     <td>For the json drawtype, the shape definition of the block as shown in the players inventory.</td>
   </tr>
   </tr>
  <tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_ambientocclusion" data-tt-parent="root">ambientocclusion</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_drawtype" data-tt-parent="root">DrawType</div></td>
    <td>boolean</td>
     <td>string</td>
    <td>true</td>
     <td>&quot;cube&quot;</td>
    <td>If ambient occlusion will be applied to the block.</td>
     <td>Determines how the block is tesselated, select JSON for being able to use custom JSON Models. The other values are hardcoded methods of tesselating the block.</td>
  </tr>
  <tr>
     <td scope="row"><div class="tt" data-tt-id="p_drawtype" data-tt-parent="root" hide="children">drawtype</div></td>
     <td>string (of enum)</td>
     <td>cube</td>
     <td>Determines how the block is tesselated, select JSON for being able to use custom JSON Models. The other values are hardcoded methods of tesselating the block. Check [[Drawtypes]] for a full list.</td>
   </tr>
   </tr>
   <tr>
   <tr>
Line 282: Line 1,282:
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_textures" data-tt-parent="root">textures</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_renderpass" data-tt-parent="root">RenderPass</div></td>
     <td>key: direction, value: texture</td>
     <td>string</td>
    <td>&quot;opaque&quot;</td>
    <td>Determines how the block will be drawn.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_opaque" data-tt-parent="p_renderpass">opaque</div></td>
     <td></td>
     <td></td>
     <td>The texture definitions for the block as seen in the world, when dropped on the ground or held in the hand.</td>
     <td>0</td>
    <td>Used for solid blocks with no half transparency.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row" valign="top"><div class="tt" data-tt-id="p_textures_base" data-tt-parent="p_textures">base</div><br><br><div class="tt" data-tt-id="p_textures_overlays" data-tt-parent="p_textures">overlays</div><br><br><div class="tt" data-tt-id="p_textures_base" data-tt-parent="p_textures">alternates</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_opaquenocull" data-tt-parent="p_renderpass">opaquenocull</div></td>
     <td colspan="3">{{:json:block:texture}}</td>
    <td></td>
    <td>1</td>
     <td>Used for non-solid single faced blocks, such as tall grass.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_texturesinventory" data-tt-parent="root">texturesinventory</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_transparent" data-tt-parent="p_renderpass">transparent</div></td>
    <td>key: direction, value: texture</td>
     <td></td>
     <td></td>
     <td>The texture definitions for the block as seen in the player inventory. Overrides the textures definition if set.</td>
     <td>2</td>
    <td>Use for solid halftransparent blocks, such as glass</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_texturesbytype" data-tt-parent="root">texturesbytype</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_liquid" data-tt-parent="p_renderpass">liquid</div></td>
    <td>key: string -> direction, value: texture</td>
     <td></td>
     <td></td>
     <td>When defining multiple block variants, use this property to selectively choose the textures of a variant.</td>
     <td>3</td>
    <td>Used for liquids, produces waves.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_texturesinventorybytype" data-tt-parent="root">texturesinventorybytype</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_topsoil" data-tt-parent="p_renderpass">topsoil</div></td>
    <td>key: string -> direction, value: texture</td>
     <td></td>
     <td></td>
     <td>When defining multiple block variants, use this property to selectively choose the inventory textures of a variant.</td>
     <td>4</td>
    <td>Used for grass covered blocks. Allows for a smooth transition from grass to soil, while still allowing climate tinting of grass.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_sideopaque" data-tt-parent="root">sideopaque</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_ambientocclusion" data-tt-parent="root">AmbientOcclusion</div></td>
     <td>key: direction, value: boolean</td>
     <td>boolean</td>
     <td>true</td>
     <td>true</td>
    <td>If ambient occlusion will be applied to the block.</td>
  </tr>
<tr>
    <td scope="row"><div class="tt" data-tt-id="p_tintindex" data-tt-parent="root">TintIndex</div></td>
    <td>integer</td>
    <td>0</td>
    <td>'''''0''''' for no tint, '''''1''''' for plant climate tint, '''''2''''' for water climate tint.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_renderflags" data-tt-parent="root">RenderFlags</div></td>
    <td>0 ... 255</td>
    <td>0</td>
    <td>8 bits that are sent to the graphics card for each vertex of the blocks shape. The lower 3 bits are currently used for altering the vertexes z-depth to fix a bunch of z-fighting issues.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_facecullmode" data-tt-parent="root">FaceCullMode</div></td>
    <td>string</td>
    <td>&quot;default&quot;</td>
    <td>Determines which sides of the blocks should be rendered.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_facecullmode_default" data-tt-parent="p_facecullmode">Default</div></td>
    <td></td>
    <td>0</td>
    <td>Culls faces if they are opaque faces adjacent to opaque faces.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_facecullmode_default" data-tt-parent="p_facecullmode">NeverCull</div></td>
    <td></td>
    <td>1</td>
    <td>Never culls any faces.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_facecullmode_default" data-tt-parent="p_facecullmode">Merge</div></td>
    <td></td>
    <td>2</td>
    <td>Culls all faces that are adjacent to opaque faces and faces adjacent to blocks of the same id (Example usage: Ice blocks).</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_facecullmode_default" data-tt-parent="p_facecullmode">Collapse</div></td>
    <td></td>
    <td>3</td>
    <td>Culls all faces that are adjacent to opaque faces and the bottom, east or south faces adjacent to blocks of the same id. This causes to still leave one single face in between instead of 2, eliminating any z-fighting.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_facecullmode_default" data-tt-parent="p_facecullmode">MergeMaterial</div></td>
    <td></td>
    <td>4</td>
    <td>Same as Merge but checks for equal material (Example usage: Plain glass and all colored glass blocks).</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_facecullmode_default" data-tt-parent="p_facecullmode">CollapseMaterial</div></td>
    <td></td>
    <td>5</td>
    <td>Same as Collapse but checks for equal material (Example usage: All leaves blocks).</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_facecullmode_default" data-tt-parent="p_facecullmode">Liquid</div></td>
    <td></td>
    <td>6</td>
    <td>Same as CollapseMaterial but also culls faces towards opaque blocks.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_sideopaque" data-tt-parent="root">SideOpaque</div></td>
    <td>key: string, value: boolean</td>
    <td>-</td>
     <td>Determines if given block face is fully opaque. If yes, the opposite face of the adjacent block will not be drawn for efficiency reasons.</td>
     <td>Determines if given block face is fully opaque. If yes, the opposite face of the adjacent block will not be drawn for efficiency reasons.</td>
   </tr>
   </tr>
Line 318: Line 1,392:
     <td scope="row">
     <td scope="row">
         <div class="tt" data-tt-id="p_sideopaque_all" data-tt-parent="p_sideopaque">all</div><br>
         <div class="tt" data-tt-id="p_sideopaque_all" data-tt-parent="p_sideopaque">all</div><br>
<div class="tt" data-tt-id="p_sideopaque_horizontals" data-tt-parent="p_sideopaque">horizontals</div><br>
<div class="tt" data-tt-id="p_sideopaque_verticals" data-tt-parent="p_sideopaque">verticals</div><br>
         <div class="tt" data-tt-id="p_sideopaque_east" data-tt-parent="p_sideopaque">east</div><br>
         <div class="tt" data-tt-id="p_sideopaque_east" data-tt-parent="p_sideopaque">east</div><br>
         <div class="tt" data-tt-id="p_sideopaque_west" data-tt-parent="p_sideopaque">west</div><br>
         <div class="tt" data-tt-id="p_sideopaque_west" data-tt-parent="p_sideopaque">west</div><br>
Line 330: Line 1,406:
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_sidesolid" data-tt-parent="root">sidesolid</div></td>
    <td scope="row"><div class="tt" data-tt-id="p_sideao" data-tt-parent="root">SideAo</div></td>
     <td>key: direction, value: boolean</td>
    <td>key: string, value: boolean</td>
     <td>true</td>
    <td>-</td>
     <td>Determins if given block side is solid. If true, other blocks like torches can be attached to it</td>
    <td>If AmbientOcclusion will be applied for each side.</td>
  </tr>
  <tr>
    <td scope="row">
        <div class="tt" data-tt-id="p_sideao_all" data-tt-parent="p_sideao">all</div><br>
<div class="tt" data-tt-id="p_sideao_horizontals" data-tt-parent="p_sideao">horizontals</div><br>
<div class="tt" data-tt-id="p_sideao_verticals" data-tt-parent="p_sideao">verticals</div><br>
        <div class="tt" data-tt-id="p_sideao_east" data-tt-parent="p_sideao">east</div><br>
        <div class="tt" data-tt-id="p_sideao_west" data-tt-parent="p_sideao">west</div><br>
        <div class="tt" data-tt-id="p_sideao_up" data-tt-parent="p_sideao">up</div><br>
        <div class="tt" data-tt-id="p_sideao_down" data-tt-parent="p_sideao">down</div><br>
        <div class="tt" data-tt-id="p_sideao_north" data-tt-parent="p_sideao">north</div><br>
        <div class="tt" data-tt-id="p_sideao_south" data-tt-parent="p_sideao">south</div>
    </td>
    <td></td>
    <td></td>
    <td></td>
  </tr>
  <tr>
     <td scope="row"><div class="tt" data-tt-id="p_sidesolid" data-tt-parent="root">SideSolid</div></td>
     <td>key: string, value: boolean</td>
     <td>-</td>
     <td>Determins if given block side is solid. If true, other blocks like torches can be attached to it.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row">
     <td scope="row">
         <div class="tt" data-tt-id="p_sidesolid_all" data-tt-parent="p_sidesolid">all</div><br>
         <div class="tt" data-tt-id="p_sidesolid_all" data-tt-parent="p_sidesolid">all</div><br>
<div class="tt" data-tt-id="p_sidesolid_horizontals" data-tt-parent="p_sidesolid">horizontals</div><br>
<div class="tt" data-tt-id="p_sidesolid_verticals" data-tt-parent="p_sidesolid">verticals</div><br>
         <div class="tt" data-tt-id="p_sidesolid_east" data-tt-parent="p_sidesolid">east</div><br>
         <div class="tt" data-tt-id="p_sidesolid_east" data-tt-parent="p_sidesolid">east</div><br>
         <div class="tt" data-tt-id="p_sidesolid_west" data-tt-parent="p_sidesolid">west</div><br>
         <div class="tt" data-tt-id="p_sidesolid_west" data-tt-parent="p_sidesolid">west</div><br>
Line 350: Line 1,450:
   </tr>
   </tr>
   <tr>
   <tr>
     <td colspan="4" style='font-size: 14pt; border-bottom: 2pt solid black; padding-left: 100px;'><b>Sound</b></td>
     <td scope="row"><div class="tt" data-tt-id="p_randomdrawoffset" data-tt-parent="root">RandomDrawOffset</div></td>
    <td>boolean</td>
    <td>false</td>
    <td>If true then the block will be randomly offseted by 1/3 of a block when placed.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_lighthsv" data-tt-parent="root">LightHsv</div></td>
    <td>byte array with 3 elements. See http://tyron.at/vs/vslightwheel.html for valid values</td>
    <td>-</td>
    <td>For light emitting blocks: hue, saturation and brightness value.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_lightabsorption" data-tt-parent="root">LightAbsorption</div></td>
    <td>0 ... 255</td>
    <td>99</td>
    <td>For light blocking blocks. Any value above 32 will completely block all light.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_sounds" data-tt-parent="root">sounds</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_guitransform" data-tt-parent="root">GuiTransform</div></td>
     <td>key: string, value: string</td>
     <td>object</td>
     <td></td>
    <td>block default</td>
     <td>The sounds to be played when a player interacts with this block.</td>
    <td>Used for scaling, rotation or offseting the block when rendered in guis.</td>
  </tr>
  <tr>
    <td scope="row"><div class="tt" data-tt-id="p_fphandtransform" data-tt-parent="root">FpHandTransform</div></td>
    <td>object</td>
     <td>block default</td>
     <td>Used for scaling, rotation or offseting the block when rendered in the first person mode hand.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_place" data-tt-parent="p_sounds">place</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_tphandtransform" data-tt-parent="root">TpHandTransform</div></td>
     <td></td>
     <td>object</td>
     <td>player/build</td>
     <td>block default</td>
     <td>Sound to played when placing this block.</td>
     <td>Used for scaling, rotation or offseting the block when rendered in the third person mode hand.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_walk" data-tt-parent="p_sounds">walk</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_groundtransform" data-tt-parent="root">GroundTransform</div></td>
     <td></td>
     <td>object</td>
     <td>walk/default</td>
     <td>block default</td>
     <td>Sound to played when walking on this block.</td>
     <td>Used for scaling, rotation or offseting the rendered as a dropped item on the ground.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_break" data-tt-parent="p_sounds">break</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_randomizeaxes" data-tt-parent="root">RandomizeAxes</div></td>
     <td></td>
     <td>string</td>
     <td>player/destruct</td>
     <td>&quot;xyz&quot;</td>
     <td>Sound to played when breaking this block.</td>
     <td>Random texture selection - whether or not to use the Y axis during randomization (for multiblock plants).</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_hit" data-tt-parent="p_sounds">hit</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_randomizeaxes_xyz" data-tt-parent="p_randomizeaxes">XYZ</div></td>
    <td></td>
    <td>0</td>
     <td></td>
     <td></td>
    <td>-</td>
    <td>Currently unused.</td>
   </tr>
   </tr>
   <tr>
   <tr>
     <td scope="row"><div class="tt" data-tt-id="p_inside" data-tt-parent="p_sounds">inside</div></td>
     <td scope="row"><div class="tt" data-tt-id="p_randomizeaxes_xz" data-tt-parent="p_randomizeaxes">XZ</div></td>
    <td></td>
    <td>1</td>
     <td></td>
     <td></td>
    <td>-</td>
    <td>Sound to played when moving inside block (only works for blocks that have no collisionbox, naturally).</td>
   </tr>
   </tr>
</table>
</table>
{{Navbox/modding|Vintage Story}}

Revision as of 10:38, 30 October 2018

Overview

A complete list of all available properties

Property Type Default Usage
json
Core (no byType available)
Code
string required A unique identifier for the block.

A domain prefix will be added dynamically depending on the location of the file. Every mod and VintageStory itself have a unique prefix.

For example the code stone turns into game:stone.

The code identifier has to be unique inside its domain. In theory there could be equal identifiers with different domain prefixes. Find out more about Domains.

Enabled
boolean true If the block will be loaded or not. Can be used to temporarily remove the block.
VariantGroups
array of object - Allows you define multiple variants of the same block.

The variantgroups property allows you to define multiple variants of this block. All of them will have their unique pattern, which will be added to the block code.

An easy example would be a bowl, which can either be raw or burned:

	variantgroups: [
		{ code:"type", states: ["raw", "burned"] },
	],

Meaning there will be two blocks bowl-raw and bowl-burned.


It's also possible to define multiple groups.

	variantgroups: [
		{ code:"state", states: ["closed", "opened"] },
		{ code:"contents", states: ["empty", "cabbage"] },
	],

As a result you will have 2x2 groups, which will be added one after each other: barrel-closed-empty, barrel-closed-cabbage, barrel-opened-empty and barrel-opened-cabbage.


Additionally it is possible to refer to external lists that are found in the worldproperties folder, such as block/rock, which contains all states of all rock types. This used for gravel, sand and rock. It's a good way to keep everything organized:

	variantgroups: [
		{ loadFromProperties: "block/rock" },
	],

Here is a full list of all groups and their variants (you can also find them in the assets/worldproperties folder): The world properties are stored in the assets/survival/worldproperties folder. They are used to help fill in the variantgroups field. Instead of directly specifying every state in the variant group, the states can be loaded from a world property through the loadFromProperties key. The states from multiple world properties can be added with the loadFromPropertiesCombine key, which takes an array of strings. The states key can still be optionally added to the variant group to specify additional states.

For example, the following creates a variant group named orientation. It contains 5 states. north, east, south, and west are loaded from the abstract/horizontalorientation world property. up is added to the list of states.

	variantgroups: [
		{ code: "orientation", states: ["up"], loadFromProperties: "abstract/horizontalorientation" }
	],

Unwanted variant states can be filtered out with the skipVariants property. Or all states that do not match an expression can be filtered out with the allowedVariants property.

Name States
abstract/alloy -
abstract/coating n, e, s, w, u, d, ud, ns, ew, nd, ed, sd, wd, su, wu, nu, eu, es, sw, nw, ne, nwd, ned, esd, swd, nwu, neu, esu, swu, nsd, ewd, sud, wud, nud, eud, nsu, ewu, nes, esw, nsw, new, newd, nesd, eswd, nswd, eswu, nswu, newu, nesu, nesw, ewud, nsud, neud, esud, swud, nwud, neswd, neswu, newud, nesud, eswud, nswud, neswud
abstract/fertility verylow, low, medium, compost, high
abstract/grasscoverage none, verysparse, sparse, normal
abstract/horizontalorientation north, east, south, west
abstract/rockgroup -
abstract/verticalorientation up, down
block/flower catmint, cornflower, forgetmenot, edelweiss, heather, horsetail, orangemallow, wilddaisy, westerngorse, cowparsley, goldenpoppy, lilyofthevalley, woad, redtopgrass
block/fruit blueberry, cranberry, redcurrant, whitecurrant, blackcurrant, saguaro, pineapple, redapple, pinkapple, yellowapple, cherry, peach, pear, orange, mango, breadfruit, lychee, pomegranate
block/grass -
block/herb basil, chamomile, cilantro, lavender, marjoram, mint, saffron, sage, thyme
block/metal bismuth, bismuthbronze, blackbronze, brass, chromium, copper, cupronickel, electrum, gold, iron, meteoriciron, lead, molybdochalkos, platinum, nickel, silver, stainlesssteel, steel, tin, tinbronze, titanium, uranium, zinc
block/mushroom flyagaric, fieldmushroom, almondmushroom, bitterbolete, blacktrumpet, chanterelle, commonmorel, deathcap, devilstooth, devilbolete, earthball, elfinsaddle, golddropmilkcap, greencrackedrussula, indigomilkcap, jackolantern, kingbolete, lobster, orangeoakbolete, paddystraw, puffball, redwinecap, saffronmilkcap, violetwebcap, witchhat, beardedtooth, chickenofthewoods, dryadsaddle, pinkoyster, tinderhoof, whiteoyster, reishi, funeralbell, deerear, livermushroom, pinkbonnet, shiitake
block/ore-gem-cut diamond, emerald, peridot
block/ore-gem-rough diamond,emerald,olivine_peridot
block/ore-graded nativecopper,limonite,quartz_nativegold,galena,cassiterite,chromite,ilmenite,sphalerite,quartz_nativesilver,galena_nativesilver,bismuthinite,magnetite,hematite,malachite,pentlandite,uranium,wolframite,rhodochrosite
block/ore-nugget nativecopper,limonite,nativegold,galena,cassiterite,chromite,ilmenite,sphalerite,nativesilver,bismuthinite,magnetite,hematite,malachite,pentlandite,uranium,wolframite,rhodochrosite
block/ore-ungraded alum,lapislazuli,corundum,anthracite,borax,cinnabar,lignite,bituminouscoal,sylvite,quartz,olivine,sulfur,fluorite,graphite,kernite,phosphorite
block/painting howl,elk,underwater,prey,forestdawn,fishandtherain,bogfort,castleruin,cow,hunterintheforest,seraph,sleepingwolf,sunkenruin,traveler,oldvillage,lastday,sodhouse
block/rock andesite,chalk,chert,conglomerate,limestone,claystone,granite,sandstone,shale,basalt,peridotite,phyllite,slate,bauxite
block/rockwithdeposit andesite,chalk,chert,conglomerate,limestone,claystone,granite,sandstone,shale,basalt,peridotite,phyllite,slate,obsidian,kimberlite,scoria,tuff,bauxite,halite,suevite,whitemarble,redmarble,greenmarble
block/tallgrass veryshort,short,mediumshort,medium,tall,verytall,eaten
block/toolmetal bismuth,bismuthbronze,blackbronze,brass,copper,gold,iron,meteoriciron,lead,molybdochalkos,silver,steel,tinbronze
block/wood birch,oak,maple,pine,acacia,kapok,baldcypress,larch,redwood,ebony,walnut,purpleheart
Icon Sign.png

Wondering where some links have gone?
The modding navbox is going through some changes! Check out Navigation Box Updates for more info and help finding specific pages.



Furthermore there are two ways of combining groups together. So far we covered the default combination mode, which is multiplicative (the total count of variants is the product of all states).

Let's take a look at a different example (flowerpot), which uses the additive combination mode:

	variantgroups: [
		{ code: "type", states: ["raw"] },
		{ code: "empty", states: ["empty"], combine: "additive" },
		{ code: "flower", loadFromProperties: "block/flower", combine: "additive" },
		{ code: "mushroom", loadFromProperties: "block/mushroom", combine: "additive" },
		{ code: "sapling", loadFromProperties: "block/wood", combine: "additive" },
	],

The variants are flowerpot-raw, flowerpot-empty, flowerpot-{all flowers}, flowerpot-{all mushrooms} and flowerpot-{all saplings}.

Additive mode could also be called separate, since it defines a variant separate from all the other groups:

	variantgroups: [
		{ code: "something", states: ["same", "different"] },
		{ code: "type", states: ["raw", "baked"] },
		{ code: "empty", states: ["red", "green"], "combine": "additive" },
	],

In this case, the result would be same-raw, same-baked, different-raw, different-baked, red and green

(any) byType
key: string; value: object - You can create properties for certain variants of the block.

In order to define properties for specific variants you can add byType to the property name. This allows you to define it depending on the type and always follows the same syntax:

	(property)ByType: {
		"selector": property,
		"selector2": property2,
		...
	}

If the selector matches the name of the variant the given property will be used. Keep in mind that only the first matching one will be used (everything below will be ignored).

A slab for example has two variants (up, down), which have different collision boxes:

	collisionboxByType: {
		"*-down": { x1: 0, y1: 0, z1: 0,   x2: 1, y2: 0.5, z2: 1 },
		"*-up": { x1: 0, y1: 0.5, z1: 0,   x2: 1, y2: 1, z2: 1 }
	},

The char * stands for anything. In this case it ignores the code of the block.

Furthermore this opens up even more possbilities for more advanced selectors like this one for doors: *-north-*-opened-left. This will ignore the second variantgroup. Additionally ByType can also be used for child properties:

	collisionboxnbox: { 
		x1: 0, y1: 0, z1: 0.875, x2: 1, y2: 1, z2: 1,
		rotateYByType: {
			"*-north-*-opened-left": 90,
			"*-north-*-closed-left": 0,
			"*-west-*-opened-left": 180,
			"*-west-*-closed-left": 90,

			"*-east-*-opened-left": 0,
			"*-east-*-closed-left": 270,
			"*-south-*-opened-left": 270,
			"*-south-*-closed-left": 180,

			"*-north-*-opened-right": 270,
			"*-north-*-closed-right": 0,
			"*-west-*-opened-right": 0,
			"*-west-*-closed-right": 90,

			"*-east-*-opened-right": 180,
			"*-east-*-closed-right": 270,
			"*-south-*-opened-right": 90,
			"*-south-*-closed-right": 180
		}
	},

Since Vintagestory v1.8 it is also possible to use the variantgroup as a placeholder:

	variantgroups: [
		{ code: "type", states: ["normal", "bamboo"] },
	],
	textures: {
		horizontals: { base: "block/hay/{type}-side" },
		verticals: { base: "block/hay/{type}-top" },
	},
Specific
Class
string "block" The block class can add special functionalities for the block.

It can be used to open guis or adding other extra functionality to the block. A complete tutorial of how to add your own class to the game can be found here.

EntityClass
string - The block entity class is able to tick and to store extra data.

A chest for example uses the BlockEntity to store the inventory. A tutorial of creating your own entityclass can be found here.

Behaviors
array of object - A behavior adds custom abilities such as falling block.

Here is an overview of all exisiting behaviors, if you want to create your own custom behavior you can read Adding Block Behavior.

Adding behaviors to your block

Block behaviors are an array of objects with properties attached to your block. They are added through the behaviors field at the top level (same level as the code field) of a block json file. Below is an example of two behaviors, one with properties and one without properties.

{
  ...
  code: "exampleblock",
  ...
  behaviors: [{name: "behavior1", properties: {myProperty1: "myValue1", myProperty2: "myValue2"}},{name: "behavior2"}],
  ...
}

All Block Behaviors

Here is a table containing all properties of the base game as of 1.18.14.

Behavior Name Properties Used by Blocks
BlockEntityInteract - door
BreakIfFloating - termitemound, crackedrock, meteorite, ore, ore, ore, rock, rottenlog
BreakSnowFirst - tallgrass, stonepath
CanAttach
  • sides
drystonefence, woodenfence, roughhewnfence
CanIgnite - torch
CollectFrom - henbox
Container - storagevessel, stove, hopper, quern, crate, labeledchest, trunk, chest, firepit, stationarybasket
Decor
  • sides
  • sidedVariants
  • nwOrientable
  • drawIfCulled
  • alternateZOffset
  • notFullFace
  • removable
  • thickness
linen, mediumcarpet, rushmat, smallcarpet, wallpaper, wool, hotspringbacteriasmooth, hotspringbacteria, attachingplant, overlay, overlay, oxidation, transition, fallenleaves, caveart
Door - door
DropNotSnowCovered - fern, flower
ExchangeOnInteract
  • exchangeStates (string array of block states)
  • sounds (path from sounds folder)
  • actionLangCode (language key from the lang file)
trapdoor
FiniteSpreadingLiquid
  • liquidCollisionSound (path from sounds folder)
  • sourceReplacementCode (block code)
  • flowingReplacementCode (block code)
  • collidesWith (other liquid)
  • spreadDelay (int, default: 0)
boilingwater, water, lava, saltwater
Harvestable
  • harvestTime (float, seconds, default: 0)
  • harvestedStack (BlockDropItemStack)
  • harvestingSound (path from sounds folder)
  • harvestedBlockCode (block code)
bigberrybush, saguarocactus, smallberrybush, log-resin
HeatSource
  • heatStrength (float)
boilingwater, lava, forge, firepit, pitkiln, coalpile, ember, fire
HorizontalAttachable
  • handleDrops (bool, default: true)
  • dropBlockFace (Compass Direction, default: "north")
  • dropBlock (block name)
  • attachmentAreas (side -> RotatableCube)
  • attachmentArea (cuboid)
tapestry, torchholder, mushroom, canvas, moldrack, painting, shelf, toolrack
HorizontalOrientable
  • dropBlockFace (Compass Direction, default: "North")
  • drop (block name)
agedwallpaperplanks, altar, bellows, bloomerybase, brake, cage, churn, clayoven, clutch, cokeovendoor, condenser, crank, creativerotor, helvehammerbase, jonas, labeledchest, metalpartpile, palisadestakes, palisadewall, pulverizerframe, resonator, skep, slantedroofing, slantedroofingcornerinner, slantedroofingcornerouter, statictranslocator, stationarybasket, stonecoffinsection, stove, trunk, verticalboiler, wagonwheels, windmillrotor, workbench
HorizontalUpDownOrientable - -
Ignitable - charcoalpit, clayoven, firepit
JonasBoilerDoor - jonas
JonasGasifier - jonas
JonasHydraulicPump - jonas
Ladder
  • dropBlockFace (face direction, Default: north)
  • isFlexible (bool, default: false)
ladder
Lockable - archimedesscrew, chest, chute, cokeovendoor, crate, door, hopper, irondoor, labeledchest, roughhewnfencegate, stationarybasket, storagevessel, trapdoor, trunk, woodenfencegate
MilkingContainer - woodbucket
Multiblock
  • sizex
  • sizey
  • sizez
  • type
  • cposition
jonas, riftward, verticalboiler, banner, trunk, painting
MyceliumHost - creativegrass, forestfloor, log, soil
NoParticles - claybrickchimney
NWOrientable - bookshelves (legacy), claybrickchimney, fruitpress, fruitpresstop, mannequin, slantedroofingridge, transmission, trough, woodenpath, woodentoggle
OmniAttachable
  • facingCode (string, default: orientation)
  • attachmentAreas (side -> RotatableCube)
crystal, lantern
OmniRotatable
  • rotateH (bool, default: false)
  • rotateV (bool, default: false)
  • rotateV4 (bool, default: false)
  • rotateSides (bool, default: false)
  • facing (string, "block" or "player", default: "player")
  • dropChance(float, default: 1)
brickslabs, clayshinglelabs, cobblestoneslab, glassslab, mudbrickslab, plankslab, polishedrockslab, quartzslab, stonebrickslab, trapdoor
Pillar
  • invertedPlacement (bool, default: false)
carvedlog, debarkedlog, hay, log, lognarrow, planks, plaster, quartzpillar, stackedbamboo, woodenaxle
Pumpkin
  • vineGrowthStage(int)
  • vineGrowthQuantity(NatFloat)
crop
PushEventOnBlockBroken
  • eventName (string)
bamboo, bambooleaves, leaves, leavesbranchy, leavesnarrow, log, lognarrow, logsection
RainDrip - -
Reinforcable - -
RightClickPickup
  • dropsPickupMode (bool, default: false)
  • sound (path from sounds folder)
  • placeSound (path from sounds folder)
basereturnteleporter, bowl, bowl-meal, clayplanter, claypot, crock, crucible, egg, flowerpot, ingotmold, jug, lantern, looseflints, looseores, loosestick, loosestones, metal, oillamp, pan, pie, pineapple, pumpkin, seashell, storagevessel, toolmold, wateringcan, woodbucket
RopeTieable - roughhewnfence, woodenfence
Slab - -
Steaming - boilingwater
SneakPlacing - pan, pie, wateringcan
Unplaceable - bloomerychimney, bowl, bowl-meal, clayplanter, claypot, crock, crucible, flowerpot, ingotmold, jug, metal, pineapple, pumpkin, storagevessel, toolmold, wateringcan
Unstable
  • attachedToFaces (default: down)
  • attachmentAreas (side -> RotatableCube)
bunchocandles, crop, deadcrop, firepit, oreblastingbomb, silvertorchcactus, verticalboiler, wildbeehive, woodenpath, woodenrails
UnstableFalling
  • attachableFaces (string array)
  • attachmentArea (cuboid)
  • attachmentAreas (side -> RotatableCube)
  • ignorePlaceTest (bool, default: false)
  • exceptions (block code array)
  • fallSideways (bool, default: false)
  • dustIntensity (float, default: 0)
  • fallSidewaysChance (float, default: 0.3)
  • fallSound (path from sounds folder)
  • impactDamageMul (float, default 1)
anvil, anvilpart, barrel, barrelcactus, bloomerychimney, bonyremains, bonysoil, carcass, chair, chandelier, cheese, churn, clayplanter, coalpile, dirtygravel, displaycase, drycarcass, egg, flowerpot, gravel, groundstorage, ingotmold, knappingsurface, lightningrod, looseboulders, looseflints, loosegears, looseores, loosestick, loosestones, lootvessel, metal, metalpartpile, muddygravel, oillamp, omoktabletop, pan, pie, quern, sand, seashell, sieve, sludgygravel, snowlayer, stonecoffinlid, storagevessel, table, talldisplaycase, toolmold, wateringcan, woodbucket
WrenchOrientable
  • hideInteractionHelpInSurvival (bool, default: false)
  • baseCode (string)
banner, brickslabs, brickstairs, carvedlog, chute, clayshinglelabs, clayshinglestairs, clutter, cobblestoneslab, cobblestonestairs, debarkedlog, glassslab, jonas, log, mudbrickslab, planks, plankslab, plankstairs, plaster, polishedrockslab, quartzpillar, quartzslab, quartzstairs, stonebrickslab, stonebrickstairs, stonepathstairs
WorldEditFixGhostBlockPlace - -
Icon Sign.png

Wondering where some links have gone?
The modding navbox is going through some changes! Check out Navigation Box Updates for more info and help finding specific pages.


BlockMaterial
string - A behavior adds custom abilities such as falling block.
Soil

Gravel

Sand

Wood

Leaves

Stone

Liquid

Snow

Ice

Metal

Mantle

Plant

Glass

Ceramic

Cloth

Lava

Brick

Fire

Other

Materials are hardcoded and currently only used to determine mining speed with a specific tool.

MatterState
array of object "block" Determines whether the block is in a solid, a liquid, a gas or a plasma state.
solid


liquid


gas


plasma


Used for special collision behavior and rendering. Currently used for:

Liquid:

  • Lava
  • Water
  • Water with particles

Gas/Plasma: none added yet

Resistance
decimal number 6 How long it takes to break this block in seconds (with a mining speed of 1).

Same examples of resistance's values used in VintageStory:

Block Value
leave 0.5
wool 1.0
bowl 1.5
obsidian 2
plank 3.5
log 4.5
rock 6
RequiredMiningTier
integer 0 Minimum required mining tier to get the drop out of the block.
Tier Ores
1 gelena and rocksalt_sylvite
2 lignite, cassiterite, sphalerite, rocksalt, sulfur and nativecopper
3 bituminouscoal, quartz_nativegold, quartz_nativesilver, lapislazuli, bismuthinite, quartz, magnetite and limonite
4 diamond and emerald
5 chromite, platinum and ilmenite
Climbable
boolean false If true, walking against this block will make the player climb (used for ladders).
RainPermeable
boolean false If rain can fall through this block.
SnowCoverage
boolean - Whether snow may rest on top of this block.

All none solid blocks can't be covered by snow unless it's defined different:

  • Leaves (also branchy): true,
  • Water with particles, Lakeice: false
CollisionBox
object box (0,0,0 -> 1,1,1) Defines a box with which the player collides with.

A half slab for example, has either a box going from 0,0,0 to 1,0.5,1 or going from 0,0.5,0 to 1,1,1, depending on whether it is a slab is down or up:

	collisionboxByType: {
		"*-down": { x1: 0, y1: 0, z1: 0,   x2: 1, y2: 0.5, z2: 1 },
		"*-up": { x1: 0, y1: 0.5, z1: 0,   x2: 1, y2: 1, z2: 1 }
	},

Collision and selection boxes are most likely equal.

CollisionBoxes
array of object - Defines multiple boxes with which the player collides with.

A crate for example requires multiple collision boxes:

	collisionboxesByType: {
		"*-opened": [ 
			{ x1: 0, y1: 0, z1: 0, x2: 1, y2: 0.0625, z2: 1 },
			{ x1: 0, y1: 0, z1: 0, x2: 1, y2: 1, z2: 0.0625 },
			{ x1: 0, y1: 0, z1: 0, x2: 1, y2: 1, z2: 0.0625, rotateY: 90 },
			{ x1: 0, y1: 0, z1: 0, x2: 1, y2: 1, z2: 0.0625, rotateY: 180 },
			{ x1: 0, y1: 0, z1: 0, x2: 1, y2: 1, z2: 0.0625, rotateY: 270 },
		]
	},
SelectionBox
object box (0,0,0 -> 1,1,1) Defines a box which the player's mouse pointer collides with for selection.

A half slab for example, has either a box going from 0,0,0 to 1,0.5,1 or going from 0,0.5,0 to 1,1,1, depending on whether it is a slab is down or up:

	selectionboxByType: {
		"*-down": { x1: 0, y1: 0, z1: 0,   x2: 1, y2: 0.5, z2: 1 },
		"*-up": { x1: 0, y1: 0.5, z1: 0,   x2: 1, y2: 1, z2: 1 }
	},

Collision and selection boxes are most likely equal.

SelectionBoxes
array of object - Defines multiple boxes which the player's mouse pointer collides with for selection.

A crate for example requires multiple selection boxes:

	selectionboxesByType: {
		"*-opened": [ 
			{ x1: 0, y1: 0, z1: 0, x2: 1, y2: 0.0625, z2: 1 },
			{ x1: 0, y1: 0, z1: 0, x2: 1, y2: 1, z2: 0.0625 },
			{ x1: 0, y1: 0, z1: 0, x2: 1, y2: 1, z2: 0.0625, rotateY: 90 },
			{ x1: 0, y1: 0, z1: 0, x2: 1, y2: 1, z2: 0.0625, rotateY: 180 },
			{ x1: 0, y1: 0, z1: 0, x2: 1, y2: 1, z2: 0.0625, rotateY: 270 },
		]
	},
Replaceable
integer 0 A value usually between 0-9999 that indicates which blocks may be replaced with others.
Value Effect (Blocks)
0 ordinary blocks (stone for example)
5000 Everything equal or above will be washed away by water (such as Fruit).
6000 Everything equal or above wwill replaced when the player tries to place a block (such as Tallgrass).
9000 Lava
9500 Water
9999 Air
Fertility
integer 0 Which plants can grow on top of this block.
Value Effect
0 nothing can grow.
10 some tallgrass and small trees can be grow on it.
100 all grass and trees can grow on it.
GlowLevel
0 ... 255 0 Causes the block to visually glow if Bloom is enabled. Basic glow level for all the blocks model elements.
Blocks Value
Glacierice 8
Paperlantern 32
Ember 48
Fire, Firepit, Oillamp, Torch 64
Lava 128
LightAbsorption
0 ... 32 0 For light blocking blocks. Any value above 32 will completely block all light.
WalkspeedMultiplier
decimal number 1.0 Percentage walk-speed when standing on or inside this block.
Blocks Value
Spiderweb 0.25
Stonepath 1.15
DragMultiplier
decimal number 1.0 Drag multiplier applied to entities standing on it (slipperiness factor).
Blocks Value
Glacierice, Lakeice 0.02
Drops
array of object - The items that should drop from breaking this block.

Drop itself

If this property does not exist the block will drop itself.


No drop

A firepit for example doesn't drop anything. You can do so if you specify an empty array:

	drops: [],

Special drop

You can also specify a special item/ block. Therefore you need to define an ItemStack, with the given properties:

Property Default Explanation
type block Can either be block or item.
code (required) - The complete code (can also include domain) of the item or block.
lastdrop false If true and the quantity dropped is >=1 any subsequent drop in the list will be ignored.
attributes - Tree Attributes that will be attached to the resulting itemstack.
tool - If specified then given tool is required to break this block.
quantity - (one) Determines the quantity of items which will be dropped.

For example, the drop of a charcoalpile looks like this:

	drops: [
		{ type: "item", code: "charcoal" }
	],

Tallgrass will only drop something if it's mined by a knife:

	drops: [
		{ type: "item", code: "drygrass", tool: "knife"  },
	],

Chance drops

Let's take a look at an example. This is the drop property of rock:

	
	drops: [
		{
			type: "item", 
			code: "stone-{rock}", 
			quantity: { avg: 2.5, var: 0.5 } 
		},
	]

This will drop 2-3 blocks.

avg: Stands for the default drop quantity. If var is 0 or not specified it will always drop the given average.

var: How much the drop rate can vary. Meaning the drop rate can be avg - var at minimum and age + var at maximum.

Furthermore you can also switch between different distribution modes using the dist property.

Overview - Distribution modes
Name Explanation
uniform Select completely random numbers within avg-var until avg+var.
triangle Select random numbers with numbers near avg being the most commonly selected ones, following a triangle curve.
gaussian Select random numbers with numbers near avg being the most commonly selected ones, following a gaussian curve.
narrowgaussian Select random numbers with numbers near avg being the most commonly selected ones, following a narrow gaussian curve.
inversegaussian Select random numbers with numbers near avg being the least commonly selected ones, following an upside down gaussian curve.
narrowinversegaussian Select random numbers with numbers near avg being the least commonly selected ones, following an upside down gaussian curve.
invexp Select numbers in the form of avg + var, wheras low value of var are preferred.
stronginvexp Select numbers in the form of avg + var, wheras low value of var are strongly preferred.
strongerinvexp Select numbers in the form of avg + var, wheras low value of var are very strongly preferred.
dirac Select completely random numbers within avg-var until avg+var only ONCE and then always 0.

Multiple Drops

Of course you can also define multiple drops at once. Sapling can drop a sapling and a stick:

	drops: [
		{ 
			type: "block", 
			code: "sapling-{wood}",
			quantity: { avg: 0.02, var: 0 },
		},
		{ 
			type: "item", 
			code: "stick",
			quantity: { avg: 0.02, var: 0 },
		}
	],

Last Drop

In order to add a special drop, which (if dropped) prevents all other drops, you can use the lastDrop property:

dropsByType: {
	"ore-quartz-*": [
		{ type: "item", code: "clearquartz",  quantity: { avg: 0.2, var: 0 }, lastDrop: true },
		{ type: "item", code: "ore-{ore}",  quantity: { avg: 1.25, var: 0 }  }
	],
	"*": [ 
		{ type: "item", code: "ore-{ore}",  quantity: { avg: 1.25, var: 0 }  }
	],
}

Quartz ore will drop with a 20% chance clearquartz, if not it will drop the regular ore. If lastDrop wouldn't be true it could drop both at the same time.

ParticleProperties
array of object - Particles that should spawn in regular intervals from this block.

The torch is a good example of how to use those particles ...

	particleProperties: [
		{
			hsvaColor: [{ avg: 20, var: 20 }, { avg: 255, var: 50 }, { avg: 255, var: 50 },  { avg: 255, var: 0 }],
			gravityEffect: { avg: 0, var: 0 },
			posOffset: [ { avg: 0, var: 0.1 }, { avg: 0, var: 0 }, { avg: 0, var: 0.1 }],
			velocity: [ { avg: 0, var: 0.025 }, { avg: 0.5, var: 0.1 }, { avg: 0, var: 0.025 }],
			quantity: { avg: 0.015 },
			size: { avg: 0.5, var: 0 },
			sizeEvolve: { transform: "quadratic", factor: -0.7 },
			lifeLength: { avg: 1.5 },
			glowLevel: 64
		},
		{
			hsvaColor: [{ avg: 0, var: 0 }, { avg: 0, var: 0 }, { avg: 40, var: 30 },  { avg: 220, var: 50 }],
			opacityEvolve: { transform: "quadratic", factor: -16 },
			gravityEffect: { avg: 0, var: 0 },
			posOffset: [ { avg: 0, var: 0.1 }, { avg: 0, var: 0 }, { avg: 0, var: 0.1 }],
			velocity: [ { avg: 0, var: 0.025 }, { avg: 0.15, var: 0.1 }, { avg: 0, var: 0.025 }],
			quantity: { avg: 0.05 },
			size: { avg: 0.25, var: 0.05 },
			sizeEvolve: { transform: "linear", factor: 0.5 },
			particleModel: "Quad"
		}
	],

There is also a complete tutorial about particles, which should help you to find out what each property does.

LiquidLevel
0 ... 7 0 Value between 0...7 for Liquids to determine the height of the liquid.
CropProps
object - Information about the block as a crop.
Sounds
key: string, value: string - The sounds played for this block during step, break, build and walk.
Walk
An entity walks over it.
Inside
The player is inside the block.
Break
Breaking the block.
Place
Placing the block.
Hit
While mining the block.
Ambient
Played from time to time if the player is close to it.

Anvil:

    sounds: {
        "place": "block/anvil",
        "break": "block/anvil"
    }

Rails:

    sounds: {
        place": "block/planks",
        "walk": "walk/wood"
    }

Water:

    sounds: {
        place: "block/water",
        inside: "walk/water",
        ambient: "environment/creek"
    },
Common
CreativeInventory
key: string, value: string[] - In which creative inventory tabs the block should be visible in.

There are several tabs to you can add your stuff. Note that general should always be included, since it should contain everything.

  • general
  • terrain
  • flora
  • construction
  • decorative
  • items

Rock adds all of it's variantions to general, terrain and construction:

	creativeinventory: { "general": ["*"], "terrain": ["*"], "construction": ["*"] },

* reprents the variants which will be added. You can specify multiple and separate them with a comma. It follows the same way as the byType property.

A Torch on the other hand only adds the variation up:

	creativeinventory: { "general": ["*-up"], "decorative": ["*-up"] },
MaxStackSize
integer 64 Determines the maximum amount you can stack the block in one slot.
AttackPower
decimal number 0.5 The damage the deals when hitting an entity.
AttackRange
decimal number 1.5 The maximum distance you can hit an entity.
MaterialDensity
integer 9999 Determines on whether an object floats on liquids or not.

Water has a density of 1000, meaning everything below or equal will float on water. The same goes for lava which has a density of 5000.

LiquidSelectable
boolean false If the block can select a liquid while holding it in hand.

Used for buckets in order to fill it with water and to place waterlily on top of water.

MiningSpeed
key: string, value: decimal number - The mining speed for each material.
MiningTier
integer 0 Determines which blocks it can break. If the required miningtier is above the defined one there will be no drop from it.
Attributes
key: string, value: object - Custom Attributes associated with this block.

Extra attributes added to a block. Those are final and cannot be modified. It's a good way to keep things organized and and modifiable. The oreblastingbomb for example has attributes, which define its radius and type. These can be used by behaviors and blockentities:

    attributes: {
		"blastRadius": 4,
		"blastType": 0,
	},
CombustibleProps
object - Information about the blocks burnable states.
BurnTemperature
integer - The temperature at which it burns in degrees Celsius.
BurnDuration
decimal number - For how long it burns in seconds.
HeatResistance
integer 500 How many degrees celsius it can resists before it ignites (not implemented yet).
MeltingPoint
integer - How many degrees celsius it takes to smelt/transform this into another. Only used when put in a stove and SmeltedStack is set.
MeltingDuration
decimal number - For how many seconds the temperature has to be above the melting point until the item is smelted.
SmokeLevel
decimal number 1 How much smoke this item produces when being used as fuel.
SmeltedRatio
integer 1 How many ores are required to produce one output stack.
SmeltedStack
object - If set, the block/item is smeltable in a furnace and this is the resulting itemstack once the MeltingPoint has been reached for the supplied duration.
RequiresContainer
boolean true If set to true, the block/item requires a smelting/cooking/baking container such as the Crucible. If false, it can be directly baked/melted without smelting/cooking/baking container.

This property can be used to define a burning material. Plank for example can get on fire:

    combustibleProps: {
        burnTemperature: 800,
        burnDuration: 12,
    },

Furthermore it can be used to define smelting processes. An example would be an ingotmold which turns into an ingotmold-burned:

    combustiblePropsByType: {
        "ingotmold-raw": {
            meltingPoint: 600,
            meltingDuration: 30,
            smeltedRatio: 1,
            smeltedStack: { type: "block", code: "ingotmold-burned" },
            requiresContainer: false
        }
    },
NutritionProps
object - Information about the blocks nutrients.
FoodCategory
string - Defines the type of food. It can be fruit, vegetable, protein, grain and dairy.
Saturation
decimal number 0 How much saturation it can restore.
Health
decimal number 0 How much health it can restore.
Rendering
Textures
key: string, value: object The texture definitions for the block as seen in the world, when dropped on the ground or held in the hand.
base


overlays


alternates
The dictionary contains multiple named textures. Different tessellators expect different texture names. Most tessellators accept the special "all" alias to set all textures at once. Default example (glass):
textures: {
		all: { base: "block/glass" },
	}
Using variantgroups (rock):
textures: {
		all: {base: "block/stone/rock/{rock}" },
	}

There are a few aliases that set multiple textures at the same time:

  • all - sets all textures for tessellators that support the alias
  • sides - "west", "east", "north", "south", "up", and "down"
  • horizontals - "west", "east", "north", and "south"
  • verticals - "up" and "down"
  • westeast - "west" and "east"
  • northsouth - "north" and "south"

For example, hay block uses two aliases:

textures: {
		horizontals: { base: "block/hay/{type}-side" },
		verticals: { base: "block/hay/{type}-top" },
	},
There are many options to rotate textures, combine them, and randomize the textures by block location.
TexturesInventory
key: string, value: object The texture definitions for the block as seen in the player inventory. Overrides the textures.
Shape
object - For the json drawtype, the shape definition of the block as shown in the world, dropped on the ground or held in hand.
base
The path to the shape json file, the base dir is assets/shapes/.
rotateX
float 0 Only 90 degree rotations are possible.
rotateY
float 0 Only 90 degree rotations are possible.
rotateZ
float 0 Only 90 degree rotations are possible.
ShapeInventory
object - For the json drawtype, the shape definition of the block as shown in the players inventory.
DrawType
string "cube" Determines how the block is tesselated, select JSON for being able to use custom JSON Models. The other values are hardcoded methods of tesselating the block.
blockLayer_1
0
blockLayer_2
1
blockLayer_3
2
blockLayer_4
3
blockLayer_5
4
blockLayer_6
5
blockLayer_7
6
json
7 Will draw a json model.
empty
8 Nothing will be drawn.
cube
9 Draws an ordinary cube.
cross
10
transparent
11
liquid
12
crossandsnowlayer
13
RenderPass
string "opaque" Determines how the block will be drawn.
opaque
0 Used for solid blocks with no half transparency.
opaquenocull
1 Used for non-solid single faced blocks, such as tall grass.
transparent
2 Use for solid halftransparent blocks, such as glass
liquid
3 Used for liquids, produces waves.
topsoil
4 Used for grass covered blocks. Allows for a smooth transition from grass to soil, while still allowing climate tinting of grass.
AmbientOcclusion
boolean true If ambient occlusion will be applied to the block.
TintIndex
integer 0 0 for no tint, 1 for plant climate tint, 2 for water climate tint.
RenderFlags
0 ... 255 0 8 bits that are sent to the graphics card for each vertex of the blocks shape. The lower 3 bits are currently used for altering the vertexes z-depth to fix a bunch of z-fighting issues.
FaceCullMode
string "default" Determines which sides of the blocks should be rendered.
Default
0 Culls faces if they are opaque faces adjacent to opaque faces.
NeverCull
1 Never culls any faces.
Merge
2 Culls all faces that are adjacent to opaque faces and faces adjacent to blocks of the same id (Example usage: Ice blocks).
Collapse
3 Culls all faces that are adjacent to opaque faces and the bottom, east or south faces adjacent to blocks of the same id. This causes to still leave one single face in between instead of 2, eliminating any z-fighting.
MergeMaterial
4 Same as Merge but checks for equal material (Example usage: Plain glass and all colored glass blocks).
CollapseMaterial
5 Same as Collapse but checks for equal material (Example usage: All leaves blocks).
Liquid
6 Same as CollapseMaterial but also culls faces towards opaque blocks.
SideOpaque
key: string, value: boolean - Determines if given block face is fully opaque. If yes, the opposite face of the adjacent block will not be drawn for efficiency reasons.
all

horizontals

verticals

east

west

up

down

north

south
SideAo
key: string, value: boolean - If AmbientOcclusion will be applied for each side.
all

horizontals

verticals

east

west

up

down

north

south
SideSolid
key: string, value: boolean - Determins if given block side is solid. If true, other blocks like torches can be attached to it.
all

horizontals

verticals

east

west

up

down

north

south
RandomDrawOffset
boolean false If true then the block will be randomly offseted by 1/3 of a block when placed.
LightHsv
byte array with 3 elements. See http://tyron.at/vs/vslightwheel.html for valid values - For light emitting blocks: hue, saturation and brightness value.
LightAbsorption
0 ... 255 99 For light blocking blocks. Any value above 32 will completely block all light.
GuiTransform
object block default Used for scaling, rotation or offseting the block when rendered in guis.
FpHandTransform
object block default Used for scaling, rotation or offseting the block when rendered in the first person mode hand.
TpHandTransform
object block default Used for scaling, rotation or offseting the block when rendered in the third person mode hand.
GroundTransform
object block default Used for scaling, rotation or offseting the rendered as a dropped item on the ground.
RandomizeAxes
string "xyz" Random texture selection - whether or not to use the Y axis during randomization (for multiblock plants).
XYZ
0
XZ
1


Icon Sign.png

Wondering where some links have gone?
The modding navbox is going through some changes! Check out Navigation Box Updates for more info and help finding specific pages.