How to make a block
Blocks are fundamental elements for most mods. This page describes how you can add custom blocks to your mod.
General properties
Property | Description |
---|---|
In game name | This is what will be displayed in the game for this block's name. |
Material | The material for this block. Materials help classify blocks. |
Sound | The sound to be used for this block. Affects things like the noise the block makes when walked on. |
Hardness | The hardness of a block determines how long it will take to break. |
Explosion Resistance | How resistant the block is to explosions. |
Jump Factor | A higher jump factor means that players can jump higher when standing on this block. |
Friction | A measure of the block's friction. |
Speed Factor | How much the player's speed is multiplied when moving on this block. |
Textures and Model
Texture and model determine how your block will look in the game. Textures are the images that will be displayed on blocks. A block model determines how the texture(s) will be mapped onto the block. The simplest model displays the same texture on all six sides of a cubic block.
Loot
A loot table is used to determine what will drop when your block is broken. Any loot table element that has been added to your mod can be selected here and associated with the block.
Events (blueprints)
Events are used to control the behavior of your block. Each event can have any number of nodes connected to form a blueprint.
onDestroyedByPlayer
This event is fired when this block is broken by the player (in survival mode).
stepOn
This event is fired when a player steps on this block.