mirror of
https://github.com/Creators-of-Create/Create.git
synced 2025-03-03 22:34:42 +01:00
A new era
- Switch to MDG instead of using FG - Implement CI-based mod publishing - Embed commit hash into the built jar - Log commit hash
This commit is contained in:
parent
d567f76e5e
commit
a962ade027
21 changed files with 445 additions and 481 deletions
65
.github/ISSUE_TEMPLATE/bug.yml
vendored
65
.github/ISSUE_TEMPLATE/bug.yml
vendored
|
@ -2,40 +2,37 @@ name: I found a bug!
|
|||
description: "Report some other kind of issue. You should ask in the Discord first to make sure it's actually a bug with Create."
|
||||
labels: [ "type: bug" ]
|
||||
body:
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Description
|
||||
description: "
|
||||
Please describe the issue with as much detail as possible.
|
||||
Explain what happened, and what should have happened instead.
|
||||
Add images, screenshots, or videos if they could be useful."
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Description
|
||||
description: >
|
||||
Please describe the issue with as much detail as possible.
|
||||
Explain what happened, and what should have happened instead.
|
||||
Add images, screenshots, or videos if they could be useful.
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: input
|
||||
attributes:
|
||||
label: Game Log
|
||||
description: "
|
||||
We need the game log for additional information about the bug.
|
||||
This file can be found in the \"logs\" folder of your Minecraft folder as \"latest.log\".
|
||||
Please upload the file to https://mclo.gs/ and put the link here.
|
||||
Do **not** paste the *contents* of the file here, because that will make this issue very hard to read.
|
||||
"
|
||||
validations:
|
||||
required: true
|
||||
- type: input
|
||||
attributes:
|
||||
label: Game Log
|
||||
description: >
|
||||
We need the game log for additional information about the bug.
|
||||
This file can be found in the \"logs\" folder of your Minecraft folder as \"latest.log\".
|
||||
Please upload the file to https://mclo.gs/ and put the link here.
|
||||
Do **not** paste the *contents* of the file here, because that will make this issue very hard to read.
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Debug Information
|
||||
description: "
|
||||
Please run the \"/create debuginfo\" command in-game.
|
||||
This will copy useful information to your clipboard that will greatly help with debugging.
|
||||
Please paste this information here.
|
||||
If this command does not exist, you can skip this part.
|
||||
"
|
||||
validations:
|
||||
required: false
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Debug Information
|
||||
description: >
|
||||
Please run the \"/create debuginfo\" command in-game.
|
||||
This will copy useful information to your clipboard that will greatly help with debugging.
|
||||
Please paste this information here.
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: "Thank you for taking the time to make a report and help improve Create!"
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: "Thank you for taking the time to make a report and help improve Create!"
|
||||
|
|
18
.github/ISSUE_TEMPLATE/config.yml
vendored
18
.github/ISSUE_TEMPLATE/config.yml
vendored
|
@ -1,11 +1,11 @@
|
|||
blank_issues_enabled: true
|
||||
contact_links:
|
||||
- name: I have a question!
|
||||
url: https://discord.gg/hmaD7Se
|
||||
about: Join us on Discord and ask the community.
|
||||
- name: I have a suggestion or idea!
|
||||
url: https://discord.gg/hmaD7Se
|
||||
about: These are best discussed with the community and submitted on Discord.
|
||||
- name: Talk to us on Discord.
|
||||
url: https://discord.gg/hmaD7Se
|
||||
about: Ask questions and get help from the community.
|
||||
- name: I have a question!
|
||||
url: https://discord.gg/hmaD7Se
|
||||
about: Join us on Discord and ask the community.
|
||||
- name: I have a suggestion or idea!
|
||||
url: https://discord.gg/hmaD7Se
|
||||
about: These are best discussed with the community and submitted on Discord.
|
||||
- name: Talk to us on Discord.
|
||||
url: https://discord.gg/hmaD7Se
|
||||
about: Ask questions and get help from the community.
|
||||
|
|
41
.github/ISSUE_TEMPLATE/crash.yml
vendored
41
.github/ISSUE_TEMPLATE/crash.yml
vendored
|
@ -2,26 +2,25 @@ name: My game crashed!
|
|||
description: Report an issue that crashes the game.
|
||||
labels: [ "type: crash" ]
|
||||
body:
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Context
|
||||
description: What were you doing when the game crashed? Add images, screenshots, or videos if they could be useful.
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Context
|
||||
description: What were you doing when the game crashed? Add images, screenshots, or videos if they could be useful.
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: input
|
||||
attributes:
|
||||
label: Crash Report
|
||||
description: "
|
||||
We need the crash report to figure out why the crash happened.
|
||||
This file can be found in the \"crash-reports\" folder of your Minecraft folder.
|
||||
It will be the newest file there.
|
||||
Please upload the file to https://mclo.gs/ and put the link here.
|
||||
Do **not** paste the *contents* of the file here, because that will make this issue very hard to read.
|
||||
"
|
||||
validations:
|
||||
required: true
|
||||
- type: input
|
||||
attributes:
|
||||
label: Crash Report
|
||||
description: >
|
||||
We need the crash report to figure out why the crash happened.
|
||||
This file can be found in the \"crash-reports\" folder of your Minecraft folder.
|
||||
It will be the newest file there.
|
||||
Please upload the file to https://mclo.gs/ and put the link here.
|
||||
Do **not** paste the *contents* of the file here, because that will make this issue very hard to read.
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: "Thank you for taking the time to make a report and help improve Create!"
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: "Thank you for taking the time to make a report and help improve Create!"
|
||||
|
|
68
.github/config/label-actions.yml
vendored
68
.github/config/label-actions.yml
vendored
|
@ -3,53 +3,53 @@
|
|||
# ----------------------------------- ISSUES ----------------------------------- #
|
||||
|
||||
'env: fabric':
|
||||
issues:
|
||||
close: true
|
||||
close-reason: 'not planned'
|
||||
comment: >
|
||||
**Fabric Loader**: This issue tracker is only for the Forge/NeoForge versions of Create. Since you mentioned using Fabric Loader, please reopen this issue on the [Create Fabric issue tracker](https://github.com/Fabricators-of-Create/Create/issues). Thanks!
|
||||
issues:
|
||||
close: true
|
||||
close-reason: 'not planned'
|
||||
comment: >
|
||||
**Fabric Loader**: This issue tracker is only for the Forge/NeoForge versions of Create. Since you mentioned using Fabric Loader, please reopen this issue on the [Create Fabric issue tracker](https://github.com/Fabricators-of-Create/Create/issues). Thanks!
|
||||
|
||||
'env: hybrid server':
|
||||
issues:
|
||||
close: true
|
||||
close-reason: 'not planned'
|
||||
comment: >
|
||||
**Hybrid Server Software**: Create cannot reasonably support hybrid server software, such as [MohistMC](https://mohistmc.com/), as their changes under the hood make it difficult for larger mods to function properly. If you encounter this issue on official Forge/NeoForge server software, feel free to open a new issue. Otherwise, consider reporting this issue to the hybrid server software you are using. Thanks!
|
||||
issues:
|
||||
close: true
|
||||
close-reason: 'not planned'
|
||||
comment: >
|
||||
**Hybrid Server Software**: Create cannot reasonably support hybrid server software, such as [MohistMC](https://mohistmc.com/), as their changes under the hood make it difficult for larger mods to function properly. If you encounter this issue on official Forge/NeoForge server software, feel free to open a new issue. Otherwise, consider reporting this issue to the hybrid server software you are using. Thanks!
|
||||
|
||||
'env: outdated create version':
|
||||
issues:
|
||||
close: true
|
||||
close-reason: 'not planned'
|
||||
comment: >
|
||||
**Outdated Create Version**: Since you are using an outdated Create version, please update to the latest version as it may resolve your issue. If this issue persists after updating Create, feel free to open a new issue. Thanks!
|
||||
issues:
|
||||
close: true
|
||||
close-reason: 'not planned'
|
||||
comment: >
|
||||
**Outdated Create Version**: Since you are using an outdated Create version, please update to the latest version as it may resolve your issue. If this issue persists after updating Create, feel free to open a new issue. Thanks!
|
||||
|
||||
'env: pojav':
|
||||
issues:
|
||||
close: true
|
||||
close-reason: 'not planned'
|
||||
comment: >
|
||||
**Pojav**: Create does not support Pojav or other mobile launchers due to rendering limitations. If you encounter this issue on a PC, feel free to open a new issue. Thanks!
|
||||
issues:
|
||||
close: true
|
||||
close-reason: 'not planned'
|
||||
comment: >
|
||||
**Pojav**: Create does not support Pojav or other mobile launchers due to rendering limitations. If you encounter this issue on a PC, feel free to open a new issue. Thanks!
|
||||
|
||||
'env: unsupported minecraft version':
|
||||
issues:
|
||||
close: true
|
||||
close-reason: 'not planned'
|
||||
comment: >
|
||||
**Unsupported Minecraft Version**: Unsupported Minecraft versions no longer receive Create updates. Please check the [supported Minecraft versions](https://github.com/Creators-of-Create/Create/wiki/dev.status). If you encounter this issue on a supported Minecraft version, feel free to open a new issue. Thanks!
|
||||
issues:
|
||||
close: true
|
||||
close-reason: 'not planned'
|
||||
comment: >
|
||||
**Unsupported Minecraft Version**: Unsupported Minecraft versions no longer receive Create updates. Please check the [supported Minecraft versions](https://github.com/Creators-of-Create/Create/wiki/dev.status). If you encounter this issue on a supported Minecraft version, feel free to open a new issue. Thanks!
|
||||
|
||||
# ----------------------------------- PULL REQUESTS ----------------------------------- #
|
||||
|
||||
'pr status: conflicts':
|
||||
prs:
|
||||
comment: >
|
||||
@{issue-author}, this pull request has merge conflicts with the target branch. Please merge the latest changes and leave a message here so we can continue with the process of reviewing and merging this pull request. Thanks!
|
||||
prs:
|
||||
comment: >
|
||||
@{issue-author}, this pull request has merge conflicts with the target branch. Please merge the latest changes and leave a message here so we can continue with the process of reviewing and merging this pull request. Thanks!
|
||||
|
||||
'pr status: waiting for author':
|
||||
prs:
|
||||
comment: >
|
||||
@{issue-author}, a developer has left a review and requested changes. Please make the requested changes or further discuss them with the developer so this pull request can be merged. Thanks!
|
||||
prs:
|
||||
comment: >
|
||||
@{issue-author}, a developer has left a review and requested changes. Please make the requested changes or further discuss them with the developer so this pull request can be merged. Thanks!
|
||||
|
||||
'pr status: wrong target':
|
||||
prs:
|
||||
comment: >
|
||||
@{issue-author}, this pull request is targeting the wrong branch. Pull requests should target the branch corresponding to the earliest supported Minecraft version unless the changes are specific to code that only exists for a newer Minecraft version. Please change the target branch, resolve any merge conflicts, and leave a message here so we can continue with the process of reviewing and merging this pull request. Thanks!
|
||||
prs:
|
||||
comment: >
|
||||
@{issue-author}, this pull request is targeting the wrong branch. Pull requests should target the branch corresponding to the earliest supported Minecraft version unless the changes are specific to code that only exists for a newer Minecraft version. Please change the target branch, resolve any merge conflicts, and leave a message here so we can continue with the process of reviewing and merging this pull request. Thanks!
|
||||
|
|
23
.github/workflows/gametest.yml
vendored
23
.github/workflows/gametest.yml
vendored
|
@ -1,23 +0,0 @@
|
|||
name: gametest
|
||||
on: [ workflow_dispatch ]
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
|
||||
- name: checkout repository
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: setup Java
|
||||
uses: actions/setup-java@v3
|
||||
with:
|
||||
distribution: temurin
|
||||
java-version: 17
|
||||
cache: gradle
|
||||
|
||||
- name: make gradle wrapper executable
|
||||
run: chmod +x ./gradlew
|
||||
|
||||
- name: run gametests
|
||||
run: ./gradlew prepareRunGameTestServer runGameTestServer --no-daemon
|
32
.github/workflows/label-actions.yml
vendored
32
.github/workflows/label-actions.yml
vendored
|
@ -1,21 +1,21 @@
|
|||
name: "Label Actions"
|
||||
name: Label Actions
|
||||
on:
|
||||
issues:
|
||||
types: [labeled, unlabeled]
|
||||
pull_request_target:
|
||||
types: [labeled, unlabeled]
|
||||
issues:
|
||||
types: [ labeled, unlabeled ]
|
||||
pull_request_target:
|
||||
types: [ labeled, unlabeled ]
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
issues: write
|
||||
pull-requests: write
|
||||
discussions: write
|
||||
contents: read
|
||||
issues: write
|
||||
pull-requests: write
|
||||
discussions: write
|
||||
|
||||
jobs:
|
||||
action:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: dessant/label-actions@102faf474a544be75fbaf4df54e73d3c515a0e65 # Depend on an exact commit
|
||||
with:
|
||||
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
config-path: '.github/config/label-actions.yml'
|
||||
action:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: dessant/label-actions@102faf474a544be75fbaf4df54e73d3c515a0e65 # Depend on an exact commit
|
||||
with:
|
||||
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
config-path: '.github/config/label-actions.yml'
|
||||
|
|
66
.github/workflows/localization.yml
vendored
66
.github/workflows/localization.yml
vendored
|
@ -1,48 +1,32 @@
|
|||
# This workflow will run Crowdin Action that will upload new texts to Crowdin, download the newest translations and create a PR
|
||||
# For more information see: https://github.com/crowdin/github-action
|
||||
|
||||
name: Crowdin Action
|
||||
|
||||
# Controls when the action will run.
|
||||
on: workflow_dispatch
|
||||
# Only run when started manually
|
||||
|
||||
#:
|
||||
# inputs:
|
||||
# uploadTranslations:
|
||||
# description: "Set to true to upload (changed) translations to Crowdin"
|
||||
# type: boolean
|
||||
# required: true
|
||||
# default: false
|
||||
|
||||
#schedule:
|
||||
#- cron: '0 */6 * * *' # Every 6 hours - https://crontab.guru/#0_*/6_*_*_*
|
||||
|
||||
jobs:
|
||||
synchronize-with-crowdin:
|
||||
runs-on: ubuntu-latest
|
||||
synchronize-with-crowdin:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v2
|
||||
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- name: crowdin action
|
||||
uses: crowdin/github-action@1.4.9
|
||||
with:
|
||||
# Upload sources to Crowdin
|
||||
upload_sources: true
|
||||
# Upload translations to Crowdin, only use true at initial run
|
||||
upload_translations: false
|
||||
# Make pull request of Crowdin translations
|
||||
download_translations: true
|
||||
# To download translations to the specified version branch
|
||||
localization_branch_name: l10n_crowdin_translations
|
||||
# Create pull request after pushing to branch
|
||||
create_pull_request: true
|
||||
pull_request_title: 'New Crowdin translations'
|
||||
pull_request_body: 'New Crowdin pull request with translations'
|
||||
pull_request_base_branch_name: 'mc1.20.1/dev'
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
|
||||
CROWDIN_PROJECT_ID: ${{ secrets.CROWDIN_PROJECT_ID }}
|
||||
CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_PERSONAL_TOKEN }}
|
||||
- name: crowdin action
|
||||
uses: crowdin/github-action@1.4.9
|
||||
with:
|
||||
# Upload sources to Crowdin
|
||||
upload_sources: true
|
||||
# Upload translations to Crowdin, only use true at initial run
|
||||
upload_translations: false
|
||||
# Make pull request of Crowdin translations
|
||||
download_translations: true
|
||||
# To download translations to the specified version branch
|
||||
localization_branch_name: l10n_crowdin_translations
|
||||
# Create pull request after pushing to branch
|
||||
create_pull_request: true
|
||||
pull_request_title: 'New Crowdin translations'
|
||||
pull_request_body: 'New Crowdin pull request with translations'
|
||||
pull_request_base_branch_name: 'mc1.20.1/dev'
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
|
||||
CROWDIN_PROJECT_ID: ${{ secrets.CROWDIN_PROJECT_ID }}
|
||||
CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_PERSONAL_TOKEN }}
|
||||
|
|
27
.github/workflows/release.yml
vendored
Normal file
27
.github/workflows/release.yml
vendored
Normal file
|
@ -0,0 +1,27 @@
|
|||
name: Publish Release
|
||||
|
||||
on: workflow_dispatch
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout Repository
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Setup Java
|
||||
run: echo "JAVA_HOME=$JAVA_HOME_17_X64" >> "$GITHUB_ENV"
|
||||
|
||||
- name: Setup Gradle
|
||||
uses: gradle/actions/setup-gradle@v4
|
||||
with:
|
||||
cache-disabled: true
|
||||
|
||||
- name: Validate Gradle Wrapper Integrity
|
||||
uses: gradle/wrapper-validation-action@v2
|
||||
|
||||
- name: Build & Publish
|
||||
env:
|
||||
MODRINTH_TOKEN: ${{ secrets.MODRINTH_TOKEN }}
|
||||
CURSEFORGE_TOKEN: ${{ secrets.CURSEFORGE_TOKEN }}
|
||||
run: ./gradlew build publish publishMods
|
468
build.gradle
468
build.gradle
|
@ -1,21 +1,21 @@
|
|||
import dev.ithundxr.silk.ChangelogText
|
||||
|
||||
plugins {
|
||||
id 'idea'
|
||||
id 'eclipse'
|
||||
id 'maven-publish'
|
||||
|
||||
id 'net.minecraftforge.gradle' version "${forgegradle_version}"
|
||||
id 'org.spongepowered.mixin' version "${mixingradle_version}"
|
||||
id 'org.parchmentmc.librarian.forgegradle' version "${librarian_version}"
|
||||
|
||||
id 'com.matthewprenger.cursegradle' version "${cursegradle_version}"
|
||||
id "idea"
|
||||
id "eclipse"
|
||||
id "maven-publish"
|
||||
id "net.neoforged.moddev.legacyforge" version "2.0.74"
|
||||
id "me.modmuss50.mod-publish-plugin" version "0.8.3"
|
||||
id "dev.ithundxr.silk" version "0.11.15"
|
||||
id "net.kyori.blossom" version "2.1.0" // https://github.com/KyoriPowered/blossom
|
||||
id "org.jetbrains.gradle.plugin.idea-ext" version "1.1.8" // https://github.com/JetBrains/gradle-idea-ext-plugin
|
||||
}
|
||||
|
||||
apply from: './gradle/java.gradle'
|
||||
|
||||
jarJar.enable()
|
||||
|
||||
boolean dev = System.getenv('RELEASE') == null || System.getenv('RELEASE').equals('false')
|
||||
ext.buildNumber = System.getenv('BUILD_NUMBER')
|
||||
String gitHash = "\"${calculateGitHash() + (hasUnstaged() ? "-modified" : "")}\""
|
||||
|
||||
base {
|
||||
archivesName = "create-${artifact_minecraft_version}"
|
||||
|
@ -46,13 +46,6 @@ mixin {
|
|||
|
||||
println "Java: ${System.getProperty 'java.version'}, JVM: ${System.getProperty 'java.vm.version'} (${System.getProperty 'java.vendor'}), Arch: ${System.getProperty 'os.arch'}"
|
||||
|
||||
mixin {
|
||||
add sourceSets.main, 'create.refmap.json'
|
||||
|
||||
debug.verbose = true
|
||||
debug.export = true
|
||||
}
|
||||
|
||||
idea {
|
||||
module {
|
||||
downloadJavadoc = true
|
||||
|
@ -60,152 +53,103 @@ idea {
|
|||
}
|
||||
}
|
||||
|
||||
minecraft {
|
||||
legacyForge {
|
||||
version = "$minecraft_version-$forge_version"
|
||||
|
||||
if (Boolean.parseBoolean(use_parchment)) {
|
||||
mappings channel: 'parchment', version: "${parchment_version}-${minecraft_version}"
|
||||
} else {
|
||||
mappings channel: 'official', version: "${minecraft_version}"
|
||||
}
|
||||
|
||||
// This property allows configuring Gradle's ProcessResources task(s) to run on IDE output locations before launching the game.
|
||||
copyIdeResources = true
|
||||
// TODO - Try turning this on later
|
||||
validateAccessTransformers = false
|
||||
|
||||
if (file('src/main/resources/META-INF/accesstransformer.cfg').exists()) {
|
||||
accessTransformer = file('src/main/resources/META-INF/accesstransformer.cfg')
|
||||
accessTransformers.from "src/main/resources/META-INF/accesstransformer.cfg"
|
||||
}
|
||||
|
||||
parchment {
|
||||
minecraftVersion = minecraft_version
|
||||
mappingsVersion = parchment_version
|
||||
}
|
||||
|
||||
runs {
|
||||
// applies to all the run configs below
|
||||
configureEach {
|
||||
if (inMultiModWorkspace)
|
||||
ideaModule "createmod.Create.main"
|
||||
else
|
||||
ideaModule "Create.main"
|
||||
|
||||
property 'forge.logging.markers', ''
|
||||
property 'forge.logging.console.level', 'info'
|
||||
jvmArgs '-XX:+IgnoreUnrecognizedVMOptions', '-XX:+AllowEnhancedClassRedefinition'
|
||||
systemProperty 'forge.logging.markers', ''
|
||||
systemProperty 'forge.logging.console.level', 'info'
|
||||
jvmArguments = ["-XX:+IgnoreUnrecognizedVMOptions", "-XX:+AllowEnhancedClassRedefinition"]
|
||||
//jvmArgs("-XX:-OmitStackTraceInFastThrow") // uncomment when you get exceptions with null messages etc
|
||||
//jvmArgs '-XX:+UnlockCommercialFeatures' // uncomment for profiling
|
||||
|
||||
property 'mixin.debug.export', 'true'
|
||||
property 'mixin.env.remapRefMap', 'true'
|
||||
property 'mixin.env.refMapRemappingFile', "${projectDir}/build/createSrgToMcp/output.srg"
|
||||
systemProperty 'mixin.debug.export', 'true'
|
||||
systemProperty 'mixin.debug.verbose', 'true'
|
||||
systemProperty 'mixin.env.remapRefMap', 'true'
|
||||
systemProperty 'mixin.env.refMapRemappingFile', "${projectDir}/build/createSrgToMcp/output.srg"
|
||||
|
||||
arg '-mixin.config=create.mixins.json'
|
||||
arg '-mixin.config=catnip.mixins.json'
|
||||
programArgument '-mixin.config=create.mixins.json'
|
||||
programArgument '-mixin.config=catnip.mixins.json'
|
||||
|
||||
mods {
|
||||
create {
|
||||
source sourceSets.main
|
||||
}
|
||||
|
||||
if (catnipInWorkspace) {
|
||||
catnip {
|
||||
source project(":catnip:Common").sourceSets.main
|
||||
source project(":catnip:Forge").sourceSets.main
|
||||
sourceSet project(":catnip:Common").sourceSets.main
|
||||
sourceSet project(":catnip:Forge").sourceSets.main
|
||||
}
|
||||
}
|
||||
|
||||
if (ponderInWorkspace) {
|
||||
ponder {
|
||||
source project(":ponder:Common").sourceSets.main
|
||||
source project(":ponder:Forge").sourceSets.main
|
||||
sourceSet project(":ponder:Common").sourceSets.main
|
||||
sourceSet project(":ponder:Forge").sourceSets.main
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
client {
|
||||
workingDirectory project.file('run')
|
||||
client()
|
||||
|
||||
gameDirectory = project.file('run')
|
||||
}
|
||||
|
||||
server {
|
||||
workingDirectory project.file('run/server')
|
||||
server()
|
||||
|
||||
gameDirectory = project.file('run/server')
|
||||
}
|
||||
|
||||
data {
|
||||
workingDirectory project.file('run')
|
||||
property 'forge.logging.markers', 'REGISTRIES,REGISTRYDUMP'
|
||||
property 'forge.logging.console.level', 'debug'
|
||||
args '--mod', 'create', '--all', '--output', file('src/generated/resources/'), '--existing', file('src/main/resources')
|
||||
data()
|
||||
|
||||
gameDirectory = project.file('run')
|
||||
systemProperty 'forge.logging.markers', 'REGISTRIES,REGISTRYDUMP'
|
||||
systemProperty 'forge.logging.console.level', 'debug'
|
||||
programArguments = ["--mod", mod_id, "--all", "--output", file("src/generated/resources/").getAbsolutePath(), "--existing", file("src/main/resources").getAbsolutePath()]
|
||||
}
|
||||
|
||||
gameTestServer {
|
||||
workingDirectory project.file('run/gametest')
|
||||
type = "gameTestServer"
|
||||
|
||||
gameDirectory = project.file('run/gametest')
|
||||
// setForceExit false <- FIXME 1.20
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
repositories {
|
||||
maven {
|
||||
// location of the maven for Registrate and Flywheel
|
||||
name = 'tterrag maven'
|
||||
url = 'https://maven.tterrag.com'
|
||||
}
|
||||
maven {
|
||||
// location of the maven that hosts JEI files since January 2023
|
||||
// location of the maven for Vazkii's mods
|
||||
name = "Jared's maven"
|
||||
url = "https://maven.blamejared.com/"
|
||||
}
|
||||
/*maven {
|
||||
// location of a maven mirror for JEI files, as a fallback
|
||||
name = "ModMaven"
|
||||
url = "https://modmaven.dev"
|
||||
}*/
|
||||
maven {
|
||||
// location of the maven for Dynamic Trees
|
||||
url = 'https://harleyoconnor.com/maven'
|
||||
}
|
||||
maven {
|
||||
// location of the maven for Curios API
|
||||
url = "https://maven.theillusivec4.top/"
|
||||
}
|
||||
maven {
|
||||
// location of maven for CC: Tweaked
|
||||
name = "squiddev"
|
||||
url = "https://squiddev.cc/maven/"
|
||||
}
|
||||
maven {
|
||||
name = "ftb"
|
||||
url = "https://maven.saps.dev/releases"
|
||||
}
|
||||
maven {
|
||||
name = "architectury"
|
||||
url = "https://maven.architectury.dev/"
|
||||
}
|
||||
maven {
|
||||
url = "https://jm.gserv.me/repository/maven-public/"
|
||||
maven { url = "https://maven.createmod.net" } // Ponder, Catnip
|
||||
maven { url = "https://maven.tterrag.com" } // Registrate, Flywheel
|
||||
maven { url = "https://maven.blamejared.com" } // JEI, Vazkii's Mods
|
||||
maven { url = "https://harleyoconnor.com/maven" } // Dynamic Trees
|
||||
maven { url = "https://maven.theillusivec4.top/" } // Curios API
|
||||
maven { url = "https://maven.squiddev.cc" } // CC: Tweaked
|
||||
maven { url = "https://www.cursemaven.com" }
|
||||
maven { url = "https://api.modrinth.com/maven" }
|
||||
maven { url = "https://maven.saps.dev/releases" } // FTB Mods
|
||||
maven { url = "https://maven.architectury.dev" } // Arch API
|
||||
maven { url = "https://jm.gserv.me/repository/maven-public" // JourneyMap
|
||||
content {
|
||||
includeGroup "info.journeymap"
|
||||
includeGroup "mysticdrew"
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
maven {
|
||||
url = 'https://www.cursemaven.com'
|
||||
content {
|
||||
includeGroup "curse.maven"
|
||||
}
|
||||
}
|
||||
maven {
|
||||
// Location of the maven for Ponder, Catnip
|
||||
name = 'createmod maven'
|
||||
url 'https://maven.createmod.net'
|
||||
}
|
||||
maven {
|
||||
name = "Modrinth"
|
||||
url = "https://api.modrinth.com/maven"
|
||||
content {
|
||||
includeGroup "maven.modrinth"
|
||||
}
|
||||
}
|
||||
maven { url = "https://raw.githubusercontent.com/Fuzss/modresources/main/maven/" }
|
||||
|
||||
// Mirror of maven.createmod.net
|
||||
if (System.getProperty("os.name").contains("Mac") && System.getenv("USER") == "ithundxr") {
|
||||
maven { url = "https://maven.ithundxr.dev/mirror" }
|
||||
|
@ -214,136 +158,143 @@ repositories {
|
|||
mavenCentral()
|
||||
mavenLocal()
|
||||
flatDir {
|
||||
dirs 'libs'
|
||||
dirs "libs"
|
||||
}
|
||||
}
|
||||
|
||||
sourceSets.main.resources {
|
||||
srcDir 'src/generated/resources'
|
||||
exclude '.cache/'
|
||||
}
|
||||
|
||||
dependencies {
|
||||
minecraft "net.minecraftforge:forge:${minecraft_version}-${forge_version}"
|
||||
|
||||
jarJar("com.tterrag.registrate:Registrate:${registrate_version}") {
|
||||
jarJar.ranged(it, '[MC1.19.3-1.1.10,)')
|
||||
version {
|
||||
strictly "[MC1.20-1.3.3,)"
|
||||
}
|
||||
}
|
||||
jarJar("dev.engine_room.flywheel:flywheel-forge-${flywheel_minecraft_version}:${flywheel_version}") {
|
||||
jarJar.ranged(it, '[1.0,2.0)')
|
||||
version {
|
||||
strictly "[1.0,2.0)"
|
||||
}
|
||||
}
|
||||
|
||||
jarJar("net.createmod.catnip:Catnip-Forge-${minecraft_version}:${catnip_version}") {
|
||||
jarJar.ranged(it, '[0.7.5,)')
|
||||
version {
|
||||
strictly "[0.7.5,)"
|
||||
}
|
||||
}
|
||||
jarJar("net.createmod.ponder:Ponder-Forge-${minecraft_version}:${ponder_version}") {
|
||||
jarJar.ranged(it, '[0.7.5,)')
|
||||
version {
|
||||
strictly "[0.7.5,)"
|
||||
}
|
||||
}
|
||||
|
||||
implementation(jarJar("io.github.llamalad7:mixinextras-forge:${mixin_extras_version}")) {
|
||||
jarJar.ranged(it, "[${mixin_extras_version},)")
|
||||
version {
|
||||
strictly "[${mixin_extras_version},)"
|
||||
}
|
||||
}
|
||||
|
||||
implementation fg.deobf("com.tterrag.registrate:Registrate:${registrate_version}")
|
||||
modImplementation("com.tterrag.registrate:Registrate:${registrate_version}")
|
||||
|
||||
compileOnly fg.deobf("dev.engine_room.flywheel:flywheel-forge-api-${flywheel_minecraft_version}:${flywheel_version}")
|
||||
runtimeOnly fg.deobf("dev.engine_room.flywheel:flywheel-forge-${flywheel_minecraft_version}:${flywheel_version}")
|
||||
modCompileOnly("dev.engine_room.flywheel:flywheel-forge-api-${flywheel_minecraft_version}:${flywheel_version}")
|
||||
modRuntimeOnly("dev.engine_room.flywheel:flywheel-forge-${flywheel_minecraft_version}:${flywheel_version}")
|
||||
|
||||
if (catnipInWorkspace) {
|
||||
implementation project(":catnip:Common")
|
||||
implementation project(":catnip:Forge")
|
||||
} else {
|
||||
implementation fg.deobf("net.createmod.catnip:Catnip-Forge-${minecraft_version}:${catnip_version}")
|
||||
modImplementation("net.createmod.catnip:Catnip-Forge-${minecraft_version}:${catnip_version}")
|
||||
}
|
||||
|
||||
if (ponderInWorkspace) {
|
||||
implementation project(":ponder:Common")
|
||||
implementation project(":ponder:Forge")
|
||||
} else {
|
||||
implementation fg.deobf("net.createmod.ponder:Ponder-Forge-${minecraft_version}:${ponder_version}")
|
||||
modImplementation("net.createmod.ponder:Ponder-Forge-${minecraft_version}:${ponder_version}")
|
||||
}
|
||||
|
||||
compileOnly(annotationProcessor("io.github.llamalad7:mixinextras-common:${mixin_extras_version}"))
|
||||
|
||||
// compileOnly fg.deobf("mezz.jei:jei-${jei_minecraft_version}-common-api:${jei_version}")
|
||||
// compileOnly fg.deobf("mezz.jei:jei-${jei_minecraft_version}-forge-api:${jei_version}")
|
||||
implementation fg.deobf("mezz.jei:jei-${jei_minecraft_version}-forge:${jei_version}")
|
||||
// modCompileOnly("mezz.jei:jei-${jei_minecraft_version}-common-api:${jei_version}")
|
||||
// modCompileOnly("mezz.jei:jei-${jei_minecraft_version}-forge-api:${jei_version}")
|
||||
modImplementation("mezz.jei:jei-${jei_minecraft_version}-forge:${jei_version}")
|
||||
|
||||
compileOnly fg.deobf("top.theillusivec4.curios:curios-forge:${curios_version}+${curios_minecraft_version}:api")
|
||||
runtimeOnly fg.deobf("top.theillusivec4.curios:curios-forge:${curios_version}+${curios_minecraft_version}")
|
||||
modCompileOnly("top.theillusivec4.curios:curios-forge:${curios_version}+${curios_minecraft_version}:api")
|
||||
modRuntimeOnly("top.theillusivec4.curios:curios-forge:${curios_version}+${curios_minecraft_version}")
|
||||
|
||||
if (cc_tweaked_enable.toBoolean()) {
|
||||
compileOnly("cc.tweaked:cc-tweaked-${cc_tweaked_minecraft_version}-core-api:${cc_tweaked_version}")
|
||||
compileOnly fg.deobf("cc.tweaked:cc-tweaked-${cc_tweaked_minecraft_version}-forge-api:${cc_tweaked_version}")
|
||||
runtimeOnly fg.deobf("cc.tweaked:cc-tweaked-${cc_tweaked_minecraft_version}-forge:${cc_tweaked_version}")
|
||||
modCompileOnly("cc.tweaked:cc-tweaked-${cc_tweaked_minecraft_version}-forge-api:${cc_tweaked_version}")
|
||||
modRuntimeOnly("cc.tweaked:cc-tweaked-${cc_tweaked_minecraft_version}-forge:${cc_tweaked_version}")
|
||||
}
|
||||
|
||||
if (dynamic_trees_enable.toBoolean()) {
|
||||
compileOnly fg.deobf("com.ferreusveritas.dynamictrees:DynamicTrees-${dynamic_trees_minecraft_version}:${dynamic_trees_version}")
|
||||
modCompileOnly("com.ferreusveritas.dynamictrees:DynamicTrees-${dynamic_trees_minecraft_version}:${dynamic_trees_version}")
|
||||
}
|
||||
|
||||
// implementation fg.deobf("curse.maven:ic2-classic-242942:5555152")
|
||||
// implementation fg.deobf("curse.maven:druidcraft-340991:3101903")
|
||||
// implementation fg.deobf("com.railwayteam.railways:railways-1.19.2-1.6.4:all") { transitive = false }
|
||||
// modImplementation("curse.maven:ic2-classic-242942:5555152")
|
||||
// modImplementation("curse.maven:druidcraft-340991:3101903")
|
||||
// modImplementation("com.railwayteam.railways:railways-1.19.2-1.6.4:all") { transitive = false }
|
||||
|
||||
implementation fg.deobf("dev.architectury:architectury-forge:9.1.12")
|
||||
implementation fg.deobf("dev.ftb.mods:ftb-chunks-forge:2001.3.1")
|
||||
implementation fg.deobf("dev.ftb.mods:ftb-teams-forge:2001.3.0")
|
||||
implementation fg.deobf("dev.ftb.mods:ftb-library-forge:2001.2.4")
|
||||
modRuntimeOnly("dev.architectury:architectury-forge:9.1.12")
|
||||
modImplementation("dev.ftb.mods:ftb-chunks-forge:2001.3.1")
|
||||
modImplementation("dev.ftb.mods:ftb-teams-forge:2001.3.0")
|
||||
modImplementation("dev.ftb.mods:ftb-library-forge:2001.2.4")
|
||||
|
||||
implementation fg.deobf("curse.maven:journeymap-32274:5457831")
|
||||
// implementation fg.deobf("ignored:journeymap-1.20.1-5.10.1-forge")
|
||||
modImplementation("curse.maven:journeymap-32274:5457831")
|
||||
// modImplementation("ignored:journeymap-1.20.1-5.10.1-forge")
|
||||
|
||||
// runtimeOnly fg.deobf("curse.maven:framedblocks-441647:5399211")
|
||||
// runtimeOnly fg.deobf("curse.maven:galosphere-631098:4574834")
|
||||
// runtimeOnly fg.deobf("curse.maven:elementary-ores-332609:4514276") 1.19.4 only
|
||||
// runtimeOnly fg.deobf("curse.maven:flib-661261:4479544")
|
||||
// runtimeOnly fg.deobf("curse.maven:infernal-expansion-395078:4002091")
|
||||
// runtimeOnly fg.deobf("vazkii.autoreglib:AutoRegLib:1.8.2-58.126")
|
||||
// runtimeOnly fg.deobf("curse.maven:quark-243121:4812006")
|
||||
// runtimeOnly fg.deobf("curse.maven:mantle-74924:5339977")
|
||||
// runtimeOnly fg.deobf("curse.maven:tinkers-construct-74072:5358052")
|
||||
// runtimeOnly fg.deobf("maven.modrinth:rubidium:0.6.2c")
|
||||
// runtimeOnly fg.deobf("maven.modrinth:aether:1.19.2-1.4.2-forge")
|
||||
// runtimeOnly fg.deobf("maven.modrinth:spark:1.10.38-forge")
|
||||
// runtimeOnly fg.deobf("curse.maven:forbidden-arcanus-309858:4852521")
|
||||
// runtimeOnly fg.deobf("curse.maven:valhelsia-core-416935:4181245")
|
||||
// runtimeOnly fg.deobf("curse.maven:modern-ui-352491:5229370")
|
||||
// runtimeOnly fg.deobf("curse.maven:sophisticated-storage-619320:5194750")
|
||||
// runtimeOnly fg.deobf("curse.maven:sophisticated-core-618298:5296313")
|
||||
// runtimeOnly fg.deobf("curse.maven:functional-storage-556861:5499169")
|
||||
// runtimeOnly fg.deobf("curse.maven:titanium-287342:5356458")
|
||||
// runtimeOnly fg.deobf("curse.maven:storage-drawers-223852:3884263")
|
||||
// runtimeOnly fg.deobf("curse.maven:ftb-chunks-forge-314906:5417874")
|
||||
// runtimeOnly fg.deobf("curse.maven:architectury-api-419699:5137942")
|
||||
// runtimeOnly fg.deobf("curse.maven:ftb-library-forge-404465:4661834")
|
||||
// runtimeOnly fg.deobf("curse.maven:ftb-teams-forge-404468:4611938")
|
||||
// runtimeOnly fg.deobf("curse.maven:citadel-331936:4556677")
|
||||
// runtimeOnly fg.deobf("curse.maven:ice-and-fire-dragons-264231:5037952")
|
||||
// runtimeOnly fg.deobf("curse.maven:exnihilosequentia-400012:4993344")
|
||||
// runtimeOnly fg.deobf("curse.maven:upgrade-aquatic-326895:4777515")
|
||||
// runtimeOnly fg.deobf("curse.maven:blueprint-382216:4749000")
|
||||
// runtimeOnly fg.deobf("curse.maven:windsweptmod-636321:4817132")
|
||||
// runtimeOnly fg.deobf("curse.maven:good-ending-690161:4363719")
|
||||
// modRuntimeOnly("curse.maven:framedblocks-441647:5399211")
|
||||
// modRuntimeOnly("curse.maven:galosphere-631098:4574834")
|
||||
// modRuntimeOnly("curse.maven:elementary-ores-332609:4514276") 1.19.4 only
|
||||
// modRuntimeOnly("curse.maven:flib-661261:4479544")
|
||||
// modRuntimeOnly("curse.maven:infernal-expansion-395078:4002091")
|
||||
// modRuntimeOnly("vazkii.autoreglib:AutoRegLib:1.8.2-58.126")
|
||||
// modRuntimeOnly("curse.maven:quark-243121:4812006")
|
||||
// modRuntimeOnly("curse.maven:mantle-74924:5339977")
|
||||
// modRuntimeOnly("curse.maven:tinkers-construct-74072:5358052")
|
||||
// modRuntimeOnly("maven.modrinth:rubidium:0.6.2c")
|
||||
// modRuntimeOnly("maven.modrinth:aether:1.19.2-1.4.2-forge")
|
||||
// modRuntimeOnly("maven.modrinth:spark:1.10.38-forge")
|
||||
// modRuntimeOnly("curse.maven:forbidden-arcanus-309858:4852521")
|
||||
// modRuntimeOnly("curse.maven:valhelsia-core-416935:4181245")
|
||||
// modRuntimeOnly("curse.maven:modern-ui-352491:5229370")
|
||||
// modRuntimeOnly("curse.maven:sophisticated-storage-619320:5194750")
|
||||
// modRuntimeOnly("curse.maven:sophisticated-core-618298:5296313")
|
||||
// modRuntimeOnly("curse.maven:functional-storage-556861:5499169")
|
||||
// modRuntimeOnly("curse.maven:titanium-287342:5356458")
|
||||
// modRuntimeOnly("curse.maven:storage-drawers-223852:3884263")
|
||||
// modRuntimeOnly("curse.maven:ftb-chunks-forge-314906:5417874")
|
||||
// modRuntimeOnly("curse.maven:architectury-api-419699:5137942")
|
||||
// modRuntimeOnly("curse.maven:ftb-library-forge-404465:4661834")
|
||||
// modRuntimeOnly("curse.maven:ftb-teams-forge-404468:4611938")
|
||||
// modRuntimeOnly("curse.maven:citadel-331936:4556677")
|
||||
// modRuntimeOnly("curse.maven:ice-and-fire-dragons-264231:5037952")
|
||||
// modRuntimeOnly("curse.maven:exnihilosequentia-400012:4993344")
|
||||
// modRuntimeOnly("curse.maven:upgrade-aquatic-326895:4777515")
|
||||
// modRuntimeOnly("curse.maven:blueprint-382216:4749000")
|
||||
// modRuntimeOnly("curse.maven:windsweptmod-636321:4817132")
|
||||
// modRuntimeOnly("curse.maven:good-ending-690161:4363719")
|
||||
|
||||
// https://discord.com/channels/313125603924639766/725850371834118214/910619168821354497
|
||||
// Prevent Mixin annotation processor from getting into IntelliJ's annotation processor settings
|
||||
// This allows 'Settings > Build, Execution, and Deployment > Build Tools > Gradle > Build and run using' set to IntelliJ to work correctly
|
||||
if (!Boolean.getBoolean('idea.sync.active')) {
|
||||
annotationProcessor "org.spongepowered:mixin:${mixin_version}:processor"
|
||||
annotationProcessor "org.spongepowered:mixin:0.8.5:processor"
|
||||
}
|
||||
}
|
||||
|
||||
sourceSets.main.java {
|
||||
if (!cc_tweaked_enable.toBoolean()) {
|
||||
exclude 'com/simibubi/create/compat/computercraft/implementation/**'
|
||||
}
|
||||
}
|
||||
|
||||
// Workaround for SpongePowered/MixinGradle#38
|
||||
afterEvaluate {
|
||||
tasks.configureReobfTaskForReobfJar.mustRunAfter(tasks.compileJava)
|
||||
tasks.configureReobfTaskForReobfJarJar.mustRunAfter(tasks.compileJava)
|
||||
sourceSets.main {
|
||||
java {
|
||||
if (!cc_tweaked_enable.toBoolean()) {
|
||||
exclude 'com/simibubi/create/compat/computercraft/implementation/**'
|
||||
}
|
||||
}
|
||||
resources {
|
||||
srcDir 'src/generated/resources'
|
||||
exclude '.cache/'
|
||||
}
|
||||
blossom.javaSources {
|
||||
property("version", build_info_mod_version)
|
||||
property("gitCommit", gitHash.toString())
|
||||
}
|
||||
}
|
||||
|
||||
processResources {
|
||||
|
@ -361,31 +312,21 @@ compileJava {
|
|||
options.compilerArgs = ['-Xdiags:verbose']
|
||||
}
|
||||
|
||||
void addLicense(jarTask) {
|
||||
jarTask.from('LICENSE') {
|
||||
rename { "${it}_${project.archivesBaseName}" }
|
||||
jar {
|
||||
from('LICENSE') {
|
||||
rename { "${it}_${archivesBaseName}" }
|
||||
}
|
||||
|
||||
manifest.attributes([
|
||||
"MixinConfigs": "create.mixins.json",
|
||||
"Git-Hash": gitHash
|
||||
])
|
||||
}
|
||||
|
||||
tasks.jar {
|
||||
archiveClassifier = 'slim'
|
||||
finalizedBy('reobfJar')
|
||||
addLicense it
|
||||
}
|
||||
|
||||
tasks.jarJar {
|
||||
finalizedBy('reobfJarJar')
|
||||
addLicense it
|
||||
}
|
||||
|
||||
task jarJarRelease {
|
||||
group = 'jarjar'
|
||||
doLast {
|
||||
tasks.jarJar {
|
||||
archiveClassifier = ''
|
||||
}
|
||||
}
|
||||
finalizedBy tasks.jarJar
|
||||
tasks.named("sourcesJar") {
|
||||
manifest.attributes([
|
||||
"Git-Hash": gitHash
|
||||
])
|
||||
}
|
||||
|
||||
project.publishing {
|
||||
|
@ -393,8 +334,6 @@ project.publishing {
|
|||
mavenJava(MavenPublication) {
|
||||
artifactId base.archivesName.get()
|
||||
from components.java
|
||||
fg.component(it)
|
||||
jarJar.component(it)
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -405,55 +344,52 @@ project.publishing {
|
|||
}
|
||||
}
|
||||
|
||||
String getChangelogText() {
|
||||
def changelogFile = file('changelog.txt')
|
||||
String str = ''
|
||||
int lineCount = 0
|
||||
boolean done = false
|
||||
changelogFile.eachLine {
|
||||
if (done || it == null) {
|
||||
return
|
||||
}
|
||||
if (it.size() > 1) {
|
||||
def temp = it
|
||||
if (lineCount == 0) {
|
||||
temp = "Create ${version}"
|
||||
temp = "<span style=\"font-size: 18px; color: #333399;\">Create v${mod_version}</span> <em>for Minecraft ${minecraft_version}</em><br/>"
|
||||
} else if (it.startsWith('-')) {
|
||||
temp = " $temp<br/>"
|
||||
temp = temp.replaceAll("(\\S+\\/\\S+)#([0-9]+)\\b", "<a href=\"https://github.com/\$1/issues/\$2\">\$0</a>");
|
||||
temp = temp.replaceAll("#([0-9]+)\\b(?!<\\/a>)", "<a href=\"https://github.com/$github_project/issues/\$1\">\$0</a>");
|
||||
} else {
|
||||
temp = "<h4>$temp</h4>"
|
||||
}
|
||||
str += temp
|
||||
lineCount++
|
||||
} else {
|
||||
str += "<p>Please submit any Issues you come across on the <a href=\"https://github.com/${github_project}/issues\" rel=\"nofollow\">Issue Tracker</a>.</p>"
|
||||
done = true
|
||||
}
|
||||
publishMods {
|
||||
file = jar.archiveFile
|
||||
changelog = ChangelogText.getChangelogText(project).toString()
|
||||
type = STABLE
|
||||
displayName = "$mod_name $minecraft_version $mod_version"
|
||||
modLoaders.add("forge")
|
||||
modLoaders.add("neoforge")
|
||||
|
||||
curseforge {
|
||||
accessToken = providers.environmentVariable("CURSEFORGE_TOKEN")
|
||||
projectId = "328085"
|
||||
minecraftVersions.add(minecraft_version)
|
||||
}
|
||||
|
||||
modrinth {
|
||||
accessToken = providers.environmentVariable("MODRINTH_TOKEN")
|
||||
projectId = "LNytGWDc"
|
||||
minecraftVersions.add(minecraft_version)
|
||||
}
|
||||
return str
|
||||
}
|
||||
|
||||
// changelog debugging
|
||||
// new File("changelog.html").write getChangelogText()
|
||||
// tasks.curseforge.enabled = !dev && project.hasProperty('simi_curseforge_key')
|
||||
// curseforge {
|
||||
// if (project.hasProperty('simi_curseforge_key')) {
|
||||
// apiKey = project.simi_curseforge_key
|
||||
// }
|
||||
//
|
||||
// project {
|
||||
// id = project.projectId
|
||||
// changelog = System.getenv('CHANGELOG') == null || System.getenv('CHANGELOG').equals('none') ? getChangelogText() : System.getenv('CHANGELOG')
|
||||
// changelogType = 'html'
|
||||
// releaseType = project.curse_type
|
||||
// mainArtifact(shadowJar) {
|
||||
// displayName = "Create - ${version}"
|
||||
// }
|
||||
// relations {
|
||||
// optionalDependency 'jei'
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
String calculateGitHash() {
|
||||
try {
|
||||
ByteArrayOutputStream stdout = new ByteArrayOutputStream()
|
||||
exec {
|
||||
commandLine("git", "rev-parse", "HEAD")
|
||||
standardOutput = stdout
|
||||
}
|
||||
return stdout.toString().trim()
|
||||
} catch(Throwable ignored) {
|
||||
return "unknown"
|
||||
}
|
||||
}
|
||||
|
||||
boolean hasUnstaged() {
|
||||
try {
|
||||
ByteArrayOutputStream stdout = new ByteArrayOutputStream()
|
||||
exec {
|
||||
commandLine("git", "status", "--porcelain")
|
||||
standardOutput = stdout
|
||||
}
|
||||
String result = stdout.toString().replace("/M gradlew(\\.bat)?/", "").trim()
|
||||
if (!result.isEmpty())
|
||||
println("Found stageable results:\n${result}\n")
|
||||
return !result.isEmpty()
|
||||
} catch(Throwable ignored) {
|
||||
return false
|
||||
}
|
||||
}
|
||||
|
|
34
changelog.md
Normal file
34
changelog.md
Normal file
|
@ -0,0 +1,34 @@
|
|||
------------------------------------------------------
|
||||
Create 0.5.2
|
||||
------------------------------------------------------
|
||||
Additions
|
||||
- Example
|
||||
|
||||
Changes
|
||||
- Bumped the defalt max rope length to 384
|
||||
- Set vault capacity limit to 2048 slots to prevent people from OOM-ing themselves if they set the capacity too high
|
||||
|
||||
Bug Fixes
|
||||
- Fix certain blocks messing up the order scheduled ticks (#7141)
|
||||
- Fix unbreakable superglue not being usable (#6253)
|
||||
- Fix update suppression (#7176)
|
||||
- Fix comparator output of depots ignoring the items max stack size (#7179)
|
||||
- Fix deployers retaining the damage attribute of their last held weapon (#4870)
|
||||
- Fix an exploit allowing people to create clipboards that execute commands (#7218)
|
||||
- Fix redstone links not updating their redstone output when they've been taken out of receiver mode (#7226)
|
||||
- Fix rare crash related to sliding doors (#6184)
|
||||
- Verify that schematics are gzip-encoded before trying to read from them (#6087)
|
||||
- Added workaround for create_tracks.dat getting corrupted during crashes, the mod will try to restore the old track data stored in the create_tracks.dat_old file if the current one is corrupted
|
||||
- Fix contraptions triggering pressure plates and tripwires (#7255)
|
||||
- Fix ConditionContext nbt in trains containing a large number of empty tags
|
||||
- Fix deployers not placing fish from fish buckets (#3705)
|
||||
- Fix gasses not being visible in basins and item drains (#7236)
|
||||
|
||||
Art Changes
|
||||
- Example
|
||||
|
||||
API Changes
|
||||
- Removed LangMerger and related classes
|
||||
- Implemented an api to allow mods to register schematic requirements, partial safe nbt and contraption transforms without implementing interfaces (#4702)
|
||||
- Add a method that developers can override to change the icon in goggle tooltips
|
||||
- Refactored Item Attributes types, Fan processing types and Arm interaction points, all 3 now use proper registries
|
|
@ -4,18 +4,15 @@ org.gradle.jvmargs = -Xmx3G
|
|||
org.gradle.daemon = false
|
||||
|
||||
# mod version info
|
||||
# build_info_mod_version is the version that gets filled into CreateBuildInfo.java
|
||||
mod_version = 0.5.2
|
||||
build_info_mod_version = 0.5.2-experimental
|
||||
artifact_minecraft_version = 1.20.1
|
||||
|
||||
minecraft_version = 1.20.1
|
||||
forge_version = 47.2.6
|
||||
|
||||
# build dependency versions
|
||||
forgegradle_version = [6.0.16,6.2)
|
||||
mixingradle_version = 0.7.+
|
||||
mixin_version = 0.8.5
|
||||
librarian_version = 1.+
|
||||
cursegradle_version = 1.4.0
|
||||
parchment_version = 2023.09.03
|
||||
|
||||
use_parchment = true
|
||||
|
|
|
@ -16,13 +16,12 @@ jar {
|
|||
'Implementation-Timestamp': new Date().format("yyyy-MM-dd'T'HH:mm:ssZ"),
|
||||
'Timestampe' : System.currentTimeMillis(),
|
||||
'Built-On-Java' : "${System.getProperty('java.vm.version')} (${System.getProperty('java.vm.vendor')})",
|
||||
'Build-On-Minecraft' : minecraft_version
|
||||
'Built-On-Minecraft' : minecraft_version
|
||||
])
|
||||
}
|
||||
}
|
||||
|
||||
tasks.withType(JavaCompile).configureEach {
|
||||
|
||||
it.options.encoding = 'UTF-8'
|
||||
it.options.release = 17
|
||||
}
|
||||
|
@ -31,12 +30,10 @@ tasks.withType(JavaCompile).configureEach {
|
|||
// metadata includes mapped dependencies which are not reasonably consumable by
|
||||
// other mod developers.
|
||||
tasks.withType(GenerateModuleMetadata) {
|
||||
|
||||
enabled = false
|
||||
}
|
||||
|
||||
javadoc {
|
||||
|
||||
// Suppress annoying warnings when generating JavaDoc files.
|
||||
options.addStringOption('Xdoclint:none', '-quiet')
|
||||
}
|
||||
|
|
BIN
gradle/wrapper/gradle-wrapper.jar
vendored
BIN
gradle/wrapper/gradle-wrapper.jar
vendored
Binary file not shown.
3
gradle/wrapper/gradle-wrapper.properties
vendored
3
gradle/wrapper/gradle-wrapper.properties
vendored
|
@ -1,6 +1,7 @@
|
|||
distributionBase=GRADLE_USER_HOME
|
||||
distributionPath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-all.zip
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.11.1-bin.zip
|
||||
networkTimeout=10000
|
||||
validateDistributionUrl=true
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
zipStorePath=wrapper/dists
|
||||
|
|
27
gradlew
vendored
27
gradlew
vendored
|
@ -15,6 +15,8 @@
|
|||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
#
|
||||
|
||||
##############################################################################
|
||||
#
|
||||
|
@ -55,7 +57,7 @@
|
|||
# Darwin, MinGW, and NonStop.
|
||||
#
|
||||
# (3) This script is generated from the Groovy template
|
||||
# https://github.com/gradle/gradle/blob/HEAD/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
|
||||
# https://github.com/gradle/gradle/blob/HEAD/platforms/jvm/plugins-application/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
|
||||
# within the Gradle project.
|
||||
#
|
||||
# You can find Gradle at https://github.com/gradle/gradle/.
|
||||
|
@ -83,7 +85,9 @@ done
|
|||
# This is normally unused
|
||||
# shellcheck disable=SC2034
|
||||
APP_BASE_NAME=${0##*/}
|
||||
APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit
|
||||
# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036)
|
||||
APP_HOME=$( cd -P "${APP_HOME:-./}" > /dev/null && printf '%s
|
||||
' "$PWD" ) || exit
|
||||
|
||||
# Use the maximum available, or set MAX_FD != -1 to use that value.
|
||||
MAX_FD=maximum
|
||||
|
@ -130,10 +134,13 @@ location of your Java installation."
|
|||
fi
|
||||
else
|
||||
JAVACMD=java
|
||||
which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
|
||||
if ! command -v java >/dev/null 2>&1
|
||||
then
|
||||
die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
|
||||
|
||||
Please set the JAVA_HOME variable in your environment to match the
|
||||
location of your Java installation."
|
||||
fi
|
||||
fi
|
||||
|
||||
# Increase the maximum file descriptors if we can.
|
||||
|
@ -141,7 +148,7 @@ if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then
|
|||
case $MAX_FD in #(
|
||||
max*)
|
||||
# In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked.
|
||||
# shellcheck disable=SC3045
|
||||
# shellcheck disable=SC2039,SC3045
|
||||
MAX_FD=$( ulimit -H -n ) ||
|
||||
warn "Could not query maximum file descriptor limit"
|
||||
esac
|
||||
|
@ -149,7 +156,7 @@ if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then
|
|||
'' | soft) :;; #(
|
||||
*)
|
||||
# In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked.
|
||||
# shellcheck disable=SC3045
|
||||
# shellcheck disable=SC2039,SC3045
|
||||
ulimit -n "$MAX_FD" ||
|
||||
warn "Could not set maximum file descriptor limit to $MAX_FD"
|
||||
esac
|
||||
|
@ -198,11 +205,11 @@ fi
|
|||
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
|
||||
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
|
||||
|
||||
# Collect all arguments for the java command;
|
||||
# * $DEFAULT_JVM_OPTS, $JAVA_OPTS, and $GRADLE_OPTS can contain fragments of
|
||||
# shell script including quotes and variable substitutions, so put them in
|
||||
# double quotes to make sure that they get re-expanded; and
|
||||
# * put everything else in single quotes, so that it's not re-expanded.
|
||||
# Collect all arguments for the java command:
|
||||
# * DEFAULT_JVM_OPTS, JAVA_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments,
|
||||
# and any embedded shellness will be escaped.
|
||||
# * For example: A user cannot expect ${Hostname} to be expanded, as it is an environment variable and will be
|
||||
# treated as '${Hostname}' itself on the command line.
|
||||
|
||||
set -- \
|
||||
"-Dorg.gradle.appname=$APP_BASE_NAME" \
|
||||
|
|
22
gradlew.bat
vendored
22
gradlew.bat
vendored
|
@ -13,6 +13,8 @@
|
|||
@rem See the License for the specific language governing permissions and
|
||||
@rem limitations under the License.
|
||||
@rem
|
||||
@rem SPDX-License-Identifier: Apache-2.0
|
||||
@rem
|
||||
|
||||
@if "%DEBUG%"=="" @echo off
|
||||
@rem ##########################################################################
|
||||
|
@ -43,11 +45,11 @@ set JAVA_EXE=java.exe
|
|||
%JAVA_EXE% -version >NUL 2>&1
|
||||
if %ERRORLEVEL% equ 0 goto execute
|
||||
|
||||
echo.
|
||||
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
|
||||
echo.
|
||||
echo Please set the JAVA_HOME variable in your environment to match the
|
||||
echo location of your Java installation.
|
||||
echo. 1>&2
|
||||
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 1>&2
|
||||
echo. 1>&2
|
||||
echo Please set the JAVA_HOME variable in your environment to match the 1>&2
|
||||
echo location of your Java installation. 1>&2
|
||||
|
||||
goto fail
|
||||
|
||||
|
@ -57,11 +59,11 @@ set JAVA_EXE=%JAVA_HOME%/bin/java.exe
|
|||
|
||||
if exist "%JAVA_EXE%" goto execute
|
||||
|
||||
echo.
|
||||
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
|
||||
echo.
|
||||
echo Please set the JAVA_HOME variable in your environment to match the
|
||||
echo location of your Java installation.
|
||||
echo. 1>&2
|
||||
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 1>&2
|
||||
echo. 1>&2
|
||||
echo Please set the JAVA_HOME variable in your environment to match the 1>&2
|
||||
echo location of your Java installation. 1>&2
|
||||
|
||||
goto fail
|
||||
|
||||
|
|
|
@ -2,7 +2,6 @@ pluginManagement {
|
|||
repositories {
|
||||
gradlePluginPortal()
|
||||
mavenCentral()
|
||||
jcenter()
|
||||
maven { url = 'https://maven.minecraftforge.net/' }
|
||||
maven { url = 'https://repo.spongepowered.org/repository/maven-public' }
|
||||
maven { url = 'https://maven.parchmentmc.org' }
|
||||
|
@ -10,7 +9,7 @@ pluginManagement {
|
|||
}
|
||||
|
||||
plugins {
|
||||
id 'org.gradle.toolchains.foojay-resolver-convention' version '0.7.0'
|
||||
id 'org.gradle.toolchains.foojay-resolver-convention' version '0.8.0'
|
||||
}
|
||||
|
||||
rootProject.name = 'Create'
|
||||
|
|
|
@ -0,0 +1,6 @@
|
|||
package com.simibubi.create;
|
||||
|
||||
public class CreateBuildInfo {
|
||||
public static String VERSION = "{{ version }}";
|
||||
public static String GIT_COMMIT = {{ gitCommit }};
|
||||
}
|
|
@ -61,10 +61,8 @@ import net.minecraftforge.fml.javafmlmod.FMLJavaModLoadingContext;
|
|||
|
||||
@Mod(Create.ID)
|
||||
public class Create {
|
||||
|
||||
public static final String ID = "create";
|
||||
public static final String NAME = "Create";
|
||||
public static final String VERSION = "0.5.2-experimental";
|
||||
|
||||
public static final Logger LOGGER = LogUtils.getLogger();
|
||||
|
||||
|
@ -102,6 +100,8 @@ public class Create {
|
|||
}
|
||||
|
||||
public static void onCtor() {
|
||||
LOGGER.info("{} {} initializing! Commit hash: {}", NAME, CreateBuildInfo.VERSION, CreateBuildInfo.GIT_COMMIT);
|
||||
|
||||
ModLoadingContext modLoadingContext = ModLoadingContext.get();
|
||||
|
||||
IEventBus modEventBus = FMLJavaModLoadingContext.get()
|
||||
|
@ -187,5 +187,4 @@ public class Create {
|
|||
public static ResourceLocation asResource(String path) {
|
||||
return new ResourceLocation(ID, path);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -11,6 +11,7 @@ import javax.annotation.Nullable;
|
|||
import com.google.common.collect.ImmutableMap;
|
||||
import com.mojang.blaze3d.platform.GlUtil;
|
||||
import com.simibubi.create.Create;
|
||||
import com.simibubi.create.CreateBuildInfo;
|
||||
import com.simibubi.create.foundation.mixin.accessor.SystemReportAccessor;
|
||||
import com.simibubi.create.infrastructure.debugInfo.element.DebugInfoSection;
|
||||
import com.simibubi.create.infrastructure.debugInfo.element.InfoElement;
|
||||
|
@ -68,7 +69,7 @@ public class DebugInformation {
|
|||
|
||||
static {
|
||||
DebugInfoSection.builder(Create.NAME)
|
||||
.put("Mod Version", Create.VERSION)
|
||||
.put("Mod Version", CreateBuildInfo.VERSION)
|
||||
.put("Forge Version", getVersionOfMod("forge"))
|
||||
.put("Minecraft Version", SharedConstants.getCurrentVersion().getName())
|
||||
.buildTo(DebugInformation::registerBothInfo);
|
||||
|
|
|
@ -5,6 +5,7 @@ import com.mojang.blaze3d.systems.RenderSystem;
|
|||
import com.mojang.blaze3d.vertex.PoseStack;
|
||||
import com.simibubi.create.AllBlocks;
|
||||
import com.simibubi.create.Create;
|
||||
import com.simibubi.create.CreateBuildInfo;
|
||||
import com.simibubi.create.foundation.gui.AllGuiTextures;
|
||||
import com.simibubi.create.foundation.utility.CreateLang;
|
||||
|
||||
|
@ -130,7 +131,7 @@ public class CreateMainMenuScreen extends AbstractSimiScreen {
|
|||
ms.translate(0, 0, 200);
|
||||
graphics.drawCenteredString(font, Components.literal(Create.NAME).withStyle(ChatFormatting.BOLD)
|
||||
.append(
|
||||
Components.literal(" v" + Create.VERSION).withStyle(ChatFormatting.BOLD, ChatFormatting.WHITE)),
|
||||
Components.literal(" v" + CreateBuildInfo.VERSION).withStyle(ChatFormatting.BOLD, ChatFormatting.WHITE)),
|
||||
width / 2, 89, 0xFF_E4BB67);
|
||||
ms.popPose();
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue