Change event priority for tooltip event

Makes sure the event is called after (as much as possible of course) all other tool tip events, so that the EMC value is always the last thing on the item tool tip and avoids it ending up in between the tooltips added by two different mods.
This commit is contained in:
ganymedes01 2014-01-06 16:56:17 +00:00
parent 146dc0a1de
commit cca58c6797

View file

@ -5,6 +5,7 @@ import com.pahimar.ee3.emc.EmcRegistry;
import com.pahimar.ee3.emc.EmcValue;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import net.minecraftforge.event.EventPriority;
import net.minecraftforge.event.ForgeSubscribe;
import net.minecraftforge.event.entity.player.ItemTooltipEvent;
import org.lwjgl.input.Keyboard;
@ -24,7 +25,7 @@ public class ItemTooltipEventHandler
private static boolean debug = true;
private static DecimalFormat emcDecimalFormat = new DecimalFormat("#.###");
@ForgeSubscribe
@ForgeSubscribe(priority = EventPriority.LOWEST)
public void handleItemTooltipEvent(ItemTooltipEvent event)
{
if (Keyboard.isKeyDown(Keyboard.KEY_LSHIFT) || Keyboard.isKeyDown(Keyboard.KEY_RSHIFT))