29 lines
1.6 KiB
Diff
29 lines
1.6 KiB
Diff
--- a/net/minecraft/client/gui/DisplayEffectsScreen.java
|
|
+++ b/net/minecraft/client/gui/DisplayEffectsScreen.java
|
|
@@ -34,6 +34,7 @@
|
|
this.field_147003_i = (this.width - this.field_146999_f) / 2;
|
|
this.field_147045_u = false;
|
|
} else {
|
|
+ if (net.minecraftforge.common.MinecraftForge.EVENT_BUS.post(new net.minecraftforge.client.event.GuiScreenEvent.PotionShiftEvent(this))) this.field_147003_i = (this.width - this.field_146999_f) / 2; else
|
|
this.field_147003_i = 160 + (this.width - this.field_146999_f - 200) / 2;
|
|
this.field_147045_u = true;
|
|
}
|
|
@@ -58,7 +59,7 @@
|
|
j = 132 / (collection.size() - 1);
|
|
}
|
|
|
|
- Iterable<EffectInstance> iterable = Ordering.<EffectInstance>natural().sortedCopy(collection);
|
|
+ Iterable<EffectInstance> iterable = collection.stream().filter( effectInstance -> effectInstance.shouldRender()).sorted().collect(java.util.stream.Collectors.toList());
|
|
this.func_214079_a(i, j, iterable);
|
|
this.func_214077_b(i, j, iterable);
|
|
this.func_214078_c(i, j, iterable);
|
|
@@ -95,6 +96,8 @@
|
|
int i = this.field_147009_r;
|
|
|
|
for(EffectInstance effectinstance : p_214078_3_) {
|
|
+ effectinstance.renderInventoryEffect(this, p_214078_1_, i, this.getBlitOffset());
|
|
+ if (!effectinstance.shouldRenderInvText()) { i += p_214078_2_; continue; }
|
|
String s = I18n.func_135052_a(effectinstance.func_188419_a().func_76393_a());
|
|
if (effectinstance.func_76458_c() >= 1 && effectinstance.func_76458_c() <= 9) {
|
|
s = s + ' ' + I18n.func_135052_a("enchantment.level." + (effectinstance.func_76458_c() + 1));
|