Skip to content

Commit

Permalink
Merge pull request #10 from sddsd2332/main
Browse files Browse the repository at this point in the history
一些小更新
  • Loading branch information
warmthdawn authored Mar 14, 2022
2 parents 07373b7 + 53ca28e commit 18d2a22
Show file tree
Hide file tree
Showing 29 changed files with 343 additions and 76 deletions.
17 changes: 15 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -116,15 +116,20 @@ dependencies {
deobfCompile "curse.maven:thaumcraft-${thaumcraft_version}"
deobfCompile "curse.maven:mekanism-${mekanism_version}"
deobfCompile "curse.maven:prodigytech-${prodigytech_version}"


deobfCompile "curse.maven:bwmsuite-${bwm_suite}"
deobfCompile "curse.maven:immersiveengineering-${immersive_engineering}"
deobfCompile "curse.maven:immersivepetroleum-${immersive_petroleum}"
deobfCompile "curse.maven:extrautilities-${extra_utilities}"

deobfCompile("codechicken:CodeChickenLib:${mc_version}-${ccl_version}:universal") {
exclude group: "mezz.jei"
}
deobfCompile "curse.maven:computercraft-${computercraft_version}"


runtime "com.azanor.baubles:Baubles:${mc_short}-${baubles_version}"

runtime "curse.maven:bwmcore-${bwm_core}"


}
Expand All @@ -140,6 +145,14 @@ jar {
}
}


//Attempt to resolve GBK errors
tasks.withType(JavaCompile) {

options.encoding = "UTF-8"

}

processResources {
// this will ensure that this task is redone when the versions change.
inputs.property "version", project.version
Expand Down
7 changes: 6 additions & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -38,4 +38,9 @@ pneumaticcraft_repressurized_version=1.12.2-0.11.9-384
computercraft_version=282001:2694855
mekanism_version=268560:2835175
theoneprobe_version=1.12-1.4.28-17
prodigytech_version=297414:2769520
prodigytech_version=297414:2769520
bwm_suite=246760:3289033
bwm_core=294335:2624990
immersive_engineering=231951:2974106
immersive_petroleum=268250:3382321
extra_utilities=225561:2678374
4 changes: 2 additions & 2 deletions src/main/java/com/warmthdawn/mod/gugu_utils/GuGuUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,15 @@

@Mod(modid = GuGuUtils.MODID, name = GuGuUtils.NAME, version = GuGuUtils.VERSION, dependencies = GuGuUtils.DEPENDENCY)
public class GuGuUtils {
public static final String MODID = "gugu-utils";
public static final String MODID = "gugu-utils";
public static final String DEPENDENCY = "required-after:forge@[14.23.5.2847,);required-after:codechickenlib@[3.2.2,);required-after:mcjtylib_ng@[3.5.4,);" +
"after:modularmachinery;after:pneumaticcraft;after:naturesaura;";
public static final String NAME = "GuGu Utils";
public static final String VERSION = "@VERSION@";
public static final CreativeTabs creativeTab = new CreativeTabs(GuGuUtils.MODID) {
@Override
public ItemStack createIcon() {
return new ItemStack(Items.BOOK);
return new ItemStack(ModItems.constructionTool);
}

@Override
Expand Down
25 changes: 25 additions & 0 deletions src/main/java/com/warmthdawn/mod/gugu_utils/ModBlocks.java
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,20 @@ public class ModBlocks {
//热气输入仓
@GameRegistry.ObjectHolder(STRING_RESOURCE_HOTAIRHATCH_INPUT)
public static GenericBlock blockHotAirHatch;
//mek激光输入仓

//mek热量输入输出仓

//IE矿脉仓

//IE原油仓

//EXU

//blood




@SideOnly(Side.CLIENT)
public static void initModels() {
Expand All @@ -87,6 +101,8 @@ public static void initModels() {
blockPressureHatch.initModel();
if(Enables.PRODIGYTECH)
blockHotAirHatch.initModel();


}
}

Expand Down Expand Up @@ -133,6 +149,15 @@ public static void register(IForgeRegistry<Block> registry) {
registry.register(new BlockHotAirInputHatch());
GameRegistry.registerTileEntity(TileHotAirInputHatch.class, RESOURCE_TILE_HOTAIRHATCH_INPUT);
}
/*if (Enables.MEKANISM){
//mek
// registry.register(new);
// GameRegistry.registerTileEntity(, );
//mek
// registry.register(new);
/// GameRegistry.registerTileEntity();
// GameRegistry.registerTileEntity();
}*/
}
}

Expand Down
8 changes: 4 additions & 4 deletions src/main/java/com/warmthdawn/mod/gugu_utils/ModItems.java
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
import com.warmthdawn.mod.gugu_utils.botania.lens.ItemLensTransform;
import com.warmthdawn.mod.gugu_utils.common.Enables;
import com.warmthdawn.mod.gugu_utils.common.VariantItem;
import com.warmthdawn.mod.gugu_utils.config.TweaksConfig;
import com.warmthdawn.mod.gugu_utils.config.GuGuUtilsConfig;
import com.warmthdawn.mod.gugu_utils.modularmachenary.aspect.BlockAspectHatch;
import com.warmthdawn.mod.gugu_utils.modularmachenary.embers.BlockEmberInputHatch;
import com.warmthdawn.mod.gugu_utils.modularmachenary.mana.BlockSparkManaHatch;
Expand Down Expand Up @@ -48,10 +48,10 @@ public static void initModels() {
public static void register(IForgeRegistry<Item> registry) {

if (Enables.BOTANIA) {
if (TweaksConfig.TWEAKE_LENS) {
if (TweaksConfig.ENABLE_LENS_OVERCLOCKING)
if (GuGuUtilsConfig.Tweaks.TWEAKE_LENS) {
if (GuGuUtilsConfig.Tweaks.ENABLE_LENS_OVERCLOCKING)
registry.register(new ItemLensOverclocking().setRegistryName(RESOURCE_LENS_OVERCLOCKING));
if (TweaksConfig.ENABLE_LENS_TRASNFORM)
if (GuGuUtilsConfig.Tweaks.ENABLE_LENS_TRASNFORM)
registry.register(new ItemLensTransform().setRegistryName(RESOURCE_LENS_TRANSFORM));
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import com.google.common.collect.BiMap;
import com.warmthdawn.mod.gugu_utils.botania.subtitle.*;
import com.warmthdawn.mod.gugu_utils.config.TweaksConfig;
import com.warmthdawn.mod.gugu_utils.config.GuGuUtilsConfig;
import vazkii.botania.api.BotaniaAPI;
import vazkii.botania.api.subtile.SubTileEntity;
import vazkii.botania.common.lib.LibBlockNames;
Expand All @@ -23,27 +23,27 @@ public SubtileRegisterOverride() {


public void reRegisterSubtile() {
if (TweaksConfig.TWEAKS_GENERATORS) {
if (GuGuUtilsConfig.Tweaks.TWEAKS_GENERATORS) {
//重新注册热爆花(产魔8000,阻止刷TNT)
if (TweaksConfig.SHULKMENOT_GENERATIONG_MULTIPLE != 1.0 || TweaksConfig.ENTROPINNYUM_NOT_ACCEPT_COPY_TNT)
if (GuGuUtilsConfig.Tweaks.SHULKMENOT_GENERATIONG_MULTIPLE != 1.0 || GuGuUtilsConfig.Tweaks.ENTROPINNYUM_NOT_ACCEPT_COPY_TNT)
registerSubTileForce(LibBlockNames.SUBTILE_ENTROPINNYUM, SubTileEntropinnyumModified.class);
//重新注册阿卡纳(禁止堆)
if (TweaksConfig.TWEAK_ARCANEROSE_EFFICIENCY)
if (GuGuUtilsConfig.Tweaks.TWEAK_ARCANEROSE_EFFICIENCY)
registerSubTileForce(LibBlockNames.SUBTILE_ARCANE_ROSE, SubTileArcaneRoseModified.class);
//重新注册火红莲(禁止堆)
if (TweaksConfig.TWEAK_ENDOFLAME_EFFICIENCY)
if (GuGuUtilsConfig.Tweaks.TWEAK_ENDOFLAME_EFFICIENCY)
registerSubTileForce(LibBlockNames.SUBTILE_ENDOFLAME, SubTileEndoflameModified.class);
//重新注册勿落草(产魔1.25倍)
if (TweaksConfig.SHULKMENOT_GENERATIONG_MULTIPLE != 1.0)
if (GuGuUtilsConfig.Tweaks.SHULKMENOT_GENERATIONG_MULTIPLE != 1.0)
registerSubTileForce(LibBlockNames.SUBTILE_SHULK_ME_NOT, SubTileShulkMeNotModified.class);
//重新注册斑斓花(产魔2倍)
if (TweaksConfig.SPECTROLUS_GENERATIONG_MULTIPLE != 1.0)
if (GuGuUtilsConfig.Tweaks.SPECTROLUS_GENERATIONG_MULTIPLE != 1.0)
registerSubTileForce(LibBlockNames.SUBTILE_SPECTROLUS, SubTileSpectrolusModified.class);
//重新注册启命英(产魔4倍)
if (TweaksConfig.DANDELIFEON_GENERATING_MULTIPLE != 1.0)
if (GuGuUtilsConfig.Tweaks.DANDELIFEON_GENERATING_MULTIPLE != 1.0)
registerSubTileForce(LibBlockNames.SUBTILE_DANDELIFEON, SubTileDandelifeonModified.class);
//重新注册噬草花(产魔2倍)
if (TweaksConfig.RAFFLOWSIA_GENERATIONG_MULTIPLE != 1.0)
if (GuGuUtilsConfig.Tweaks.RAFFLOWSIA_GENERATIONG_MULTIPLE != 1.0)
registerSubTileForce(LibBlockNames.SUBTILE_RAFFLOWSIA, SubTileRafflowsiaModified.class);
}
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.warmthdawn.mod.gugu_utils.botania.subtitle;

import com.warmthdawn.mod.gugu_utils.config.TweaksConfig;
import com.warmthdawn.mod.gugu_utils.config.GuGuUtilsConfig;
import net.minecraft.client.Minecraft;
import net.minecraft.client.gui.ScaledResolution;
import net.minecraft.entity.item.EntityXPOrb;
Expand Down Expand Up @@ -29,7 +29,7 @@ public void onUpdate() {
if (!supertile.getWorld().isRemote && (flowerNum < 0 || ticksExisted % 80 == 0)) {
flowerNum = Tools.getNearbyFlowers(getWorld(), getPos(), RANGE + 1,
te -> te instanceof SubTileArcaneRoseModified || te instanceof SubTileArcaneRose);
efficiency = Tools.getOutputEfficiency(flowerNum, TweaksConfig.ARCANEROSE_MAX_FLOWERS);
efficiency = Tools.getOutputEfficiency(flowerNum, GuGuUtilsConfig.Tweaks.ARCANEROSE_MAX_FLOWERS);
}
super.onUpdate();

Expand Down Expand Up @@ -78,7 +78,7 @@ public LexiconEntry getEntry() {
@Override
public void renderHUD(Minecraft mc, ScaledResolution res) {
super.renderHUD(mc, res);
Tools.renderTooManyFlowers(mc, res, flowerNum, TweaksConfig.ARCANEROSE_MAX_FLOWERS);
Tools.renderTooManyFlowers(mc, res, flowerNum, GuGuUtilsConfig.Tweaks.ARCANEROSE_MAX_FLOWERS);

}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.warmthdawn.mod.gugu_utils.botania.subtitle;

import com.warmthdawn.mod.gugu_utils.config.TweaksConfig;
import com.warmthdawn.mod.gugu_utils.config.GuGuUtilsConfig;
import net.minecraft.block.Block;
import net.minecraft.block.state.IBlockState;
import net.minecraft.tileentity.TileEntity;
Expand Down Expand Up @@ -36,8 +36,8 @@ public class SubTileDandelifeonModified extends SubTileGenerating {
private int MAX_MANA = 100000;

public SubTileDandelifeonModified() {
this.MAX_MANA_GENERATIONS = (int) (MAX_MANA_GENERATIONS * TweaksConfig.DANDELIFEON_GENERATING_MULTIPLE);
this.MAX_MANA = (int) (MAX_MANA * TweaksConfig.DANDELIFEON_GENERATING_MULTIPLE);
this.MAX_MANA_GENERATIONS = (int) (MAX_MANA_GENERATIONS * GuGuUtilsConfig.Tweaks.DANDELIFEON_GENERATING_MULTIPLE);
this.MAX_MANA = (int) (MAX_MANA * GuGuUtilsConfig.Tweaks.DANDELIFEON_GENERATING_MULTIPLE);
}

@Override
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.warmthdawn.mod.gugu_utils.botania.subtitle;

import com.warmthdawn.mod.gugu_utils.config.TweaksConfig;
import com.warmthdawn.mod.gugu_utils.config.GuGuUtilsConfig;
import net.minecraft.client.Minecraft;
import net.minecraft.client.gui.ScaledResolution;
import net.minecraft.nbt.NBTTagCompound;
Expand Down Expand Up @@ -38,7 +38,7 @@ public void onUpdate() {
if (!supertile.getWorld().isRemote && (flowerNum < 0 || ticksExisted % 80 == 0)) {
flowerNum = Tools.getNearbyFlowers(getWorld(), getPos(), RANGE + 2,
ste -> ste instanceof SubTileEndoflame && ((SubTileEndoflame) ste).canGeneratePassively());
setEfficiency(Tools.getOutputEfficiency(flowerNum, TweaksConfig.ENDOFLAME_MAX_FLOWERS));
setEfficiency(Tools.getOutputEfficiency(flowerNum, GuGuUtilsConfig.Tweaks.ENDOFLAME_MAX_FLOWERS));
}
}

Expand All @@ -56,7 +56,7 @@ public int getDelayBetweenPassiveGeneration() {
@Override
public void renderHUD(Minecraft mc, ScaledResolution res) {
super.renderHUD(mc, res);
Tools.renderTooManyFlowers(mc, res, flowerNum, TweaksConfig.ENDOFLAME_MAX_FLOWERS);
Tools.renderTooManyFlowers(mc, res, flowerNum, GuGuUtilsConfig.Tweaks.ENDOFLAME_MAX_FLOWERS);
}


Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.warmthdawn.mod.gugu_utils.botania.subtitle;

import com.warmthdawn.mod.gugu_utils.config.TweaksConfig;
import com.warmthdawn.mod.gugu_utils.config.GuGuUtilsConfig;
import net.minecraft.entity.Entity;
import net.minecraft.entity.item.EntityTNTPrimed;
import net.minecraft.init.SoundEvents;
Expand Down Expand Up @@ -80,7 +80,7 @@ public int getColor() {

@Override
public int getMaxMana() {
return TweaksConfig.ENTROPINNYUM_GENERATING;
return GuGuUtilsConfig.Tweaks.ENTROPINNYUM_GENERATING;
}

@Override
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.warmthdawn.mod.gugu_utils.botania.subtitle;

import com.warmthdawn.mod.gugu_utils.config.TweaksConfig;
import com.warmthdawn.mod.gugu_utils.config.GuGuUtilsConfig;
import net.minecraft.block.state.IBlockState;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.item.ItemStack;
Expand Down Expand Up @@ -29,8 +29,8 @@ public class SubTileRafflowsiaModified extends SubTileGenerating {
String lastFlower;
int lastFlowerTimes;
public SubTileRafflowsiaModified() {
SINGLE_MANA = (int) (2100 * TweaksConfig.RAFFLOWSIA_GENERATIONG_MULTIPLE);
MAX_MANA = (int) (9000 * TweaksConfig.RAFFLOWSIA_GENERATIONG_MULTIPLE);
SINGLE_MANA = (int) (2100 * GuGuUtilsConfig.Tweaks.RAFFLOWSIA_GENERATIONG_MULTIPLE);
MAX_MANA = (int) (9000 * GuGuUtilsConfig.Tweaks.RAFFLOWSIA_GENERATIONG_MULTIPLE);
}

@Override
Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
package com.warmthdawn.mod.gugu_utils.botania.subtitle;

import com.warmthdawn.mod.gugu_utils.config.TweaksConfig;
import com.warmthdawn.mod.gugu_utils.config.GuGuUtilsConfig;
import vazkii.botania.common.block.subtile.generating.SubTileShulkMeNot;

public class SubTileShulkMeNotModified extends SubTileShulkMeNot {

private final int MAX_MANA;

public SubTileShulkMeNotModified() {
MAX_MANA = (int) (super.getMaxMana() * TweaksConfig.SHULKMENOT_GENERATIONG_MULTIPLE);
MAX_MANA = (int) (super.getMaxMana() * GuGuUtilsConfig.Tweaks.SHULKMENOT_GENERATIONG_MULTIPLE);
}

@Override
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.warmthdawn.mod.gugu_utils.botania.subtitle;

import com.warmthdawn.mod.gugu_utils.config.TweaksConfig;
import com.warmthdawn.mod.gugu_utils.config.GuGuUtilsConfig;
import net.minecraft.client.Minecraft;
import net.minecraft.client.gui.ScaledResolution;
import net.minecraft.client.renderer.GlStateManager;
Expand Down Expand Up @@ -33,7 +33,7 @@ public class SubTileSpectrolusModified extends SubTileGenerating {
int nextColor;

public SubTileSpectrolusModified() {
SINGLE_MANA = (int) (2400 * TweaksConfig.SPECTROLUS_GENERATIONG_MULTIPLE);
SINGLE_MANA = (int) (2400 * GuGuUtilsConfig.Tweaks.SPECTROLUS_GENERATIONG_MULTIPLE);
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ public class Constants {
public static final ResourceLocation RESOURCE_COMPRESSED_AIR_PER_TICK = new ResourceLocation(GuGuUtils.MODID , "compressed_air_pertick");
public static final String STRING_RESOURCE_COMPRESSED_AIR = GuGuUtils.MODID + ":" + "compressed_air";


public static final ResourceLocation RESOURCE_HOT_AIR = new ResourceLocation(GuGuUtils.MODID , "hot_air");
public static final String STRING_RESOURCE_HOT_AIR = GuGuUtils.MODID + ":" + "hot_air";

Expand Down
25 changes: 14 additions & 11 deletions src/main/java/com/warmthdawn/mod/gugu_utils/common/Enables.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.warmthdawn.mod.gugu_utils.common;

import com.warmthdawn.mod.gugu_utils.config.PluginsConfig;
import com.warmthdawn.mod.gugu_utils.config.GuGuUtilsConfig;
import net.minecraftforge.fml.common.Loader;

public final class Enables {
Expand All @@ -19,22 +19,25 @@ public final class Enables {
public static boolean THAUMCRAFT = false;
public static boolean PNEUMATICCRAFT = false;
public static boolean PRODIGYTECH = false;
public static boolean MEKANISM = false;

public static void init() {
Enables.BOTANIA = PluginsConfig.ENABLE_BOTANIA_SUPPORT && Loader.isModLoaded("botania");
Enables.ASTRAL_SORCERY = PluginsConfig.ENABLE_ASTRAL_SORCERY_SUPPORT && Loader.isModLoaded("astralsorcery");
Enables.EMBERS = PluginsConfig.ENABLE_EMBERS_SUPPORT && Loader.isModLoaded("embers");
Enables.MODULAR_MACHIENARY = PluginsConfig.ENABLE_MODULAR_MACHIENARY_SUPPORT && Loader.isModLoaded("modularmachinery");
Enables.PSI = PluginsConfig.ENABLE_PSI_SUPPORT && Loader.isModLoaded("psi");
Enables.BOTANIA = GuGuUtilsConfig.Plugins.ENABLE_BOTANIA_SUPPORT && Loader.isModLoaded("botania");
Enables.ASTRAL_SORCERY = GuGuUtilsConfig.Plugins.ENABLE_ASTRAL_SORCERY_SUPPORT && Loader.isModLoaded("astralsorcery");
Enables.EMBERS = GuGuUtilsConfig.Plugins.ENABLE_EMBERS_SUPPORT && Loader.isModLoaded("embers");
Enables.MODULAR_MACHIENARY = GuGuUtilsConfig.Plugins.ENABLE_MODULAR_MACHIENARY_SUPPORT && Loader.isModLoaded("modularmachinery");
Enables.PSI = GuGuUtilsConfig.Plugins.ENABLE_PSI_SUPPORT && Loader.isModLoaded("psi");
Enables.CRAFT_TWEAKER = Loader.isModLoaded("crafttweaker");
Enables.THERMAL_DYNAMICS = Loader.isModLoaded("thermaldynamics");
Enables.APPLIED_ENERGISTICS = Loader.isModLoaded("appliedenergistics2");
Enables.BOTANIA_TWEAKS = Loader.isModLoaded("botania_tweaks");
Enables.ACTUALLY_ADDITIONS = Loader.isModLoaded("actuallyadditions");
Enables.NATURES_AURA = PluginsConfig.ENABLE_NATURES_AURA_SUPPORT && Loader.isModLoaded("naturesaura");
Enables.BLOOD_MAGIC = PluginsConfig.ENABLE_BLOOD_MAGIC_SUPPORT && Loader.isModLoaded("bloodmagic");
Enables.THAUMCRAFT = PluginsConfig.ENABLE_THAUMCRAFT_SUPPORT && Loader.isModLoaded("thaumcraft");
Enables.PNEUMATICCRAFT = PluginsConfig.ENABLE_PNEUMATICCRAFT_SUPPORT && Loader.isModLoaded("pneumaticcraft");
Enables.PRODIGYTECH = PluginsConfig.ENABLE_PRODIGYTECH_SUPPORT && Loader.isModLoaded("prodigytech");
Enables.NATURES_AURA = GuGuUtilsConfig.Plugins.ENABLE_NATURES_AURA_SUPPORT && Loader.isModLoaded("naturesaura");
Enables.BLOOD_MAGIC = GuGuUtilsConfig.Plugins.ENABLE_BLOOD_MAGIC_SUPPORT && Loader.isModLoaded("bloodmagic");
Enables.THAUMCRAFT = GuGuUtilsConfig.Plugins.ENABLE_THAUMCRAFT_SUPPORT && Loader.isModLoaded("thaumcraft");
Enables.PNEUMATICCRAFT = GuGuUtilsConfig.Plugins.ENABLE_PNEUMATICCRAFT_SUPPORT && Loader.isModLoaded("pneumaticcraft");
Enables.PRODIGYTECH = GuGuUtilsConfig.Plugins.ENABLE_PRODIGYTECH_SUPPORT && Loader.isModLoaded("prodigytech");
Enables.MEKANISM = Loader.isModLoaded("mekanism");

}
}
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
/*
package com.warmthdawn.mod.gugu_utils.config;
import com.warmthdawn.mod.gugu_utils.GuGuUtils;
import net.minecraftforge.common.config.Config;
@Config(modid = "gugu-utils", category = "Core")
public class CoreConfig {
@Config(modid = GuGuUtils.MODID, name = "Core")
public class CoreConfig {
@Config.Comment("Actions when a recipe failure whit per tick input, can be 'reset', 'still' and 'decrease'.")
public static String DEFAULT_RECIPE_FAILURE_ACTION = "reset";
}
*/
Loading

0 comments on commit 18d2a22

Please sign in to comment.