mirror of
https://github.com/GTNewHorizons/BloodMagic.git
synced 2026-11-27 07:13:14 +00:00
Compare commits
27
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
fd09bc9c8e | ||
|
|
711a0b8048 | ||
|
|
364d97238f | ||
|
|
287033fe8a | ||
|
|
7bc6d7bdef | ||
|
|
a6c282716b | ||
|
|
95872c2080 | ||
|
|
656ea1d065 | ||
|
|
a5af28d48d | ||
|
|
180c7c0f3e | ||
|
|
caca7c5fc7 | ||
|
|
efc0c52bc8 | ||
|
|
fc589690d0 | ||
|
|
3e40aa9708 | ||
|
|
8da3db4e65 | ||
|
|
b0096a3279 | ||
|
|
681fa92af5 | ||
|
|
e153c70116 | ||
|
|
1ea6d9c700 | ||
|
|
38a7bbbe55 | ||
|
|
082b41cb8c | ||
|
|
5a6c998070 | ||
|
|
b14aded91f | ||
|
|
46a8c566d7 | ||
|
|
ac59510594 | ||
|
|
d5a33f6f81 | ||
|
|
aad613b221 |
No files matched your search
+1
-1
@@ -40,5 +40,5 @@ dependencies {
|
||||
compileOnly("thaumcraft:Thaumcraft:1.7.10-4.2.3.5:dev") {transitive = false }
|
||||
compileOnly("curse.maven:guide-api-228832:2287185") {transitive = false }
|
||||
|
||||
compileOnly("com.github.GTNewHorizons:StructureLib:1.4.10:dev")
|
||||
compileOnly("com.github.GTNewHorizons:StructureLib:1.4.6:dev")
|
||||
}
|
||||
@@ -26,7 +26,7 @@ import com.google.common.base.Joiner;
|
||||
|
||||
import WayofTime.alchemicalWizardry.AlchemicalWizardry;
|
||||
import WayofTime.alchemicalWizardry.api.alchemy.energy.Reagent;
|
||||
import WayofTime.alchemicalWizardry.api.spell.APISpellHelper;
|
||||
import WayofTime.alchemicalWizardry.api.soulNetwork.SoulNetworkHandler;
|
||||
import WayofTime.alchemicalWizardry.client.nei.widgets.CostInfo;
|
||||
import WayofTime.alchemicalWizardry.client.nei.widgets.RadiusInfo;
|
||||
import WayofTime.alchemicalWizardry.client.nei.widgets.ReagentInfo;
|
||||
@@ -303,7 +303,7 @@ public class NEIMeteorRecipeHandler extends TemplateRecipeHandler {
|
||||
Rectangle rect = cachedRecipe.costInfo.getRect(gui);
|
||||
if (rect.contains(mousePos)) {
|
||||
list.add(StatCollector.translateToLocal("nei.recipe.meteor.cost"));
|
||||
if (APISpellHelper.getPlayerLPTag(mc.thePlayer) < cachedRecipe.getCost()) {
|
||||
if (SoulNetworkHandler.getCurrentEssence(mc.thePlayer.getDisplayName()) < cachedRecipe.getCost()) {
|
||||
list.add(
|
||||
EnumChatFormatting.RED
|
||||
+ StatCollector.translateToLocal("nei.recipe.meteor.tooExpensive"));
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
package WayofTime.alchemicalWizardry.client.nei.widgets;
|
||||
|
||||
import static WayofTime.alchemicalWizardry.client.ClientUtils.mc;
|
||||
import static WayofTime.alchemicalWizardry.client.nei.NEIConfig.getBloodOrbs;
|
||||
import static WayofTime.alchemicalWizardry.client.nei.NEIConfig.getOrbsByCapacity;
|
||||
|
||||
import java.awt.Rectangle;
|
||||
import java.util.ArrayList;
|
||||
@@ -13,14 +15,14 @@ import net.minecraft.item.ItemStack;
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import WayofTime.alchemicalWizardry.api.items.interfaces.IBloodOrb;
|
||||
import WayofTime.alchemicalWizardry.api.spell.APISpellHelper;
|
||||
import WayofTime.alchemicalWizardry.client.nei.NEIConfig;
|
||||
import WayofTime.alchemicalWizardry.api.soulNetwork.SoulNetworkHandler;
|
||||
import codechicken.nei.recipe.GuiRecipe;
|
||||
|
||||
public class CostInfo {
|
||||
|
||||
private final int cost;
|
||||
private int prevX, prevY;
|
||||
private final int orbLP;
|
||||
private final ItemStack orbStack;
|
||||
private static final RenderItem renderItem = new RenderItem();
|
||||
static {
|
||||
@@ -31,7 +33,8 @@ public class CostInfo {
|
||||
this.cost = cost;
|
||||
|
||||
Item orb = null;
|
||||
ArrayList<Item> orbList = NEIConfig.getOrbsByCapacity();
|
||||
getOrbsByCapacity();
|
||||
ArrayList<Item> orbList = getBloodOrbs();
|
||||
for (Item o : orbList) {
|
||||
if (((IBloodOrb) o).getMaxEssence() >= cost) {
|
||||
orb = o;
|
||||
@@ -42,6 +45,7 @@ public class CostInfo {
|
||||
orb = orbList.get(orbList.size() - 1);
|
||||
}
|
||||
|
||||
orbLP = ((IBloodOrb) orb).getMaxEssence();
|
||||
orbStack = new ItemStack(orb);
|
||||
}
|
||||
|
||||
@@ -53,11 +57,13 @@ public class CostInfo {
|
||||
prevX = x;
|
||||
prevY = y;
|
||||
|
||||
int currentLP = SoulNetworkHandler.getCurrentEssence(mc.thePlayer.getDisplayName());
|
||||
|
||||
GL11.glPushMatrix();
|
||||
GL11.glEnable(GL11.GL_BLEND);
|
||||
GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
|
||||
|
||||
if (cost > APISpellHelper.getPlayerLPTag(mc.thePlayer)) {
|
||||
if (orbLP > currentLP) {
|
||||
GL11.glColor4f(0.4f, 0.4f, 0.4f, 1.0f);
|
||||
} else {
|
||||
GL11.glColor4f(1.0f, 1.0f, 1.0f, 1.0f);
|
||||
|
||||
Reference in new issue
Block a user