Skip to content

Commit

Permalink
JEI Integration
Browse files Browse the repository at this point in the history
JEI Compatibility and integration for Electrodynamics mod
  • Loading branch information
skiprocks999 committed Apr 16, 2021
1 parent 5095d03 commit 349a2b0
Show file tree
Hide file tree
Showing 34 changed files with 2,643 additions and 52 deletions.
92 changes: 46 additions & 46 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,36 +1,36 @@
/bin
/out
/run
/classes
*.classpath
*.project
.settings/
build/
config/
mods/
logs/
resourcepacks/
saves/
crash-reports/
eclipse/
.gradle/
output/
.cache
*.iml
*.ipr
*.iws
*.idea/
logs/
html/downloads/
downloads/
banned-ips.json
banned-players.json
ops.json
whitelist.json
Colored-Pots.txt
libs.ink
options.txt
usernamecache.json
/bin
/out
/run
/classes
*.classpath
*.project
.settings/
build/
config/
mods/
logs/
resourcepacks/
saves/
crash-reports/
eclipse/
.gradle/
output/
.cache
*.iml
*.ipr
*.iws
*.idea/
logs/
html/downloads/
downloads/
banned-ips.json
banned-players.json
ops.json
whitelist.json
Colored-Pots.txt
libs.ink
options.txt
usernamecache.json
screenshots/
*.log
asm/
Expand All @@ -42,17 +42,17 @@ libs/
outputSplitOnly/

releaseJarsOnly/

Physica_Client.launch

Physica_Server.launch

.DS_Store

runClient.launch

runData.launch

runServer.launch
*.launch

Physica_Client.launch

Physica_Server.launch

.DS_Store

runClient.launch

runData.launch

runServer.launch
*.launch
Icon
2 changes: 2 additions & 0 deletions build.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
gradlew build
pause
28 changes: 25 additions & 3 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,12 @@ minecraft {

dependencies {
minecraft 'net.minecraftforge:forge:1.16.5-36.0.1'
compile fileTree("libs")
/*
Compiles against source code as well as JAR at runtime. Recommend to keep it
*/
compileOnly fg.deobf("mezz.jei:jei-1.16.5:7.6.3.81:api")
runtimeOnly fg.deobf("mezz.jei:jei-1.16.5:7.6.3.81")

}

// Example for how to get properties into the manifest for reading by the runtime..
Expand All @@ -111,7 +116,7 @@ jar {
}

jar.finalizedBy('reobfJar')


task sourcesJar(type: Jar, dependsOn: classes) {
from sourceSets.main.allSource
classifier = 'sources'
Expand All @@ -138,6 +143,21 @@ publishing {
}
}

/*
This needs to stay. It's the Maven repository for JEI along with a fallback!
*/
repositories{
mavenCentral()
maven {
name = "Progwml6 maven"
url = "https://dvs1.progwml6.com/files/maven/"
}
maven {
name = "ModMaven"
url = "https://modmaven.k-4u.nl"
}
}

ext.gittagnew = 'v'+project.version

task createTag(type: GitTag) {
Expand All @@ -152,6 +172,7 @@ task pushTag(type: GitPush, dependsOn: createTag) {
tasks.curseforge.dependsOn jar
tasks.curseforge.dependsOn pushTag

/* I had to comment this out to get things set up. Feel free to uncomment it!
curseforge {
apiKey = System.getenv("CURSEFORGE_KEY")
project {
Expand All @@ -164,4 +185,5 @@ curseforge {
displayName=project.name+' ' + project.version
}
}
}
}
*/
1 change: 1 addition & 0 deletions refresh dependencies.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
gradlew --refresh-dependencies&&gradlew eclipse --info --stacktrace
2 changes: 2 additions & 0 deletions src/main/java/electrodynamics/common/fluid/FluidMineral.java
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,8 @@ public int getLevel(FluidState state) {
return 0;
}

//TODO: Consider naming each variant of mineral fluid for the ore e.g. "Copper Mineral Fluid".
//Just a thought tho
@Override
protected FluidAttributes createAttributes() {
return FluidAttributes.builder(new ResourceLocation(References.ID + ":fluid/mineral"), new ResourceLocation(References.ID + ":fluid/mineral"))
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
/*
* This is mainly here for when we eventually switch to JSONs. I mainly included it so I can
* build the ability to switch over into the plugin already. For now just kinda ignore it I
* guess
*/
package electrodynamics.common.recipe;

import net.minecraft.item.crafting.IRecipe;
import net.minecraftforge.items.wrapper.RecipeWrapper;

public abstract class ElectrodynamicsRecipe implements IRecipe<RecipeWrapper>{

}
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
import net.minecraft.tileentity.TileEntityType;

public class MachineRecipes {
private static final HashMap<TileEntityType<?>, HashSet<O2OProcessingRecipe>> o2orecipemap = new HashMap<>();
private static final HashMap<TileEntityType<?>, HashSet<DO2OProcessingRecipe>> do2orecipemap = new HashMap<>();
public static final HashMap<TileEntityType<?>, HashSet<O2OProcessingRecipe>> o2orecipemap = new HashMap<>();
public static final HashMap<TileEntityType<?>, HashSet<DO2OProcessingRecipe>> do2orecipemap = new HashMap<>();

public static void registerRecipe(TileEntityType<?> type, O2OProcessingRecipe recipe) {
HashSet<O2OProcessingRecipe> list = new HashSet<>();
Expand Down
Loading

0 comments on commit 349a2b0

Please sign in to comment.