Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
17 changes: 17 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,22 @@
# Changelog

## 0.3.7.110021

- Use a shovel to turn dirt and grass steps and corners into matching path
pieces. Their shape and direction stay the same, with the top lowered by
one pixel.
- Flattening a grass step or corner also turns ordinary grass directly beneath
it into a path. Both changes use one shovel action and one durability point.
- Grass steps and corners keep their grass and snow fringes, and leave exposed
grass visible underneath.
- Stack two matching corners in the crafting grid to make a step, or two steps
to make a slab. The same recipes work with supported add-on materials.
- Mineralogy's 27 natural rocks now get steps and corners automatically when
Mineralogy is installed. Its existing slabs are used when rebuilding pieces.
No separate Mineralogy piece add-on is needed.
- Saves made with the earlier Mineralogy piece add-on keep their materials,
orientations and item data when moving to the built-in support.

## 0.3.6.110021

- Shortened piece names, including Gold Wall, Gold Stairs and Oak Step.
Expand Down
10 changes: 9 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@ with: slabs, steps, corners, stairs, walls and ice panes. Add narrow trims,
fill awkward corners or build a glass wall without using full blocks everywhere.

The mod uses vanilla materials and reuses existing Minecraft pieces where they
already fit. It doesn't generate terrain.
already fit. When Mineralogy is installed, its natural rocks also get matching
steps and corners automatically. No Mineralogy add-on is needed. Building
Pieces doesn't generate terrain.

## Building with the pieces

Expand All @@ -25,12 +27,18 @@ run, with borders at posts, exposed ends and colour changes.

Dirt and grass steps and corners are included too. Grass follows biome colours,
spreads and decays much like vanilla grass. Plants need a complete upper face.
Use a shovel on an uncovered dirt or grass step or corner to turn it into a
matching path piece. Its footprint stays the same, with a one-pixel lower top.
Flattening a grass piece also turns an ordinary grass block directly beneath
it into a path, using the same shovel action.

## Crafting

Craft pieces from matching full blocks, slabs and steps. For example, three
full blocks in a row make six slabs, and two matching slabs placed diagonally
make four steps. Existing vanilla recipes stay available.
You can also rebuild larger pieces: stack two matching corners in the crafting
grid for one step, or two matching steps for one slab.

The [recipe and placement guide](docs/GAMEPLAY.md) has the full patterns,
quantities and exceptions, including the separate dirt vertical slab recipe
Expand Down
20 changes: 20 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -227,6 +227,15 @@ dependencies {
testRuntimeOnly 'org.junit.platform:junit-platform-launcher:1.10.2'
}

tasks.register('alignSoilModels', JavaExec) {
group = 'build setup'
description = 'Aligns grass and snow fringes with the exposed top of each soil piece.'
dependsOn tasks.named('testClasses')
classpath = sourceSets.test.runtimeClasspath
mainClass = 'zone.moddev.mc.skysbuildingpieces.AlignSoilModels'
workingDir = project.projectDir
}

def integrationTestClasses = layout.buildDirectory.dir('integration-test-mod/classes')
tasks.register('generateWallModels', JavaExec) {
group = 'build setup'
Expand Down Expand Up @@ -286,6 +295,9 @@ def prepareIntegrationTest = tasks.register('prepareIntegrationTest') {
into mods
}
new File(runDirectory, 'eula.txt').setText('eula=true\n', 'UTF-8')
['banned-players.json', 'banned-ips.json', 'ops.json', 'whitelist.json'].each { name ->
new File(runDirectory, name).setText('[]\n', 'UTF-8')
}
new File(runDirectory, 'server.properties').setText('''\
level-name=world
level-seed=skys-building-pieces-integration
Expand Down Expand Up @@ -599,6 +611,7 @@ ext.releaseFiles = releaseFiles
ext.releaseJar = releaseJar
apply from: 'gradle/release.gradle'


// Keep the old entry point disabled until publication is configured.
tasks.register('publishRelease') {
doLast { throw new GradleException('Publication is disabled for the local beta.') }
Expand Down Expand Up @@ -706,3 +719,10 @@ tasks.register('verifyEclipseProductionClasspath') {
tasks.named('check') {
dependsOn tasks.named('verifyReleaseMetadata')
}

// Optional native mods stay in a separate development folder and never enter the published jar.
ext.configureMineralogyVerificationRun = configureFromForgeRun
ext.mineralogyProfileProbeId = 'skysbuildingpieces'
ext.mineralogyProfileAdditionalMods = files()
apply from: 'gradle/mineralogy-runs.gradle'
apply from: 'gradle/mineralogy-fixtures.gradle'
31 changes: 31 additions & 0 deletions docs/BUILDING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# Building from source

Use Java 17 for Gradle and Temurin Java 8.0.502+7 for compilation and Minecraft.
Set `SBP_JAVA8_HOME` to that Java 8 installation, then run:

```text
gradlew clean check integrationTest build javadoc verifyReleaseArtifacts writeReleaseChecksums
gradlew genEclipseRuns verifyEclipseProductionClasspath
```

The main jar, sources and Javadocs are in `build/libs`. Tests and runtime probes
are separate from the published mod and ordinary Eclipse launches.

## Optional Mineralogy development runs

`runMineralogyClient` and `runMineralogyServer` use a separate `run-mineralogy`
folder. Supply the exact Mineralogy and OreSpawn jars listed in
`gradle/mineralogy-runtime.properties`; their checksums are checked before use.
You can select their locations with `-PmineralogyRuntimeJar=<jar>` and
`-PorespawnRuntimeJar=<jar>`. The default paths follow the sibling-checkout
layout used by the projects.

These jars are development inputs, not required dependencies. Neither is
bundled with Building Pieces. Normal builds and CI work without them.
`integrationMineralogyTest` runs the optional fresh-world and reload checks.

The former-add-on migration fixture also uses a matching Terrain Smoother
development jar. Build that project first, then run
`gradlew -PenableMineralogyFixtures=true prepareMineralogyFixture`.
The same option enables `prepareLegacyMineralogyWorld`. These fixtures are
opt-in and are not needed for ordinary builds or game launches.
12 changes: 9 additions & 3 deletions docs/CONFIGURATION.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,16 @@ configuration, generation or migration progress.

## Block-ID budget for modpacks

Building Pieces uses 236 block IDs: 235 building blocks and one hidden recovery
Without Mineralogy, Building Pieces uses 238 block IDs: 237 building blocks and one hidden recovery
holder. Materials share fixed metadata palettes so they don't each need a
separate block ID for every shape and orientation. Saved palette assignments
do not change between installations.

The matching Biomes O Plenty add-on uses another 66 IDs, for 302 combined.
These totals exclude blocks already registered by Minecraft and Biomes O Plenty.
The matching Biomes O Plenty add-on uses another 66 IDs, for 304 combined.
Mineralogy support adds 35 IDs only when Mineralogy is installed, for 273 core
IDs in that setup. The vanilla catalogue still uses 238 IDs. The optional rock
catalogue has its own fixed 35-ID budget; it does not change existing palettes.
These totals exclude blocks already registered by Minecraft, Biomes O Plenty
and Mineralogy.
With both Mineralogy and the BOP add-on installed, the combined Sky pieces use
339 IDs (238+35+66).
31 changes: 30 additions & 1 deletion docs/GAMEPLAY.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# Pieces and recipes

Mineralogy rock steps and corners are included automatically when Mineralogy
is installed. Three matching full rocks diagonally across the crafting grid
make twelve steps; two steps side by side make four corners. Vertical pairs
rebuild corners into steps and steps into Mineralogy's existing slabs.
Disabled native slab types are not used by recipes or smoothing. The rock
steps and corners remain craftable from full blocks.

The Sky's Building Pieces creative tab contains the mod's pieces and the
vanilla slab, stair, wall and pane items it reuses. Vertical slab items and old
templates stay hidden; use the regular slab for either placement direction.
Expand Down Expand Up @@ -51,6 +58,17 @@ also applies to supported BOP materials. A vertical pair keeps any existing
native decorative-block recipe. Smooth stone has no obtainable full block item
in this Minecraft version and therefore has no recombination recipe.

To rebuild larger pieces, put two matching corners one above the other to make
one step. Two matching steps in a column make one slab. This works in either
crafting grid and also covers the Building Pieces BOP add-on's materials.
Keep each pair the same material and item type; saved placement orientations
do not matter. Side-by-side steps still make four corners, and diagonal slabs
still make four steps.

Dirt and grass steps return the matching Grass Slabs item when that mod is
installed. Without it, ordinary dirt steps return the existing dirt vertical
slab. No new slabs are added for soil materials without a matching slab.

For raw stone, snow, decorative sandstone and mossy/cracked/chiseled stone brick
slabs, use two full blocks diagonally to make four slabs. Their full-block rows
already belong to native recipes, which remain unchanged.
Expand Down Expand Up @@ -92,11 +110,22 @@ do not combine. Some unions have no supported shape and cannot combine.

Grass shapes use biome colours and spread to ordinary dirt and matching dirt
pieces. Covered or dark grass becomes the matching dirt shape, retaining its
orientation. Grass pieces keep their grass-block support as dirt. With Grass
orientation. Steps and corners leave exposed ground grassy; pieces covering
the whole footprint keep dirt underneath. With Grass
Slabs 1.1 installed, spreading also works across its slabs and turf.
Plants and bonemeal need a complete upper supporting face. Nearby snow gives
soil and grass pieces a visual snow cap without changing their collision.

Use a compatible shovel on an uncovered ordinary dirt or grass step or corner
to make a path. The piece keeps its shape and orientation; only its exposed
top drops by one pixel. Each use costs one durability, except in creative mode.
Flattening a grass piece also turns an ordinary grass block directly beneath
it into a path. Both changes use that same durability point. Other supporting
blocks stay as they are.
Paths drop matching dirt pieces, even with Silk Touch. A solid block above a
path turns it back into the matching dirt shape. Coarse dirt, podzol and
mycelium are not converted. Grass Slabs still provides the full-width path slabs.

Without Grass Slabs, three ordinary dirt blocks in a column make six dirt vertical slabs.
Place them in any of the four directions; complementary halves combine
into a vanilla dirt block.
Expand Down
11 changes: 11 additions & 0 deletions docs/INTEGRATION.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,12 @@
Catalogue API version 1 remains supported. Register add-on catalogues during
pre-initialization as before; permanent palette slots must never be reassigned.

The JSON-array overload of `registerCatalogue` accepts resolved material and
palette definitions. Use it when a native mod can disable some shapes, without
changing the permanent piece palettes. A material can set
`fullBlockStepRecipe: true` to cut three diagonal full blocks into twelve
steps instead of using the usual two-slab recipe.

Building Pieces 0.3 also provides `BuildingPiecesApi.bottomPiece(material,
TerrainShape, direction)` after pre-initialization. It returns an existing block
state or `null` when that material has no such piece. It registers nothing.
Expand All @@ -12,3 +18,8 @@ west; corners use those directions for NW, NE, SE and SW respectively.
Sky's Terrain Smoother uses this lookup without depending on palette internals.
Building Pieces never generates terrain itself. It optionally joins Grass
Slabs 1.1's grass-form integration, but works without either mod installed.

Mineralogy is supported directly. Its presence adds 35 fixed rock-piece
palettes during pre-initialization; no add-on or compile-time Mineralogy
dependency is required. The original rocks, textures and slabs remain owned
by Mineralogy. Disabled native slabs are not used in recipes or smoothing.
17 changes: 17 additions & 0 deletions docs/RELEASE-0.3.7.110021.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Sky's Building Pieces 0.3.7 for Minecraft 1.10.2

Grass steps and corners now keep their grass and snow edges, with grass visible
on the exposed ground beneath them. Use a shovel to make matching path pieces;
ordinary grass directly underneath becomes a path in the same action.

You can rebuild larger pieces in the crafting grid: stack two matching corners
for a step, or two matching steps for a slab.

Mineralogy support is now built in. Install Mineralogy to get steps and corners
for its 27 natural rocks, using its own textures and existing slabs. Remove the
separate Mineralogy piece add-on if you used an earlier test build; its saved
pieces are recovered by the core mod.

Building Pieces still works on its own and does not generate terrain. For the
shared grass behaviour, use Sky's Grass Slabs 1.1.1.110021 or later. Back up an
existing world before updating mods.
5 changes: 3 additions & 2 deletions docs/RELEASING.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,9 @@ The MMD release workflow uses the organisation's `CURSEFORGE_TOKEN`,
It requires a passing CI build and explicit confirmation of live publication.
Enter the full release version and choose the CurseForge release level.

The first 0.3 releases are betas. Select `beta` for CurseForge and confirm live
publication after the branch's checks have passed.
Select the agreed CurseForge release level and confirm live publication after
the branch's checks have passed. A successful upload may still need CurseForge
approval before the file appears for players.

The workflow resolves the Minecraft branch from the version, rebuilds the exact
commit, and checks one immutable artifact bundle. It validates or creates the tag,
Expand Down
8 changes: 8 additions & 0 deletions docs/TRYING-THE-BETA.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Trying the beta

For Mineralogy, use the core jar with Mineralogy and its OreSpawn dependency.
Do not install the separate Mineralogy piece add-on from the earlier tests.
The generated `runMineralogyClient` Eclipse profile loads the native mods in
a separate development folder. Check rock textures, all step and corner
orientations, cutting recipes and rebuilding to the native slab.

Install the main jar in a Minecraft 1.10.2 Forge 12.18.3.2511 instance using
Java 8. The sources and Javadoc jars are not game mods. Start with a new
creative world; use a separate copy when trying an existing world.
Expand Down Expand Up @@ -31,6 +37,8 @@ Before relying on the beta in a modpack, check:
templates should not appear in creative inventory or crafting results.
- Check grass colours in several biomes, nearby snow, covered grass becoming
dirt, plant support, breaking drops and Silk Touch.
- Use a shovel on a grass step or corner above ordinary grass. Both should
become paths, with one durability point used. Check after saving and reloading.
- Check wall and pane connections and stair corners, including their collision.
- Place clear and stained-glass walls in rows, corners and junctions. The
straight sections should have no posts; ends, corners and junctions should.
Expand Down
6 changes: 6 additions & 0 deletions docs/WORLD-UPGRADES.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Existing worlds

The separate Mineralogy piece add-on from the earlier local tests is no longer
needed. Use Building Pieces with Mineralogy instead. Its test-save piece IDs
are recovered automatically, including item stacks in chunks opened after the
first upgrade save. Counts, metadata, names and other item data are retained.
Do not load the old add-on jar alongside the new core.

Test this beta on a disposable copy, never the only copy of a world.

BuildingBricks 1.10.2-2.0.13 stores many pieces using generic block IDs and
Expand Down
4 changes: 2 additions & 2 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ release_enabled=true
curseforge_project_id=1754162
mod_name=Sky's Building Pieces
mod_license=LGPL-2.1-only
mod_version=0.3.6.110021
mod_version=0.3.7.110021
mod_group=zone.moddev.mc.skysbuildingpieces
mod_authors=SkyBlade1978
mod_description=Vanilla building pieces with ordinary crafting recipes and optional legacy world recovery. No world generation.
mod_description=Extra building shapes for vanilla materials, with built-in Mineralogy support when installed. No world generation.
17 changes: 17 additions & 0 deletions gradle/development-log4j2.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<Configuration status="WARN">
<Appenders>
<Console name="Console" target="SYSTEM_OUT">
<PatternLayout pattern="[%d{HH:mm:ss}] [%t/%level] [%logger]: %msg%n"/>
</Console>
<File name="DevelopmentLog" fileName="logs/latest.log" append="false">
<PatternLayout pattern="[%d{HH:mm:ss}] [%t/%level] [%logger]: %msg%n"/>
</File>
</Appenders>
<Loggers>
<Root level="info">
<AppenderRef ref="Console"/>
<AppenderRef ref="DevelopmentLog"/>
</Root>
</Loggers>
</Configuration>
2 changes: 2 additions & 0 deletions gradle/mineralogy-catalogue-checksums.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
materials=572AE6C5744ED85FBA6F17E7017554157C9CFE37CDD7DE00117B703BD598BC08
palettes=75BE34621A9637D958070A5E850BE3CB1FA1D6CD1EFA1CA22695B743807BF12D
63 changes: 63 additions & 0 deletions gradle/mineralogy-fixtures.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
// Build-only checks for the former add-on's save format and real generated slopes.
// Neither these classes nor Terrain Smoother enter ordinary content-mod runs.

// Renamer attaches its outputs to assemble. Register this optional fixture only
// when requested, so a normal build does not need a sibling project's jar.
if (!providers.gradleProperty('enableMineralogyFixtures').getOrElse('false').toBoolean()) {
['prepareMineralogyFixture', 'prepareLegacyMineralogyWorld'].each { name ->
tasks.register(name) {
group = 'verification'
doLast {
throw new GradleException('Use -PenableMineralogyFixtures=true and build the matching Terrain Smoother development jar first.')
}
}
}
return
}
def smoother = file('../../SkysTerrainSmoother110/SkysTerrainSmoother')
def smootherJar = new File(smoother,
'build/libs-dev/SkysTerrainSmoother-0.1.0.110021-deobf.jar')
def fixtureClasses = layout.buildDirectory.dir('mineralogy-fixture/classes')
def compileFixture = tasks.register('compileMineralogyFixture', JavaCompile) {
group = 'verification'
dependsOn tasks.named('classes')
source fileTree('src/mineralogyTest/java')
source fileTree('src/integrationTest/java') { exclude '**/RuntimeProbe.java' }
classpath = files(sourceSets.main.output, sourceSets.main.compileClasspath, smootherJar)
destinationDirectory = fixtureClasses
options.encoding = 'UTF-8'
doFirst {
if (!smootherJar.isFile()) throw new GradleException('Build the matching Terrain Smoother development jar first.')
}
}
def fixtureJar = tasks.register('mineralogyFixtureJar', Jar) {
group = 'verification'
dependsOn compileFixture
archiveFileName = 'skysbuildingpieces-mineralogy-runtime-test.jar'
destinationDirectory = layout.buildDirectory.dir('mineralogy-fixture')
from fixtureClasses
}
def packagedFixture = renamer.classes(fixtureJar) {
map.from minecraft.dependency.toSrgFile
libraries.from tasks.named('jar', Jar).flatMap { it.archiveFile }
libraries.from sourceSets.main.compileClasspath
libraries.from smootherJar
output = layout.buildDirectory.file('mineralogy-fixture/skysbuildingpieces-mineralogy-runtime-test-reobf.jar')
}
tasks.register('prepareMineralogyFixture') {
group = 'verification'
dependsOn packagedFixture
}

tasks.register('prepareLegacyMineralogyWorld', JavaExec) {
group = 'verification'
dependsOn compileFixture
classpath = files(fixtureClasses, sourceSets.main.runtimeClasspath)
mainClass = 'zone.moddev.mc.skysbuildingpieces.mineralogytest.FixtureTool'
doFirst {
if (!providers.gradleProperty('legacyMineralogyFixture').isPresent()) {
throw new GradleException('Supply a marked disposable world copy with -PlegacyMineralogyFixture=<path>.')
}
args providers.gradleProperty('legacyMineralogyFixture').get(), project.minecraft_version.toString()
}
}
Loading
Loading