Skip to content

Block Definition File

Jacob Granberry edited this page Feb 21, 2025 · 5 revisions

Block Definition File Reference

This page covers all the properties you can use when defining blocks in the WesterosBlocks mod.

Base Block Properties

These properties are available for all block types:

Required Properties

Property Description
blockName Name of block type (must be lowercase). Full name will be 'westerosblocks:' plus this name
blockType Type of block being defined (see Custom-Block-Types)
label Display name for the block
creativeTab Which creative tab the block appears in
material Type of material for the block

Optional Properties

Property Description Default
hardness Block's durability/hardness -
resistance Block's explosion resistance -
lightValue Emitted light level (0=none, 1=max) 0
stepSound Sound when walked on "stone"
alphaRender Use alpha blending (translucent) false
nonOpaque Block is not solid/opaque false
legacyBlockID Legacy block-id:metadata value from 1.12.2 -

Material Types

Available materials: air, grass, ground, wood, rock, iron, anvil, water, lava, leaves, plants, vine, sponge, cloth, fire, sand, glass, tnt, coral, ice, snow, craftedSnow, cactus, clay, portal, cake, web, piston, decoration, stone

Step Sounds

Available step sounds: powder, wood, gravel, grass, stone, metal, glass, cloth, sand, snow, ladder, anvil, plant, slime

Creative Tabs

Vanilla Minecraft tabs: buildingBlocks, decorations, redstone, transportation, misc, food, tools, combat, brewing, materials WesterosBlocks tabs: WesterosBrick, WesterosCobbleStone, WesterosSandstone, WesterosMarblePlaster, WesterosTimberFrame, WesterosRoofing, WesterosWoodPlanks, WesterosPanellingCarvings, WesterosMetal, WesterosWindowsGlass, WesterosClothFibers, WesterosFurniture, WesterosLighting, WesterosToolBlocks, WesterosFoodBlocks, WesterosDecor, WesterosTerrainSets, WesterosGrassDirt, WesterosSandGravel, WesterosLogs, WesterosLeaves, WesterosGrassesShrubs, WesterosFlowers, WesterosCropsHerbs, WesterosWaterAir, WesterosUtility, WesterosSounds, WesterosDoNotUse

Harvest Properties

You can define required tools and levels for harvesting:

"harvestLevel": [
  {
    "tool": "pickaxe",
    "level": 2
  }
]

Available tools:

  • axe
  • hoe
  • pickaxe
  • shovel

Levels range from 0-4.

Color Properties

Color Multiplier

The colorMult property can be used to tint blocks. Values can be:

  • Hex color: "#RRGGBB"
  • Built-in maps: "water", "foliage", "grass", "pine", "birch", "basic", "lily"
  • Custom map: Path to a colormap file in assets/westerosblocks/

Random Textures

"randomTextures": [
  {
    "textures": ["texture1", "texture2"],
    "weight": 1
  }
]

Overlay Textures

"overlayTextures": ["overlay1", "overlay2"]

Advanced Properties

Collision Boxes

"collisionBoxes": [
  {
    "xMin": 0,
    "xMax": 1,
    "yMin": 0,
    "yMax": 1,
    "zMin": 0,
    "zMax": 1
  }
]

Support Boxes

"supportBoxes": [
  {
    "xMin": 0,
    "xMax": 1,
    "yMin": 0,
    "yMax": 1,
    "zMin": 0,
    "zMax": 1
  }
]

Multi-State Blocks

Some block types support multiple states:

"states": [
  {
    "stateID": "state1",
    "textures": ["texture1", "texture2"],
    "lightValue": 0.5
  }
]