-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ec107dc
commit 3afd16e
Showing
105 changed files
with
949 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
name: Build Mod | ||
|
||
on: [push, pull_request] | ||
|
||
jobs: | ||
buildJar: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Set up PATH | ||
run: | | ||
echo "${ANDROID_HOME}/build-tools/34.0.0" >> $GITHUB_PATH | ||
- name: Set up JDK 17 | ||
uses: actions/setup-java@v1 | ||
with: | ||
java-version: 17 | ||
- name: Build mod jar | ||
run: | | ||
chmod +x gradlew | ||
./gradlew deploy | ||
- name: Upload built jar file | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: ${{ github.event.repository.name }} | ||
path: build/libs/${{ github.event.repository.name }}.jar |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,156 @@ | ||
logs/ | ||
/core/assets/mindustry-saves/ | ||
/core/assets/mindustry-maps/ | ||
/core/assets/bundles/output/ | ||
/core/assets/.gifimages/ | ||
/deploy/ | ||
/desktop/packr-out/ | ||
/desktop/packr-export/ | ||
/desktop/mindustry-saves/ | ||
/desktop/mindustry-maps/ | ||
/desktop/gifexport/ | ||
/core/lib/ | ||
/ios/assets/ | ||
/core/assets-raw/sprites/generated/ | ||
/core/assets-raw/sprites_out/ | ||
/annotations/build/ | ||
/annotations/out/ | ||
/net/build/ | ||
/tools/build/ | ||
/tests/build/ | ||
/server/build/ | ||
/test_files/ | ||
/annotations/build/ | ||
/desktop-sdl/build/ | ||
desktop-sdl/build/ | ||
/android/assets/mindustry-maps/ | ||
/android/assets/mindustry-saves/ | ||
/core/assets/gifexport/ | ||
/core/assets/version.properties | ||
/core/assets/locales | ||
/ios/src/io/anuke/mindustry/gen/ | ||
/core/src/io/anuke/mindustry/gen/ | ||
ios/robovm.properties | ||
packr-out/ | ||
config/ | ||
*.gif | ||
|
||
version.properties | ||
|
||
.attach_* | ||
## Java | ||
|
||
*.class | ||
*.war | ||
*.ear | ||
hs_err_pid* | ||
crash-report-* | ||
|
||
## Robovm | ||
/ios/robovm-build/ | ||
|
||
## GWT | ||
/html/war/ | ||
/html/gwt-unitCache/ | ||
.apt_generated/ | ||
.gwt/ | ||
gwt-unitCache/ | ||
www-test/ | ||
.gwt-tmp/ | ||
|
||
## Android Studio and Intellij and Android in general | ||
/android/libs/armeabi/ | ||
/android/libs/armeabi-v7a/ | ||
/android/libs/arm64-v8a/ | ||
/android/libs/x86/ | ||
/android/libs/x86_64/ | ||
/android/gen/ | ||
.idea/ | ||
*.ipr | ||
*.iws | ||
*.iml | ||
/android/out/ | ||
com_crashlytics_export_strings.xml | ||
|
||
## Eclipse | ||
|
||
.classpath | ||
.project | ||
.metadata/ | ||
/android/bin/ | ||
/core/bin/ | ||
/desktop/bin/ | ||
/html/bin/ | ||
/ios/bin/ | ||
/ios-moe/bin/ | ||
*.tmp | ||
*.bak | ||
*.swp | ||
*~.nib | ||
.settings/ | ||
.loadpath | ||
.externalToolBuilders/ | ||
*.launch | ||
|
||
## NetBeans | ||
|
||
/nbproject/private/ | ||
/android/nbproject/private/ | ||
/core/nbproject/private/ | ||
/desktop/nbproject/private/ | ||
/html/nbproject/private/ | ||
/ios/nbproject/private/ | ||
/ios-moe/nbproject/private/ | ||
|
||
/build/ | ||
/android/build/ | ||
/core/build/ | ||
/desktop/build/ | ||
/html/build/ | ||
/ios/build/ | ||
/ios-moe/build/ | ||
|
||
/nbbuild/ | ||
/android/nbbuild/ | ||
/core/nbbuild/ | ||
/desktop/nbbuild/ | ||
/html/nbbuild/ | ||
/ios/nbbuild/ | ||
/ios-moe/nbbuild/ | ||
|
||
/dist/ | ||
/android/dist/ | ||
/core/dist/ | ||
/desktop/dist/ | ||
/html/dist/ | ||
/ios/dist/ | ||
/ios-moe/dist/ | ||
|
||
/nbdist/ | ||
/android/nbdist/ | ||
/core/nbdist/ | ||
/desktop/nbdist/ | ||
/html/nbdist/ | ||
/ios/nbdist/ | ||
/ios-moe/nbdist/ | ||
|
||
nbactions.xml | ||
nb-configuration.xml | ||
|
||
## Gradle | ||
|
||
/local.properties | ||
.gradle/ | ||
gradle-app.setting | ||
/build/ | ||
/android/build/ | ||
/core/build/ | ||
/desktop/build/ | ||
/html/build/ | ||
/ios/build/ | ||
/ios-moe/build/ | ||
|
||
## OS Specific | ||
.DS_Store | ||
Thumbs.db | ||
android/libs/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# A Java Mindustry mod. | ||
Enless's, and music by Saigo. | ||
Still in development. |
Empty file.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,100 @@ | ||
apply plugin: "java" | ||
|
||
version '1.0' | ||
|
||
sourceSets.main.java.srcDirs = ["src"] | ||
|
||
repositories{ | ||
mavenCentral() | ||
maven{ url "https://raw.githubusercontent.com/Zelaux/MindustryRepo/master/repository" } | ||
maven{ url 'https://www.jitpack.io' } | ||
} | ||
|
||
java{ | ||
targetCompatibility = 8 | ||
sourceCompatibility = JavaVersion.VERSION_17 | ||
} | ||
|
||
ext{ | ||
//the build number that this mod is made for | ||
mindustryVersion = 'v145' | ||
jabelVersion = "93fde537c7" | ||
//windows sucks | ||
isWindows = System.getProperty("os.name").toLowerCase().contains("windows") | ||
sdkRoot = System.getenv("ANDROID_HOME") ?: System.getenv("ANDROID_SDK_ROOT") | ||
} | ||
|
||
//java 8 backwards compatibility flag | ||
allprojects{ | ||
tasks.withType(JavaCompile){ | ||
options.compilerArgs.addAll(['--release', '8']) | ||
} | ||
} | ||
|
||
dependencies{ | ||
compileOnly "com.github.Anuken.Arc:arc-core:$mindustryVersion" | ||
compileOnly "com.github.Anuken.Mindustry:core:$mindustryVersion" | ||
|
||
annotationProcessor "com.github.Anuken:jabel:$jabelVersion" | ||
} | ||
|
||
//force arc version | ||
configurations.all{ | ||
resolutionStrategy.eachDependency { details -> | ||
if(details.requested.group == 'com.github.Anuken.Arc'){ | ||
details.useVersion "$mindustryVersion" | ||
} | ||
} | ||
} | ||
|
||
task jarAndroid{ | ||
dependsOn "jar" | ||
|
||
doLast{ | ||
if(!sdkRoot || !new File(sdkRoot).exists()) throw new GradleException("No valid Android SDK found. Ensure that ANDROID_HOME is set to your Android SDK directory."); | ||
|
||
def platformRoot = new File("$sdkRoot/platforms/").listFiles().sort().reverse().find{ f -> new File(f, "android.jar").exists()} | ||
|
||
if(!platformRoot) throw new GradleException("No android.jar found. Ensure that you have an Android platform installed.") | ||
|
||
//collect dependencies needed for desugaring | ||
def dependencies = (configurations.compileClasspath.asList() + configurations.runtimeClasspath.asList() + [new File(platformRoot, "android.jar")]).collect{ "--classpath $it.path" }.join(" ") | ||
|
||
def d8 = isWindows ? "d8.bat" : "d8" | ||
|
||
//dex and desugar files - this requires d8 in your PATH | ||
"$d8 $dependencies --min-api 14 --output ${project.archivesBaseName}Android.jar ${project.archivesBaseName}Desktop.jar" | ||
.execute(null, new File("$buildDir/libs")).waitForProcessOutput(System.out, System.err) | ||
} | ||
} | ||
|
||
jar{ | ||
archiveFileName = "${base.archivesBaseName}Desktop.jar" | ||
|
||
from{ | ||
configurations.runtimeClasspath.collect{ it.isDirectory() ? it : zipTree(it) } | ||
} | ||
|
||
from(rootDir){ | ||
include "mod.hjson" | ||
} | ||
|
||
from("assets/"){ | ||
include "**" | ||
} | ||
} | ||
|
||
task deploy(type: Jar){ | ||
dependsOn jarAndroid | ||
dependsOn jar | ||
archiveFileName = "${base.archivesBaseName}.jar" | ||
|
||
from{ [zipTree("$buildDir/libs/${project.archivesBaseName}Desktop.jar"), zipTree("$buildDir/libs/${project.archivesBaseName}Android.jar")] } | ||
|
||
doLast{ | ||
delete{ | ||
delete "$buildDir/libs/${project.archivesBaseName}Desktop.jar" | ||
delete "$buildDir/libs/${project.archivesBaseName}Android.jar" | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
org.gradle.jvmargs=--illegal-access=permit \ | ||
--add-exports=jdk.compiler/com.sun.tools.javac.api=ALL-UNNAMED \ | ||
--add-exports=jdk.compiler/com.sun.tools.javac.code=ALL-UNNAMED \ | ||
--add-exports=jdk.compiler/com.sun.tools.javac.model=ALL-UNNAMED \ | ||
--add-exports=jdk.compiler/com.sun.tools.javac.processing=ALL-UNNAMED \ | ||
--add-exports=jdk.compiler/com.sun.tools.javac.parser=ALL-UNNAMED \ | ||
--add-exports=jdk.compiler/com.sun.tools.javac.util=ALL-UNNAMED \ | ||
--add-exports=jdk.compiler/com.sun.tools.javac.tree=ALL-UNNAMED \ | ||
--add-exports=jdk.compiler/com.sun.tools.javac.file=ALL-UNNAMED \ | ||
--add-exports=jdk.compiler/com.sun.tools.javac.main=ALL-UNNAMED \ | ||
--add-exports=jdk.compiler/com.sun.tools.javac.jvm=ALL-UNNAMED \ | ||
--add-exports=jdk.compiler/com.sun.tools.javac.comp=ALL-UNNAMED \ | ||
--add-exports=java.base/sun.reflect.annotation=ALL-UNNAMED |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
distributionBase=GRADLE_USER_HOME | ||
distributionPath=wrapper/dists | ||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.2.1-bin.zip | ||
zipStoreBase=GRADLE_USER_HOME | ||
zipStorePath=wrapper/dists |
Oops, something went wrong.