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
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 15 additions & 15 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
name: Base Metals 1.14.4 CI
name: Base Metals 1.15.2 CI

on:
push:
branches:
- master-1.14.4
- master-1.15.2
- 'feature/**'
pull_request:
branches:
- master-1.14.4
- master-1.15.2

permissions:
contents: read

concurrency:
group: basemetals-1.14-${{ github.workflow }}-${{ github.ref }}
group: basemetals-1.15-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
Expand Down Expand Up @@ -141,9 +141,9 @@ jobs:
./gradlew "${gradle_args[@]}"
first="$RUNNER_TEMP/basemetals-first"
mkdir -p "$first"
cp build/libs/BaseMetals-3.0.1.114041.jar "$first/"
cp build/libs/BaseMetals-3.0.1.114041-sources.jar "$first/"
cp build/libs/BaseMetals-3.0.1.114041-javadoc.jar "$first/"
cp build/libs/BaseMetals-3.0.1.115021.jar "$first/"
cp build/libs/BaseMetals-3.0.1.115021-sources.jar "$first/"
cp build/libs/BaseMetals-3.0.1.115021-javadoc.jar "$first/"
cp build/release/SHA256SUMS "$first/"

- name: Rebuild and prove byte-identical archives
Expand All @@ -159,9 +159,9 @@ jobs:
-Dorg.gradle.java.installations.auto-download=false
)
./gradlew "${gradle_args[@]}"
cmp "$RUNNER_TEMP/basemetals-first/BaseMetals-3.0.1.114041.jar" build/libs/BaseMetals-3.0.1.114041.jar
cmp "$RUNNER_TEMP/basemetals-first/BaseMetals-3.0.1.114041-sources.jar" build/libs/BaseMetals-3.0.1.114041-sources.jar
cmp "$RUNNER_TEMP/basemetals-first/BaseMetals-3.0.1.114041-javadoc.jar" build/libs/BaseMetals-3.0.1.114041-javadoc.jar
cmp "$RUNNER_TEMP/basemetals-first/BaseMetals-3.0.1.115021.jar" build/libs/BaseMetals-3.0.1.115021.jar
cmp "$RUNNER_TEMP/basemetals-first/BaseMetals-3.0.1.115021-sources.jar" build/libs/BaseMetals-3.0.1.115021-sources.jar
cmp "$RUNNER_TEMP/basemetals-first/BaseMetals-3.0.1.115021-javadoc.jar" build/libs/BaseMetals-3.0.1.115021-javadoc.jar
cmp "$RUNNER_TEMP/basemetals-first/SHA256SUMS" build/release/SHA256SUMS

- name: Run exact-OreSpawn dedicated-server probe
Expand All @@ -181,21 +181,21 @@ jobs:
- name: Upload audited release candidate
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7
with:
name: BaseMetals-1.14.4-${{ github.sha }}
name: BaseMetals-1.15.2-${{ github.sha }}
if-no-files-found: error
retention-days: 30
path: |
build/libs/BaseMetals-3.0.1.114041.jar
build/libs/BaseMetals-3.0.1.114041-sources.jar
build/libs/BaseMetals-3.0.1.114041-javadoc.jar
build/libs/BaseMetals-3.0.1.115021.jar
build/libs/BaseMetals-3.0.1.115021-sources.jar
build/libs/BaseMetals-3.0.1.115021-javadoc.jar
build/release/SHA256SUMS
CHANGELOG.txt

- name: Upload bounded diagnostics on failure
if: failure()
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7
with:
name: BaseMetals-1.14.4-diagnostics-${{ github.sha }}
name: BaseMetals-1.15.2-diagnostics-${{ github.sha }}
if-no-files-found: ignore
retention-days: 14
path: |
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@ name: CodeQL
on:
push:
branches:
- master-1.14.4
- master-1.15.2
- 'feature/**'
pull_request:
branches:
- master-1.14.4
- master-1.15.2
schedule:
- cron: '37 7 * * 4'

Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/validate-gradle-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@ name: Validate Gradle Wrapper
on:
push:
branches:
- master-1.14.4
- master-1.15.2
- 'feature/**'
pull_request:
branches:
- master-1.14.4
- master-1.15.2

permissions:
contents: read
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ out
# gradle
build
.gradle
.local-gradle.properties

# other
eclipse
Expand Down
17 changes: 17 additions & 0 deletions CHANGELOG.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,20 @@
Base Metals 3.0.1.115021

- Bring Base Metals to Minecraft 1.15.2 and Forge 31.2.57.
- Update ore overlays, metal bars, doors, trapdoors and molten fluids for
Minecraft 1.15's rendering changes.
- Keep bows firing arrows and crossbows firing bolts, including the free iron
bolt used when firing without ammunition in Creative mode.
- Keep material arrows and bolts visible in flight and when stuck in a target.
- Keep the 1.14 recipes, equipment effects, configuration screens, smith trades and village loot.
- Preserve Kiri's ore overlays and their resource-pack-aware vanilla backgrounds.
- Support upgrades from Cyano and MMD 1.10, MMD 1.12, and the 1.13 and 1.14
ports, keeping existing blocks, items, equipment and saved data.
- Keep ForgeGradle 7 and Java 8 game compatibility. Builds and IDE launches
keep test code separate from the mod.
- Use the published OreSpawn 4.1.0.115021 release for ore placement. The eleven
ore rules and their defaults are unchanged.

Base Metals 3.0.1.114041

- Bring the finished 1.13.2 port to Minecraft 1.14.4 and Forge 28.2.26.
Expand Down
53 changes: 31 additions & 22 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,36 +1,36 @@
[![Discord](https://img.shields.io/badge/Discord-MMD-green.svg?style=flat&logo=Discord)](https://discord.moddev.zone)
[![CurseForge downloads](https://cf.way2muchnoise.eu/full_base-metals_downloads.svg)](https://www.curseforge.com/minecraft/mc-mods/base-metals)
[![Supported Minecraft versions](https://cf.way2muchnoise.eu/versions/Minecraft_base-metals_all.svg)](https://www.curseforge.com/minecraft/mc-mods/base-metals)
[![Build, test, and audit](https://github.com/MinecraftModDevelopmentMods/BaseMetals/actions/workflows/ci.yml/badge.svg?branch=master-1.14.4)](https://github.com/MinecraftModDevelopmentMods/BaseMetals/actions/workflows/ci.yml?query=branch%3Amaster-1.14.4)
[![Build, test, and audit](https://github.com/MinecraftModDevelopmentMods/BaseMetals/actions/workflows/ci.yml/badge.svg?branch=master-1.15.2)](https://github.com/MinecraftModDevelopmentMods/BaseMetals/actions/workflows/ci.yml?query=branch%3Amaster-1.15.2)

# Base Metals

Base Metals adds historically common metals, useful alloys, and fantasy metals
to Minecraft. Depending on the material, these are available as ores, storage
Base Metals adds real and fantasy metals, along with useful alloys, to
Minecraft. Depending on the material, these are available as ores, storage
and decorative blocks, molten fluids, crafting components, tools, armour,
shields, bows, crossbows, arrows, and bolts. The mod also includes Crack
Hammers, scythes, metal anvils, the human detector, villager trades,
advancements, and extra loot to find in chests.

This is the Minecraft 1.14.4 version, `3.0.1.114041`, continued from the finished
1.13.2 port. It keeps the historical `basemetals` block and item IDs, but no longer
needs MMDLib or Additional Loot Tables. OreSpawn places the ores, and Base
Metals supplies the metals and their recipes.
This is Base Metals `3.0.1.115021` for Minecraft 1.15.2. It brings the 1.14.4
release forward while keeping the same blocks, items and recipes. MMDLib and
Additional Loot Tables are no longer needed. OreSpawn places the ores, and
Base Metals supplies the metals and their recipes.

Ores use vanilla stone, netherrack and end-stone textures beneath Kiri's ore
overlays, so resource packs can change their surroundings without making the
ores look out of place. Smith trades and village chest loot use the new
ores look out of place. Smith trades and village chest loot use the
Armorer, Weaponsmith and Toolsmith professions introduced in Minecraft 1.14.

## Requirements

- Minecraft `1.14.4`
- Forge `28.2.26`
- Minecraft `1.15.2`
- Forge `31.2.57`
- Java 8
- OreSpawn `[4.1.0.114041,5.0.0)` on both client and server
- OreSpawn `[4.1.0.115021,5.0.0)` on both client and server

Put `BaseMetals-3.0.1.114041.jar` and OreSpawn `4.1.0.114041` (or a later
compatible OreSpawn 4 build for 1.14.4) in the `mods` directory. MMDLib and
Put `BaseMetals-3.0.1.115021.jar` and OreSpawn `4.1.0.115021` (or a later
compatible OreSpawn 4 build for 1.15.2) in the `mods` directory. MMDLib and
Additional Loot Tables are not dependencies. Mineralogy is optional.

## Materials and gameplay
Expand Down Expand Up @@ -122,13 +122,14 @@ items in containers are protected too.

Always perform the first upgrade on a copy of the world and keep the untouched
original. Read [Migration](docs/MIGRATION.md) before opening an old save. A
world already upgraded to Minecraft 1.15 or later must not be opened in this
older version. Worlds from the Base Metals 1.13.2 port can be upgraded normally.
world already upgraded to Minecraft 1.16 or later must not be opened in this
older version. Worlds from the Base Metals 1.13.2 and 1.14.4 ports can be
upgraded normally.

## Compatibility

Forge item, block, and fluid tags are Base Metals' public compatibility API.
The 1.14.4 line deliberately contains no version-specific Mekanism, Thermal,
The 1.15.2 line deliberately contains no version-specific Mekanism, Thermal,
Tinkers' Construct, Ender IO, IC2, or Thaumcraft plugin code. Compatible mods
can consume the common tags without linking to Base Metals internals. See
[Compatibility](docs/COMPATIBILITY.md) and [Supported versions](docs/VERSIONS.md).
Expand Down Expand Up @@ -174,7 +175,7 @@ Generate and verify Eclipse launches with:
```

Release candidates can also be exercised as packaged mods in prepared official
Forge 28 client and server runtimes with `packagedRuntimeIntegrationTest`; pass
Forge 31 client and server runtimes with `packagedRuntimeIntegrationTest`; pass
their directories through the `packagedForgeClientRuntime` and
`packagedForgeServerRuntime` Gradle properties. These probes load the exact
release JAR and OreSpawn dependency, create real worlds, validate client models
Expand All @@ -184,18 +185,26 @@ and colours, and remain outside the published artifact.
content modes, old configuration files, client/server matching and mismatch
messages in disposable multiplayer profiles.

`packagedMineralogyIntegrationTest` checks ore placement alongside Mineralogy.
It uses the server runtime above and a `mineralogyTestJar` property pointing to
the qualified Mineralogy 1.15.2 JAR. Mineralogy remains optional for players.

CI checks a fresh Forge setup, unit tests, generated files, a dedicated server
with the pinned OreSpawn release, release-JAR contents, checksums, reproducible
builds, CodeQL, wrapper validation, and Eclipse classpath isolation. Test probes
and historical fixtures are excluded from the published JAR.

Development and CI use the published
[OreSpawn 4.1.0.114041 release](https://www.curseforge.com/minecraft/mc-mods/mmd-orespawn/files/9041431)
from CurseMaven. The build checks its exact file ID and SHA-256 before release
auditing and packaged tests; no local OreSpawn build is needed.
Builds use the published [OreSpawn `4.1.0.115021` release](https://www.curseforge.com/minecraft/mc-mods/mmd-orespawn/files/9073591)
through Curse Maven. No sibling checkout or local candidate repository is
needed. The build verifies the download's checksum, Minecraft version and
configuration-screen API.

CI stages that same download with `gradle/stage-orespawn-release.sh` and passes
the temporary repository through `orespawnVerificationRepository`. Local
candidate builds remain guarded against publication.

Release artifacts use Maven coordinate
`zone.moddev.mc.basemetals:BaseMetals:3.0.1.114041`.
`zone.moddev.mc.basemetals:BaseMetals:3.0.1.115021`.

Report defects through the
[Base Metals issue tracker](https://github.com/MinecraftModDevelopmentMods/BaseMetals/issues).
Expand Down
39 changes: 32 additions & 7 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,16 @@ group = project.mod_group
version = project.mod_version
base.archivesName = 'BaseMetals'

// Keep local candidate paths out of version control and Eclipse's public setup.
File localPropertiesFile = file('.local-gradle.properties')
if (localPropertiesFile.isFile()) {
Properties localProperties = new Properties()
localPropertiesFile.withInputStream { localProperties.load(it) }
localProperties.each { key, value ->
if (!project.hasProperty(key.toString())) project.ext.set(key.toString(), value)
}
}

def eclipseWorkspaceProjectName = projectDir.name
def expectedMavenGroup = 'zone.moddev.mc.basemetals'
def expectedMavenArtifact = 'BaseMetals'
Expand Down Expand Up @@ -113,7 +123,7 @@ def mainModClasses = "${mod_id}%%${forgeMainOutputPath}${File.pathSeparator}${mo
def forgeProbeOutputPath = integrationTestModClassesDirectory.get().asFile.absolutePath
def probeModClasses = mainModClasses + "${File.pathSeparator}basemetalsprobe%%${forgeProbeOutputPath}" +
"${File.pathSeparator}basemetalsprobe%%${forgeProbeOutputPath}"
def forge28RunTargets = [client: 'fmluserdevclient', server: 'fmluserdevserver',
def forge31RunTargets = [client: 'fmluserdevclient', server: 'fmluserdevserver',
data: 'fmluserdevdata', runtimeProbeServer: 'fmluserdevserver', legacyUpgradeServer: 'fmluserdevserver']

minecraft {
Expand All @@ -126,7 +136,7 @@ minecraft {
systemProperty 'forge.logging.markers', 'REGISTRIES'
systemProperty 'forge.logging.console.level', 'info'
mods { basemetals { source sourceSets.main } }
environment 'target', forge28RunTargets[name]
environment 'target', forge31RunTargets[name]
environment 'MCP_MAPPINGS', "${mapping_channel}_${mapping_version}"
environment 'MCP_VERSION', mcp_version
environment 'FORGE_VERSION', forge_version
Expand Down Expand Up @@ -172,7 +182,7 @@ def prepareIntegrationTestModClasses = tasks.register('prepareIntegrationTestMod
}

tasks.withType(JavaExec).configureEach { JavaExec runTask ->
def runName = forge28RunTargets.keySet().find { runTask.name == 'run' + it.capitalize() }
def runName = forge31RunTargets.keySet().find { runTask.name == 'run' + it.capitalize() }
if (runName != null) {
runTask.dependsOn prepareForgeRunModClasses
if (runTask.name in ['runRuntimeProbeServer', 'runLegacyUpgradeServer']) {
Expand All @@ -190,7 +200,15 @@ tasks.withType(JavaExec).configureEach { JavaExec runTask ->

def orespawnModule = "mmd-orespawn-${project.orespawn_curse_project_id}"
def orespawnVerificationRepository = project.findProperty('orespawnVerificationRepository')
def orespawnCoordinate = "curse.maven:${orespawnModule}:${orespawn_curse_file_id}"
def orespawnCandidate = project.orespawn_dependency_mode == 'candidate'
def orespawnCandidateRepository = project.findProperty('orespawnCandidateRepository')
if (orespawnCandidate && orespawnCandidateRepository == null) {
throw new GradleException('Local qualification needs -PorespawnCandidateRepository=<staged Maven repository>. ' +
'You may also set it in the ignored .local-gradle.properties file.')
}
def orespawnCoordinate = orespawnCandidate
? "zone.moddev.mc.orespawn:OreSpawn:${orespawn_version}"
: "curse.maven:${orespawnModule}:${orespawn_curse_file_id}"
repositories {
minecraft.mavenizer(it)
maven fg.forgeMaven
Expand All @@ -204,13 +222,17 @@ repositories {
exclusiveContent {
forRepository {
maven {
name = orespawnVerificationRepository == null ? 'CurseMaven' : 'OreSpawnReleaseVerificationMirror'
url = orespawnVerificationRepository == null
name = orespawnCandidate ? 'OreSpawnLocalCandidate' : 'OreSpawnReleaseVerificationMirror'
url = orespawnCandidate ? uri(orespawnCandidateRepository)
: orespawnVerificationRepository == null
? uri('https://www.cursemaven.com') : uri(orespawnVerificationRepository)
metadataSources { artifact() }
}
}
filter { includeModule('curse.maven', orespawnModule) }
filter {
if (orespawnCandidate) includeModule('zone.moddev.mc.orespawn', 'OreSpawn')
else includeModule('curse.maven', orespawnModule)
}
}
}

Expand All @@ -225,6 +247,7 @@ dependencies {
renamer.mappings.from minecraft.dependency.toSrgFile
configurations.named('testRuntimeClasspath') {
exclude group: 'curse.maven', module: orespawnModule
exclude group: 'zone.moddev.mc.orespawn', module: 'OreSpawn'
}

tasks.named('processResources', ProcessResources) {
Expand Down Expand Up @@ -253,6 +276,7 @@ tasks.named('jar', Jar) {
'Specification-Version': '1', 'Implementation-Title': 'Base Metals',
'Implementation-Version': project.version, 'Implementation-Vendor': project.mod_authors,
'Built-On-Java': '8', 'Built-On': "${project.minecraft_version}-${project.forge_version}",
'OreSpawn-Dependency-Mode': project.orespawn_dependency_mode,
'Build-Target': "minecraft-${project.minecraft_version}-${project.loader_name}-" +
"${project.forge_version}-java-${project.java_version}"])
}
Expand All @@ -279,6 +303,7 @@ ext.baseMetalsBuild = [
expectedMavenArtifact: expectedMavenArtifact,
expectedMavenCoordinate: expectedMavenCoordinate,
eclipseWorkspaceProjectName: eclipseWorkspaceProjectName,
orespawnCandidate: orespawnCandidate,
prepareIntegrationTestModClasses: prepareIntegrationTestModClasses,
releaseJar: releaseJar
]
Expand Down
4 changes: 2 additions & 2 deletions docs/COMPATIBILITY.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@ ores, crystals, shards, clumps, dirty dusts, and molten fluids.
Adamantite, Adamantium, Adamant, Quicksilver, and steel-sprocket names are
forwarding tags. Copper-consuming recipes accept `forge:ingots/copper`, except
Base Metals' own compacting and decompacting recipes, whose output must remain
the Base Metals item. On Minecraft 1.14.4 the copper ore, ingot, and storage
the Base Metals item. On Minecraft 1.15.2 the copper ore, ingot, and storage
tags contain Base Metals entries; other mods can add their equivalents through
normal tag merging.

This version has no mod-specific plugins for Mekanism, Thermal Expansion, Tinkers'
Construct, Ender IO, IC2, Thaumcraft, Dense Ores, VeinMiner, or Constructs
Armory. Their version-specific 1.18 data and APIs are not valid on Forge
28. Generic processors and tools can interoperate through Forge tags.
31. Generic processors and tools can interoperate through Forge tags.

Mineralogy is optional. When installed, OreSpawn can place the same ores in
Mineralogy's rocks. Base Metals does not need Mineralogy to run.
Expand Down
Loading
Loading