forked from TAIGA/TAIGA
moved harvest level translation to client proxy
This commit is contained in:
@@ -5,8 +5,6 @@ import com.sosnitzka.taiga.proxy.CommonProxy;
|
||||
import com.sosnitzka.taiga.recipes.CraftingRegistry;
|
||||
import com.sosnitzka.taiga.recipes.SmeltingRegistry;
|
||||
import com.sosnitzka.taiga.world.WorldGen;
|
||||
import net.minecraft.client.resources.I18n;
|
||||
import net.minecraft.util.text.TextFormatting;
|
||||
import net.minecraftforge.fml.common.Mod;
|
||||
import net.minecraftforge.fml.common.Mod.EventHandler;
|
||||
import net.minecraftforge.fml.common.SidedProxy;
|
||||
@@ -32,7 +30,7 @@ import static slimeknights.tconstruct.library.utils.HarvestLevels.*;
|
||||
public class TAIGA {
|
||||
|
||||
public static final String MODID = "taiga";
|
||||
public static final String VERSION = "@VERSION@";
|
||||
public static final String VERSION = "1.12.2-1.3.3";
|
||||
public static final String GUIFACTORY = "com.sosnitzka.taiga.TAIGAGuiFactory";
|
||||
public static Logger logger;
|
||||
|
||||
@@ -66,9 +64,7 @@ public class TAIGA {
|
||||
// GameRegistry.registerFuelHandler(new FuelHandler()); Registeres fuels' burn times
|
||||
|
||||
// Adds new harvest levels' names
|
||||
harvestLevelNames.put(DURANITE, I18n.format("harvestlevel.duranite", TextFormatting.GREEN, TextFormatting.RESET));
|
||||
harvestLevelNames.put(VALYRIUM, I18n.format("harvestlevel.valyrium", TextFormatting.GOLD, TextFormatting.RESET));
|
||||
harvestLevelNames.put(VIBRANIUM, I18n.format("harvestlevel.vibranium", TextFormatting.DARK_PURPLE, TextFormatting.RESET));
|
||||
proxy.registerHarvestLevels();
|
||||
|
||||
Blocks.register(true);
|
||||
|
||||
|
@@ -12,9 +12,11 @@ import net.minecraft.client.renderer.ItemMeshDefinition;
|
||||
import net.minecraft.client.renderer.block.model.ModelResourceLocation;
|
||||
import net.minecraft.client.renderer.block.statemap.StateMapperBase;
|
||||
import net.minecraft.client.renderer.texture.TextureAtlasSprite;
|
||||
import net.minecraft.client.resources.I18n;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.util.text.TextFormatting;
|
||||
import net.minecraftforge.client.model.ModelLoader;
|
||||
import net.minecraftforge.fluids.Fluid;
|
||||
import net.minecraftforge.fml.client.registry.ClientRegistry;
|
||||
@@ -31,6 +33,7 @@ import static com.sosnitzka.taiga.Fluids.*;
|
||||
import static com.sosnitzka.taiga.Keybindings.altKey;
|
||||
import static com.sosnitzka.taiga.MaterialTraits.*;
|
||||
import static slimeknights.mantle.client.book.BookLoader.registerPageType;
|
||||
import static slimeknights.tconstruct.library.utils.HarvestLevels.harvestLevelNames;
|
||||
|
||||
@SuppressWarnings("unused")
|
||||
public class ClientProxy extends CommonProxy {
|
||||
@@ -164,4 +167,11 @@ public class ClientProxy extends CommonProxy {
|
||||
return location;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void registerHarvestLevels() {
|
||||
harvestLevelNames.put(DURANITE, I18n.format("harvestlevel.duranite", TextFormatting.GREEN, TextFormatting.RESET));
|
||||
harvestLevelNames.put(VALYRIUM, I18n.format("harvestlevel.valyrium", TextFormatting.GOLD, TextFormatting.RESET));
|
||||
harvestLevelNames.put(VIBRANIUM, I18n.format("harvestlevel.vibranium", TextFormatting.DARK_PURPLE, TextFormatting.RESET));
|
||||
}
|
||||
}
|
||||
|
@@ -5,6 +5,9 @@ import net.minecraftforge.fluids.Fluid;
|
||||
import net.minecraftforge.fml.common.event.FMLServerStartingEvent;
|
||||
import slimeknights.tconstruct.library.materials.Material;
|
||||
|
||||
import static com.sosnitzka.taiga.MaterialTraits.*;
|
||||
import static slimeknights.tconstruct.library.utils.HarvestLevels.harvestLevelNames;
|
||||
|
||||
public class CommonProxy {
|
||||
|
||||
public void registerModels() {
|
||||
@@ -31,4 +34,10 @@ public class CommonProxy {
|
||||
public void regsiterKeyBindings() {
|
||||
|
||||
}
|
||||
|
||||
public void registerHarvestLevels() {
|
||||
harvestLevelNames.put(DURANITE, "harvestlevel.duranite");
|
||||
harvestLevelNames.put(VALYRIUM, "harvestlevel.valyrium");
|
||||
harvestLevelNames.put(VIBRANIUM, "harvestlevel.vibranium");
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user