Skip to content

Commit

Permalink
Ported to 1.16.3 without JEI 😢
Browse files Browse the repository at this point in the history
  • Loading branch information
MichaelHillcox committed Sep 12, 2020
1 parent f6eed0b commit 35d6c48
Show file tree
Hide file tree
Showing 5 changed files with 49 additions and 40 deletions.
9 changes: 9 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,15 @@
# Mining Gadgets Changelog
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),

## 1.16.3
### [1.6.0] - 2020-09-12
> note: Lots has been ported up from `1.16.1` since our first `1.16.2 ` release see:
> https://github.com/Direwolf20-MC/MiningGadgets/blob/master/CHANGELOG.md#142---2020-09-12 and
> https://github.com/Direwolf20-MC/MiningGadgets/blob/master/CHANGELOG.md#141---2020-08-21 for more info
#### Changed
- Ported to 1.16.3

## 1.16.2
### [1.5.1] - 2020-09-12
> note: Lots has been ported up from `1.16.1` since our first `1.16.2 ` release see:
Expand Down
4 changes: 2 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -113,8 +113,8 @@ dependencies {
minecraft "net.minecraftforge:forge:${forge_version}"

//JEI
compileOnly fg.deobf("mezz.jei:jei-${jei_version}:api")
runtimeOnly fg.deobf("mezz.jei:jei-${jei_version}")
// compileOnly fg.deobf("mezz.jei:jei-${jei_version}:api")
// runtimeOnly fg.deobf("mezz.jei:jei-${jei_version}")

// You may put jars on which you depend on in ./libs or you may define them like so..
// compile "some.group:artifact:version:classifier"
Expand Down
4 changes: 2 additions & 2 deletions gradle.properties
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
org.gradle.jvmargs=-Xmx3G
org.gradle.daemon=false
#Mod Info
mod_version=1.5.1
mod_version=1.16.3
#Dependencies
forge_version=1.16.2-33.0.61
forge_version=1.16.3-34.0.1
mcp_version=20200820-1.16.1
jei_version=1.16.2:7.3.2.25
Original file line number Diff line number Diff line change
@@ -1,35 +1,35 @@
package com.direwolf20.mininggadgets.client;

import com.direwolf20.mininggadgets.common.Config;
import com.direwolf20.mininggadgets.common.MiningGadgets;
import com.direwolf20.mininggadgets.common.items.MiningGadget;
import com.direwolf20.mininggadgets.common.items.ModItems;
import mezz.jei.api.IModPlugin;
import mezz.jei.api.JeiPlugin;
import mezz.jei.api.ingredients.subtypes.ISubtypeInterpreter;
import mezz.jei.api.registration.ISubtypeRegistration;
import net.minecraft.util.ResourceLocation;

@JeiPlugin
public class MiningGadgetsJEI implements IModPlugin {
@Override
public ResourceLocation getPluginUid() {
return new ResourceLocation(MiningGadgets.MOD_ID, "jei_plugin");
}

@Override
public void registerItemSubtypes(ISubtypeRegistration registration) {
registration.registerSubtypeInterpreter(ModItems.MININGGADGET.get(), itemStack -> {
if(!(itemStack.getItem() instanceof MiningGadget))
return ISubtypeInterpreter.NONE;

double energy = itemStack.getOrCreateTag().getDouble("energy");
if (energy == 0)
return "empty";
else if (energy == Config.MININGGADGET_MAXPOWER.get())
return "charged";

return ISubtypeInterpreter.NONE;
});
}
}
//import com.direwolf20.mininggadgets.common.Config;
//import com.direwolf20.mininggadgets.common.MiningGadgets;
//import com.direwolf20.mininggadgets.common.items.MiningGadget;
//import com.direwolf20.mininggadgets.common.items.ModItems;
//import mezz.jei.api.IModPlugin;
//import mezz.jei.api.JeiPlugin;
//import mezz.jei.api.ingredients.subtypes.ISubtypeInterpreter;
//import mezz.jei.api.registration.ISubtypeRegistration;
//import net.minecraft.util.ResourceLocation;
//
//@JeiPlugin
//public class MiningGadgetsJEI implements IModPlugin {
// @Override
// public ResourceLocation getPluginUid() {
// return new ResourceLocation(MiningGadgets.MOD_ID, "jei_plugin");
// }
//
// @Override
// public void registerItemSubtypes(ISubtypeRegistration registration) {
// registration.registerSubtypeInterpreter(ModItems.MININGGADGET.get(), itemStack -> {
// if(!(itemStack.getItem() instanceof MiningGadget))
// return ISubtypeInterpreter.NONE;
//
// double energy = itemStack.getOrCreateTag().getDouble("energy");
// if (energy == 0)
// return "empty";
// else if (energy == Config.MININGGADGET_MAXPOWER.get())
// return "charged";
//
// return ISubtypeInterpreter.NONE;
// });
// }
//}
6 changes: 3 additions & 3 deletions src/main/resources/META-INF/mods.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
modLoader="javafml"
loaderVersion="[33,)"
loaderVersion="[34,)"
issueTrackerURL="https://github.com/Direwolf20-MC/MiningGadgets"
license="MIT (https://github.com/Direwolf20-MC/MiningGadgets/blob/master/LICENSE.txt)"

Expand All @@ -18,14 +18,14 @@ description='''Mining is better with lasers.'''
[[dependencies.mininggadgets]]
modId="forge"
mandatory=true
versionRange="[33,)"
versionRange="[34,)"
ordering="NONE"
side="BOTH"

#minecraft
[[dependencies.mininggadgets]]
modId="minecraft"
mandatory=true
versionRange="[1.16.2]"
versionRange="[1.16.3]"
ordering="NONE"
side="BOTH"

0 comments on commit 35d6c48

Please sign in to comment.