mirror of
https://github.com/HbmMods/Hbm-s-Nuclear-Tech-GIT.git
synced 2026-01-25 10:32:49 +00:00
Whoops!
This commit is contained in:
parent
4c944d6f2e
commit
fdb4a1c39e
@ -96,7 +96,7 @@ public class GUIBookLore extends GuiScreen {
|
||||
String k = "book_lore." + key + ".page.";
|
||||
|
||||
for(int i = 0; i < 2; i++) {
|
||||
int defacto = this.page * 2 + i; //TODO: force i18n to index from 0 instead of 1
|
||||
int defacto = this.page * 2 + i;
|
||||
|
||||
if(defacto < tag.getInteger("p")) {
|
||||
String text;
|
||||
|
||||
@ -142,83 +142,4 @@ public class ItemBookLore extends Item implements IGUIProvider {
|
||||
|
||||
book.stackTagCompound.setTag("p" + page, data);
|
||||
}
|
||||
//TODO remove this and fix any references
|
||||
/*public enum BookLoreType {
|
||||
TEST(true, "test", 5),
|
||||
BOOK_IODINE(true, "book_iodine", 3) {
|
||||
public String resolveKey(String key, NBTTagCompound tag) {
|
||||
return I18nUtil.resolveKey(key, tag.getInteger("mku_slot"));
|
||||
}},
|
||||
BOOK_PHOSPHOROUS(true, "book_phosphorous", 2) {
|
||||
public String resolveKey(String key, NBTTagCompound tag) {
|
||||
return I18nUtil.resolveKey(key, tag.getInteger("mku_slot"));
|
||||
}},
|
||||
BOOK_DUST(true, "book_dust", 3) {
|
||||
public String resolveKey(String key, NBTTagCompound tag) {
|
||||
return I18nUtil.resolveKey(key, tag.getInteger("mku_slot"));
|
||||
}},
|
||||
BOOK_MERCURY(true, "book_mercury", 2) {
|
||||
public String resolveKey(String key, NBTTagCompound tag) {
|
||||
return I18nUtil.resolveKey(key, tag.getInteger("mku_slot"));
|
||||
}},
|
||||
BOOK_FLOWER(true, "book_flower", 2) {
|
||||
public String resolveKey(String key, NBTTagCompound tag) {
|
||||
return I18nUtil.resolveKey(key, tag.getInteger("mku_slot"));
|
||||
}},
|
||||
BOOK_SYRINGE(true, "book_syringe", 2) {
|
||||
public String resolveKey(String key, NBTTagCompound tag) {
|
||||
return I18nUtil.resolveKey(key, tag.getInteger("mku_slot"));
|
||||
}},
|
||||
RESIGNATION_NOTE(true, "resignation_note", 3),
|
||||
MEMO_STOCKS(false, "memo_stocks", 1),
|
||||
MEMO_SCHRAB_GSA(false, "memo_schrab_gsa", 2),
|
||||
MEMO_SCHRAB_RD(false, "memo_schrab_rd", 4),
|
||||
MEMO_SCHRAB_NUKE(true, "memo_schrab_nuke", 3),
|
||||
;
|
||||
|
||||
public boolean hasAuthor = false;
|
||||
public final String keyI18n;
|
||||
public final int pages;
|
||||
|
||||
private BookLoreType(Boolean author, String key, int max) {
|
||||
this.hasAuthor = author;
|
||||
this.keyI18n = key;
|
||||
this.pages = max;
|
||||
}
|
||||
|
||||
private BookLoreType(String key, int max) {
|
||||
this.keyI18n = key;
|
||||
this.pages = max;
|
||||
}
|
||||
|
||||
/** Function to resolve I18n keys using potential save-dependent information, a la format specifiers. */
|
||||
/*public String resolveKey(String key, NBTTagCompound tag) {
|
||||
return I18nUtil.resolveKey(key, tag);
|
||||
}
|
||||
|
||||
public static BookLoreType getTypeFromStack(ItemStack stack) {
|
||||
if(!stack.hasTagCompound()) {
|
||||
stack.stackTagCompound = new NBTTagCompound();
|
||||
}
|
||||
|
||||
NBTTagCompound tag = stack.getTagCompound();
|
||||
int ordinal = tag.getInteger("Book_Lore_Type");
|
||||
|
||||
return BookLoreType.values()[Math.abs(ordinal) % BookLoreType.values().length];
|
||||
}
|
||||
|
||||
public static ItemStack setTypeForStack(ItemStack stack, BookLoreType num) {
|
||||
|
||||
if(stack.getItem() instanceof ItemBookLore) {
|
||||
if(!stack.hasTagCompound()) {
|
||||
stack.stackTagCompound = new NBTTagCompound();
|
||||
}
|
||||
|
||||
NBTTagCompound tag = stack.getTagCompound();
|
||||
tag.setInteger("Book_Lore_Type", num.ordinal());
|
||||
}
|
||||
|
||||
return stack;
|
||||
}
|
||||
}*/
|
||||
}
|
||||
|
||||
@ -2,6 +2,8 @@ package com.hbm.items.tool;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.hbm.handler.pollution.PollutionHandler;
|
||||
import com.hbm.handler.pollution.PollutionHandler.PollutionType;
|
||||
import com.hbm.lib.Library;
|
||||
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
@ -30,7 +32,7 @@ public class ItemWandD extends Item {
|
||||
vnt.setSFX(new ExplosionEffectStandard());
|
||||
vnt.explode();*/
|
||||
|
||||
//PollutionHandler.incrementPollution(world, pos.blockX, pos.blockY, pos.blockZ, PollutionType.SOOT, 15);
|
||||
PollutionHandler.incrementPollution(world, pos.blockX, pos.blockY, pos.blockZ, PollutionType.SOOT, 15);
|
||||
|
||||
/*TimeAnalyzer.startCount("setBlock");
|
||||
world.setBlock(pos.blockX, pos.blockY, pos.blockZ, Blocks.dirt);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user