1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
|
package darkknight.jewelrycraft.container;
import java.util.ArrayList;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import darkknight.jewelrycraft.client.GuiGuide;
import darkknight.jewelrycraft.item.ItemList;
import darkknight.jewelrycraft.util.JewelryNBT;
import darkknight.jewelrycraft.util.JewelrycraftUtil;
public class GuiTabRings extends GuiTab
{
public GuiTabRings(int id)
{
super("Rings", id);
}
public ItemStack getIcon()
{
ItemStack it = new ItemStack(ItemList.ring);
JewelryNBT.addMetal(it, new ItemStack(Item.ingotGold));
JewelryNBT.addJewel(it, new ItemStack(Item.enderPearl));
return it;
}
@Override
public void drawBackground(GuiGuide gui, int x, int y, int page)
{
ArrayList<String> text = new ArrayList<String>();
ItemStack item = new ItemStack(ItemList.ring);
int xPos = (page%2==0)?107:-35;
switch(page)
{
case 1:
if(del == 0) values++;
del++;
if(del >= 300) del = 0;
if(values > JewelrycraftUtil.metal.size() - 1) values = 0;
JewelryNBT.addMetal(item, JewelrycraftUtil.metal.get(values));
JewelryNBT.addJewel(item, new ItemStack(Item.enderPearl));
text.add("§2Jewel: §0Ender Pearl");
text.add("§2Modifier: §0None");
text.add("§2Ingot: §0Any");
text.add(" This ring allows you");
text.add("to teleport in any");
text.add("location from the same");
text.add("dimension. Simply right");
text.add("click once in a location");
text.add("to se the position. Then");
text.add("right click any time you");
text.add("want to teleport there.");
Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), item, text, 50f, 0, -10);
break;
default:;
}
}
@Override
public void drawForeground(GuiGuide gui, int x, int y, int page)
{
}
}
|