mirror of
https://github.com/HbmMods/Hbm-s-Nuclear-Tech-GIT.git
synced 2026-01-25 10:32:49 +00:00
flixes
This commit is contained in:
parent
e03ad3edfb
commit
99aa9da490
@ -1,7 +1,9 @@
|
||||
## Changed
|
||||
* Added more QMAW manual pages
|
||||
* WIAJ presentations now use a configurable keybind, like QMAW
|
||||
* The default keybind is now F5, in order to not collide with QMAW's F1
|
||||
* WIAJ presentations now use the same configurable keybind as QMAW
|
||||
* Shift has to be held for the presentations, while F1 will open the standard QMAW page
|
||||
* Double UZIs no longer render weirdly when dropped
|
||||
|
||||
## Fixed
|
||||
* Fixed fusion reactor item IO being broken
|
||||
* Fixed issue with the chemical factory where the declogging feature would be triggered by a recipe processor that doesn't even own the reported slot
|
||||
@ -39,7 +39,6 @@ public class HbmKeybinds {
|
||||
public static KeyBinding trainKey = new KeyBinding(category + ".trainInv", Keyboard.KEY_R, category);
|
||||
|
||||
public static KeyBinding qmaw = new KeyBinding(category + ".qmaw", Keyboard.KEY_F1, category);
|
||||
public static KeyBinding wiaj = new KeyBinding(category + ".wiaj", Keyboard.KEY_F5, category);
|
||||
|
||||
public static KeyBinding abilityCycle = new KeyBinding(category + ".ability", -99, category);
|
||||
public static KeyBinding abilityAlt = new KeyBinding(category + ".abilityAlt", Keyboard.KEY_LMENU, category);
|
||||
@ -66,7 +65,6 @@ public class HbmKeybinds {
|
||||
ClientRegistry.registerKeyBinding(trainKey);
|
||||
|
||||
ClientRegistry.registerKeyBinding(qmaw);
|
||||
ClientRegistry.registerKeyBinding(wiaj);
|
||||
|
||||
ClientRegistry.registerKeyBinding(reloadKey);
|
||||
ClientRegistry.registerKeyBinding(gunPrimaryKey);
|
||||
|
||||
@ -658,11 +658,11 @@ public class OreDictManager {
|
||||
for(NTMMaterial mat : Mats.orderedList) {
|
||||
if(mat.autogen.contains(MaterialShapes.FRAGMENT)) {
|
||||
String name = mat.names[0];
|
||||
if(!OreDictionary.getOres(MaterialShapes.DUST.name() + name).isEmpty()) MineralRecipes.add9To1(mat.make(ModItems.bedrock_ore_fragment), OreDictionary.getOres(MaterialShapes.DUST.name() + name).get(0));
|
||||
else if(!OreDictionary.getOres(MaterialShapes.GEM.name() + name).isEmpty()) MineralRecipes.add9To1(mat.make(ModItems.bedrock_ore_fragment), OreDictionary.getOres(MaterialShapes.GEM.name() + name).get(0));
|
||||
else if(!OreDictionary.getOres(MaterialShapes.CRYSTAL.name() + name).isEmpty()) MineralRecipes.add9To1(mat.make(ModItems.bedrock_ore_fragment), OreDictionary.getOres(MaterialShapes.CRYSTAL.name() + name).get(0));
|
||||
else if(!OreDictionary.getOres(MaterialShapes.INGOT.name() + name).isEmpty()) MineralRecipes.add9To1(mat.make(ModItems.bedrock_ore_fragment), OreDictionary.getOres(MaterialShapes.INGOT.name() + name).get(0));
|
||||
else if(!OreDictionary.getOres(MaterialShapes.BILLET.name() + name).isEmpty()) MineralRecipes.addBilletFragment(OreDictionary.getOres(MaterialShapes.BILLET.name() + name).get(0), mat.make(ModItems.bedrock_ore_fragment));
|
||||
if(!OreDictionary.getOres(MaterialShapes.DUST.name() + name).isEmpty()) MineralRecipes.add9To1(mat.make(ModItems.bedrock_ore_fragment), OreDictionary.getOres(MaterialShapes.DUST.name() + name).get(0).copy());
|
||||
else if(!OreDictionary.getOres(MaterialShapes.GEM.name() + name).isEmpty()) MineralRecipes.add9To1(mat.make(ModItems.bedrock_ore_fragment), OreDictionary.getOres(MaterialShapes.GEM.name() + name).get(0).copy());
|
||||
else if(!OreDictionary.getOres(MaterialShapes.CRYSTAL.name() + name).isEmpty()) MineralRecipes.add9To1(mat.make(ModItems.bedrock_ore_fragment), OreDictionary.getOres(MaterialShapes.CRYSTAL.name() + name).get(0).copy());
|
||||
else if(!OreDictionary.getOres(MaterialShapes.INGOT.name() + name).isEmpty()) MineralRecipes.add9To1(mat.make(ModItems.bedrock_ore_fragment), OreDictionary.getOres(MaterialShapes.INGOT.name() + name).get(0).copy());
|
||||
else if(!OreDictionary.getOres(MaterialShapes.BILLET.name() + name).isEmpty()) MineralRecipes.addBilletFragment(OreDictionary.getOres(MaterialShapes.BILLET.name() + name).get(0).copy(), mat.make(ModItems.bedrock_ore_fragment));
|
||||
else MineralRecipes.add9To1(mat.make(ModItems.bedrock_ore_fragment), new ItemStack(ModItems.nothing));
|
||||
}
|
||||
}
|
||||
|
||||
@ -229,7 +229,7 @@ public abstract class MagazineSingleTypeBase implements IMagazine<BulletConfig>
|
||||
|
||||
@Override public int getCapacity(ItemStack stack) { return capacity; }
|
||||
@Override public int getAmount(ItemStack stack, IInventory inventory) { return getMagCount(stack, index); }
|
||||
@Override public void setAmount(ItemStack stack, int amount) { setMagCount(stack, index, amount); }
|
||||
@Override public void setAmount(ItemStack stack, int amount) { setMagCount(stack, index, Math.max(amount, 0)); }
|
||||
|
||||
@Override public void setAmountBeforeReload(ItemStack stack, int amount) { ItemGunBaseNT.setValueInt(stack, KEY_MAG_PREV + index, amount); }
|
||||
@Override public int getAmountBeforeReload(ItemStack stack) { return ItemGunBaseNT.getValueInt(stack, KEY_MAG_PREV + index); }
|
||||
|
||||
@ -742,17 +742,6 @@ public class ModEventHandlerClient {
|
||||
}
|
||||
}
|
||||
|
||||
try {
|
||||
CanneryBase cannery = Jars.canneries.get(comp);
|
||||
if(cannery != null) {
|
||||
list.add(EnumChatFormatting.GREEN + I18nUtil.resolveKey("cannery.f1", Keyboard.getKeyName(HbmKeybinds.wiaj.getKeyCode())));
|
||||
lastCannery = comp;
|
||||
canneryTimestamp = Clock.get_ms();
|
||||
}
|
||||
} catch(Exception ex) {
|
||||
list.add(EnumChatFormatting.RED + "Error loading cannery: " + ex.getLocalizedMessage());
|
||||
}
|
||||
|
||||
try {
|
||||
QuickManualAndWiki qmaw = QMAWLoader.triggers.get(comp);
|
||||
if(qmaw == null) {
|
||||
@ -767,6 +756,17 @@ public class ModEventHandlerClient {
|
||||
list.add(EnumChatFormatting.RED + "Error loading cannery: " + ex.getLocalizedMessage());
|
||||
}
|
||||
|
||||
try {
|
||||
CanneryBase cannery = Jars.canneries.get(comp);
|
||||
if(cannery != null) {
|
||||
list.add(EnumChatFormatting.GREEN + I18nUtil.resolveKey("cannery.f1", Keyboard.getKeyName(Keyboard.KEY_LSHIFT) + " + " + Keyboard.getKeyName(HbmKeybinds.qmaw.getKeyCode())));
|
||||
lastCannery = comp;
|
||||
canneryTimestamp = Clock.get_ms();
|
||||
}
|
||||
} catch(Exception ex) {
|
||||
list.add(EnumChatFormatting.RED + "Error loading cannery: " + ex.getLocalizedMessage());
|
||||
}
|
||||
|
||||
/*ItemStack copy = stack.copy();
|
||||
List<MaterialStack> materials = Mats.getMaterialsFromItem(copy);
|
||||
|
||||
@ -895,7 +895,7 @@ public class ModEventHandlerClient {
|
||||
}
|
||||
}
|
||||
|
||||
if(Keyboard.isKeyDown(HbmKeybinds.wiaj.getKeyCode()) && Minecraft.getMinecraft().currentScreen != null) {
|
||||
if(Keyboard.isKeyDown(HbmKeybinds.qmaw.getKeyCode()) && Keyboard.isKeyDown(Keyboard.KEY_LSHIFT) && Minecraft.getMinecraft().currentScreen != null) {
|
||||
|
||||
ComparableStack comp = canneryTimestamp > Clock.get_ms() - 100 ? lastCannery : null;
|
||||
|
||||
@ -913,7 +913,7 @@ public class ModEventHandlerClient {
|
||||
}
|
||||
}
|
||||
|
||||
if(Keyboard.isKeyDown(HbmKeybinds.qmaw.getKeyCode()) && Minecraft.getMinecraft().currentScreen != null) {
|
||||
if(Keyboard.isKeyDown(HbmKeybinds.qmaw.getKeyCode()) && !Keyboard.isKeyDown(Keyboard.KEY_LSHIFT) && Minecraft.getMinecraft().currentScreen != null) {
|
||||
|
||||
QuickManualAndWiki qmaw = qmawTimestamp > Clock.get_ms() - 100 ? lastQMAW : null;
|
||||
|
||||
|
||||
@ -201,6 +201,9 @@ public abstract class ModuleMachineBase {
|
||||
|
||||
/** Returns true if the supplied slot is occupied with an item that does not match the recipe */
|
||||
public boolean isSlotClogged(int slot) {
|
||||
boolean isSlotValid = false;
|
||||
for(int i : inputSlots) if(i == slot) isSlotValid = true;
|
||||
if(!isSlotValid) return false;
|
||||
ItemStack stack = slots[slot];
|
||||
if(stack == null) return false;
|
||||
return !isItemValid(slot, stack); // we need to use this because it also handles autoswitch correctly, otherwise autoswitch items may be ejected instantly
|
||||
|
||||
@ -195,6 +195,43 @@ public class ItemRenderUziAkimbo extends ItemRenderWeaponBase {
|
||||
GL11.glShadeModel(GL11.GL_FLAT);
|
||||
}
|
||||
|
||||
public void renderEntity(ItemStack stack) {
|
||||
GL11.glEnable(GL11.GL_LIGHTING);
|
||||
GL11.glShadeModel(GL11.GL_SMOOTH);
|
||||
|
||||
boolean silencer0 = hasSilencer(stack, 1);
|
||||
boolean silencer1 = hasSilencer(stack, 0);
|
||||
boolean anySilenced = silencer0 || silencer1;
|
||||
|
||||
if(anySilenced) {
|
||||
GL11.glScaled(0.75, 0.75, 0.75);
|
||||
}
|
||||
|
||||
GL11.glPushMatrix();
|
||||
GL11.glTranslated(-1, 1, 0);
|
||||
Minecraft.getMinecraft().renderEngine.bindTexture(isSaturnite(stack, 1) ? ResourceManager.uzi_saturnite_tex : ResourceManager.uzi_tex);
|
||||
ResourceManager.uzi.renderPart("Gun");
|
||||
ResourceManager.uzi.renderPart("StockBack");
|
||||
ResourceManager.uzi.renderPart("StockFront");
|
||||
ResourceManager.uzi.renderPart("Slide");
|
||||
ResourceManager.uzi.renderPart("Magazine");
|
||||
if(silencer0) ResourceManager.uzi.renderPart("Silencer");
|
||||
GL11.glPopMatrix();
|
||||
|
||||
GL11.glPushMatrix();
|
||||
GL11.glTranslated(1, 1, 0);
|
||||
Minecraft.getMinecraft().renderEngine.bindTexture(isSaturnite(stack, 0) ? ResourceManager.uzi_saturnite_tex : ResourceManager.uzi_tex);
|
||||
ResourceManager.uzi.renderPart("GunMirror");
|
||||
ResourceManager.uzi.renderPart("StockBack");
|
||||
ResourceManager.uzi.renderPart("StockFront");
|
||||
ResourceManager.uzi.renderPart("Slide");
|
||||
ResourceManager.uzi.renderPart("Magazine");
|
||||
if(silencer1) ResourceManager.uzi.renderPart("Silencer");
|
||||
GL11.glPopMatrix();
|
||||
|
||||
GL11.glShadeModel(GL11.GL_FLAT);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void renderOther(ItemStack stack, ItemRenderType type) {
|
||||
GL11.glEnable(GL11.GL_LIGHTING);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user