mirror of
https://github.com/GTNewHorizons/waila.git
synced 2026-11-15 09:34:53 +00:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
afb9549da9 | ||
|
|
0d749d80ae | ||
|
|
050fd992c6 | ||
|
|
3694992eb5 | ||
|
|
6f0301667d | ||
|
|
d2606bfc25 | ||
|
|
299ef5307e | ||
|
|
a750f76a5d | ||
|
|
cd587ee8ca | ||
|
|
987254caca | ||
|
|
ef5ff0c6ed | ||
|
|
e9947e3960 | ||
|
|
95bf99a24a | ||
|
|
be530da970 | ||
|
|
5d82ebf0d5 | ||
|
|
165cb1003c | ||
|
|
5388d1bea0 | ||
|
|
c40c032531 | ||
|
|
bf0bb6e0c7 | ||
|
|
42c35d2b69 | ||
|
|
e9b440616e | ||
|
|
d1b354f05e | ||
|
|
0742ef2422 | ||
|
|
8e45cb8064 | ||
|
|
6896998934 | ||
|
|
74a2805844 | ||
|
|
c95daee0e2 | ||
|
|
bb5cd6cbfa | ||
|
|
3dde25b1a4 | ||
|
|
66649fa9dd | ||
|
|
a87c29bb2f | ||
|
|
3a057e4aba | ||
|
|
b50df6af26 | ||
|
|
8e8fd7f2bd | ||
|
|
d9f209a1d4 | ||
|
|
5e6ccc5ff8 | ||
|
|
bbfcc3b3ad | ||
|
|
d4a7b62644 | ||
|
|
417a75a896 | ||
|
|
b551d54e5c | ||
|
|
16ca8f2917 | ||
|
|
e7f2cab192 | ||
|
|
40063f3799 | ||
|
|
326d2b519b | ||
|
|
a7668e321c | ||
|
|
79af54e8cf | ||
|
|
09f8bbe33e | ||
|
|
1908f39995 | ||
|
|
748fc3fffa | ||
|
|
250dc6ac2a | ||
|
|
b81d2d3709 | ||
|
|
a873131d2f | ||
|
|
b5689428e8 | ||
|
|
d6285e2932 | ||
|
|
eb348d10fc | ||
|
|
7eb3ddb50c | ||
|
|
fde934363c | ||
|
|
dce9809205 | ||
|
|
15bee287f3 | ||
|
|
f28ed4c274 | ||
|
|
fc3606b71c | ||
|
|
aeff9c1039 | ||
|
|
9fd13c9ca1 | ||
|
|
ac1cc77258 | ||
|
|
e6005e55af | ||
|
|
62ec48ba21 | ||
|
|
7ab8981dde | ||
|
|
f8202e8fa8 | ||
|
|
b18fb9df61 | ||
|
|
b4ca299115 | ||
|
|
b0104482bb | ||
|
|
ef9ee6441d | ||
|
|
4ad3e92fae | ||
|
|
098c88676e | ||
|
|
4b05b017f7 | ||
|
|
a92a5dde3c | ||
|
|
a6890c5824 | ||
|
|
e87d08a789 | ||
|
|
65d8ef8c63 | ||
|
|
878a00b16b | ||
|
|
984b26c7fd | ||
|
|
b2cc1e02d7 | ||
|
|
83c7ef6aa9 | ||
|
|
6fca3468e2 | ||
|
|
d134aba573 | ||
|
|
8f32c0c770 | ||
|
|
e0a5da865f | ||
|
|
69a62e6edf | ||
|
|
a6da4adc08 | ||
|
|
2d3768423f | ||
|
|
cb2491f3f3 | ||
|
|
9248b75a0c | ||
|
|
fc46634fcc | ||
|
|
9df8f252c0 | ||
|
|
a844fb4815 | ||
|
|
58266d3cd1 | ||
|
|
94a22bf6ca | ||
|
|
32a50e112b | ||
|
|
6dbcf366bd | ||
|
|
24efba751d | ||
|
|
e681b98231 | ||
|
|
30d88b4c45 | ||
|
|
9a13ff7898 | ||
|
|
91ac3a9e32 | ||
|
|
1036c7c0c0 | ||
|
|
c03d9183a8 | ||
|
|
5da91bea2d | ||
|
|
c2ceb365d9 | ||
|
|
4488c37149 | ||
|
|
3c3fcad888 | ||
|
|
391cfe8290 | ||
|
|
8c2ff2b56f | ||
|
|
d9a16ba7fa | ||
|
|
3b906f4de8 | ||
|
|
0496543d70 | ||
|
|
e9cc68d2b1 | ||
|
|
8a5dc45240 | ||
|
|
d23855b263 | ||
|
|
5601fcdf7b | ||
|
|
a87d3b9de7 | ||
|
|
67775bad84 | ||
|
|
3d004700fb | ||
|
|
b3b2024ce7 | ||
|
|
c1cfb94a0d | ||
|
|
029d141872 | ||
|
|
ed93c68fb9 | ||
|
|
4b8acb517e | ||
|
|
419308e2ac | ||
|
|
8dc890421d | ||
|
|
fe90900b55 | ||
|
|
1d9807e6d6 | ||
|
|
58931febc4 | ||
|
|
d72dfa5775 | ||
|
|
dbf49534da | ||
|
|
aad38c1eac | ||
|
|
c0727b2157 | ||
|
|
3085f7442a | ||
|
|
25cfff7354 | ||
|
|
13f49db4b7 | ||
|
|
117808a326 | ||
|
|
31ee058c87 | ||
|
|
4d8087fb4c | ||
|
|
cef91a3ef4 | ||
|
|
9da2402851 | ||
|
|
3eaffb5812 | ||
|
|
643d1bfad2 | ||
|
|
ad6fd7290a | ||
|
|
7e012ff6c6 | ||
|
|
b547b7ece6 | ||
|
|
022d792d01 | ||
|
|
c4f6b40ea5 | ||
|
|
709f750a2a | ||
|
|
281a8f26dd | ||
|
|
03b8097ccb | ||
|
|
6a2c137bce | ||
|
|
e9c43a71fa | ||
|
|
f7e0e24548 | ||
|
|
73c5383d59 | ||
|
|
4cbe727b81 | ||
|
|
00ea3d77cc | ||
|
|
bc424e1d01 | ||
|
|
3c048e9795 | ||
|
|
eeb3c7f48a | ||
|
|
ee1118ee4b | ||
|
|
636ae4203e | ||
|
|
5360475686 | ||
|
|
15f89627c6 | ||
|
|
e42914c721 | ||
|
|
394d9cd564 | ||
|
|
f648c41890 | ||
|
|
37498dc0b1 | ||
|
|
ed1a4d010d | ||
|
|
83ee66d8a6 | ||
|
|
c4dcdd926a | ||
|
|
3048dfe09a | ||
|
|
6acfa28ef7 | ||
|
|
bac71d0894 | ||
|
|
b2dabe7bed | ||
|
|
78a8f92b2f | ||
|
|
137db44e23 | ||
|
|
d744bdf25b | ||
|
|
1eb67afea6 | ||
|
|
396dbd734a | ||
|
|
fb00790fdc | ||
|
|
39124f153f | ||
|
|
acda2b4a85 | ||
|
|
5a82bb2a5c | ||
|
|
987d5556ef | ||
|
|
f754ab5fbe | ||
|
|
4ebbd2b3e9 | ||
|
|
6598e693f9 | ||
|
|
4970a268f4 | ||
|
|
a984e2e8bd | ||
|
|
71aba4006b | ||
|
|
da64a0a019 | ||
|
|
d687bb5383 | ||
|
|
37d07ab99f | ||
|
|
172e8ca659 | ||
|
|
243ca7db20 | ||
|
|
39a979ef62 | ||
|
|
73cf134212 | ||
|
|
ae641e642d | ||
|
|
58feff48f9 | ||
|
|
c77306ae4f | ||
|
|
0ce1661a7f | ||
|
|
95adb69f55 | ||
|
|
b52b110852 | ||
|
|
7f1cb7d710 | ||
|
|
94d0f4d681 | ||
|
|
5f168bb1bc | ||
|
|
d29ecd09ce | ||
|
|
1fd33e8d7c | ||
|
|
f43bfad3d8 | ||
|
|
953e255189 | ||
|
|
e953471d3e | ||
|
|
78c8c9a2ad | ||
|
|
db75285bc5 | ||
|
|
cbd8b81f90 | ||
|
|
f7d397211f | ||
|
|
0eb9f813f7 | ||
|
|
8387373850 | ||
|
|
fa6218a526 | ||
|
|
5dd15fd727 | ||
|
|
5206ab683e |
No files matched your search
@@ -1,4 +0,0 @@
|
||||
Waila-1.7.10
|
||||
============
|
||||
|
||||
A port of Prof. Mobius' Minecraft mod, Waila, to Minecraft 1.7.10. Unofficial.
|
||||
File renamed without changes.
@@ -1,148 +1,128 @@
|
||||
screen.button.waila=Waila
|
||||
screen.button.modules=Module
|
||||
screen.label.scale=Maße
|
||||
screen.label.dragtuto=Verschiebe das HUD, um seine Position zu ändern.
|
||||
|
||||
screen.button.default=Standard
|
||||
screen.button.cancel=Abbrechen
|
||||
screen.button.ok=Ok
|
||||
screen.button.yes=Ja
|
||||
screen.button.no=Nein
|
||||
screen.button.back=Zurück
|
||||
screen.button.hidden=Versteckt
|
||||
screen.button.visible=Sichtbar
|
||||
screen.button.maintained=Gewartet
|
||||
screen.button.toggled=Geschaltet
|
||||
|
||||
choice.showhidewaila=Zeige/Verstecke Waila
|
||||
choice.showhideidmeta=Zeige ID:Metadata
|
||||
choice.toggledmaintained=Geschaltet/Gewartet
|
||||
choice.showliquids=Flüssigkeiten
|
||||
choice.shifttoggledblock=Blöcke schleichend umschalten
|
||||
choice.shifttoggledents=Lebewesen schleichend umschalten
|
||||
screen.button.configureaspect=Konfiguriere Aspekt...
|
||||
|
||||
enchant.title.name=Name
|
||||
enchant.title.minlvl=Min lvl
|
||||
enchant.title.maxlvl=Max lvl
|
||||
enchant.title.weight=Gewicht
|
||||
enchant.label.enchantability=Verzauberbarkeit
|
||||
|
||||
waila.keybind.wailaconfig=[Waila] Config-Bildschirm
|
||||
waila.keybind.wailadisplay=[Waila] Zeigen/Verstecken
|
||||
waila.keybind.liquid=[Waila] Zeige Flüssigkeiten
|
||||
waila.keybind.recipe=[Waila] Zeige Rezept
|
||||
waila.keybind.usage=[Waila] Zeige Nutzung
|
||||
waila.keybind.testing=[Waila] Testen
|
||||
|
||||
client.msg.norecipe=Kein Rezept gefunden.
|
||||
client.msg.nousage=Keine Nutzung gefunden.
|
||||
|
||||
hud.msg.none=<Nichts>
|
||||
hud.msg.empty=<Leer>
|
||||
hud.msg.output=Output
|
||||
hud.msg.input=Input
|
||||
hud.msg.out=Out
|
||||
hud.msg.in=In
|
||||
hud.msg.power=Energie
|
||||
hud.msg.storage=Speicher
|
||||
hud.msg.stored=Gespeichert
|
||||
hud.msg.any=Jegliches
|
||||
hud.msg.mode=Modus
|
||||
hud.msg.maxpower=Max Energie
|
||||
hud.msg.trigger=Trigger
|
||||
hud.msg.maxio=Max IO
|
||||
|
||||
hud.msg.send=Senden
|
||||
hud.msg.recv=Empfangen
|
||||
hud.msg.item=Item
|
||||
hud.msg.fluid=Flüssigk.
|
||||
hud.msg.energ=Energie
|
||||
hud.msg.frequency=Frequenz
|
||||
|
||||
hud.msg.owner=Besitzer
|
||||
hud.msg.public=Öffentlich
|
||||
hud.msg.restricted=Eingeschränkt
|
||||
hud.msg.private=Privat
|
||||
|
||||
hud.msg.white=Weiß
|
||||
hud.msg.orange=Orange
|
||||
hud.msg.magenta=Magenta
|
||||
hud.msg.lblue=HBlau
|
||||
hud.msg.yellow=Gelb
|
||||
hud.msg.lime=HGrün
|
||||
hud.msg.pink=Pink
|
||||
hud.msg.gray=Grau
|
||||
hud.msg.lgray=HGrau
|
||||
hud.msg.cyan=Türkis
|
||||
hud.msg.purple=Violett
|
||||
hud.msg.blue=Blau
|
||||
hud.msg.brown=Braun
|
||||
hud.msg.green=Grün
|
||||
hud.msg.red=Rot
|
||||
hud.msg.black=Schwarz
|
||||
|
||||
hud.msg.growth=Wachstum
|
||||
hud.msg.mature=Erwachsen
|
||||
hud.msg.off=Aus
|
||||
hud.msg.on=An
|
||||
hud.msg.state=Status
|
||||
hud.msg.delay=Verzögerung
|
||||
hud.msg.comparator=Komparator
|
||||
hud.msg.substractor=Substraktor
|
||||
hud.msg.record=Platte
|
||||
|
||||
hud.msg.offers=Angebote
|
||||
hud.msg.demands=Bedarf
|
||||
|
||||
option.appeng.monitorcontent=Monitorinhalt
|
||||
option.bb.content=Fassinhalt
|
||||
option.bc.tankamount=Flüssigk.-Menge
|
||||
option.bc.tanktype=Flüssigk.-Typ
|
||||
option.enderstorage.colors=Farben
|
||||
option.ic2.inputeumach=Max EU-Input [Maschinen]
|
||||
option.ic2.inputeuother=Max EU-Input [Anderes]
|
||||
option.ic2.inputeu=Max EU-Input
|
||||
option.ic2.outputeu=Max EU-Output
|
||||
option.ic2.storage=Energie gespeichert
|
||||
option.ic2.consump=Zeige Verbrauch
|
||||
option.ic2.tradeomat=Zeige Tauschautomaten-Forderung
|
||||
option.thaumcraft.storedvis=Kondensatorspeicher
|
||||
option.thermalexpansion.energyhandler=Zeige RO-Speicher
|
||||
option.thermalexpansion.energycell=Zeige EZellen IN/OUT
|
||||
option.thermalexpansion.fluidtype=Zeige Flüssigk.-Typ
|
||||
option.thermalexpansion.fluidamount=Zeige Flüssigk.-Menge
|
||||
option.thermalexpansion.tankmode=Zeige Tankmodus
|
||||
option.thermalexpansion.tesssendrecv=Tesseraktmodus
|
||||
option.thermalexpansion.tessfreq=Tesseraktfrequenz
|
||||
option.thermalexpansion.owner=Zeige Besitzer
|
||||
option.thermalexpansion.conditemmode=Zeige Itemduktmodus
|
||||
option.vanilla.spawntype=Spawner-Typ
|
||||
option.vanilla.growthvalue=Wachstumswert
|
||||
option.vanilla.leverstate=Hebelstatus
|
||||
option.vanilla.repeater=Repeater-Verzögerung
|
||||
option.vanilla.comparator=Komparatormodus
|
||||
option.vanilla.redstone=Redstone-Stärke
|
||||
option.vanilla.jukebox=Musikbox-Platte
|
||||
option.vanilla.silverfish=Silberfisch verdecken
|
||||
option.etb.displaydata=Zeige Sockeldaten
|
||||
option.enderio.inout=Zeige Input/Output
|
||||
option.enderio.storage=Zeige gespeicherte MJ
|
||||
option.enderio.owner=Zeige Block-Besitzer
|
||||
option.enderio.channel=Zeige Hypercube-Kanal
|
||||
option.bcapi.storage=Zeige gespeicherte MJ
|
||||
option.bcapi.consump=Zeige maximale Energie
|
||||
option.bcapi.trigger=Zeige Startenergie
|
||||
option.pr.showio=Zeige Gatter IO
|
||||
option.pr.showdata=Zeige Gatterdaten
|
||||
option.extrautilities.fluidamount=Zeige Flüssigk.-Menge
|
||||
option.openblocks.fluidamount=Zeige Flüssigk.-Menge
|
||||
option.railcraft.fluidamount=Zeige Flüssigk.-Menge
|
||||
option.secretrooms.hide=Getarnte Blöcke verdecken
|
||||
option.carpenters.hide=Getarnte Blöcke verdecken
|
||||
option.stevescarts.showall=Zeige Daten
|
||||
option.stevescarts.colorblind=Farbenblind-Modus
|
||||
option.stevescarts.shifttoggle=Schleichend Umschalten
|
||||
option.general.showhp=Zeige Gesundheit von Lebewesen
|
||||
option.general.showcrop=Zeige Pflanzenwachstum
|
||||
option.thaumcraft.aspects=Zeige Aspekte
|
||||
screen.button.waila=Waila
|
||||
screen.button.modules=Module
|
||||
screen.label.scale=Maße
|
||||
screen.label.dragtuto=Verschiebe das HUD, um seine Position zu ändern.
|
||||
|
||||
screen.button.default=Standard
|
||||
screen.button.cancel=Abbrechen
|
||||
screen.button.ok=Ok
|
||||
screen.button.yes=Ja
|
||||
screen.button.no=Nein
|
||||
screen.button.back=Zurück
|
||||
screen.button.hidden=Versteckt
|
||||
screen.button.visible=Sichtbar
|
||||
screen.button.maintained=Gewartet
|
||||
screen.button.toggled=Geschaltet
|
||||
|
||||
choice.showhidewaila=Zeige/Verstecke Waila
|
||||
choice.showhideidmeta=Zeige ID:Metadata
|
||||
choice.toggledmaintained=Geschaltet/Gewartet
|
||||
choice.showliquids=Flüssigkeiten
|
||||
screen.button.configureaspect=Konfiguriere Aspekt...
|
||||
|
||||
enchant.title.name=Name
|
||||
enchant.title.minlvl=Min lvl
|
||||
enchant.title.maxlvl=Max lvl
|
||||
enchant.title.weight=Gewicht
|
||||
enchant.label.enchantability=Verzauberbarkeit
|
||||
|
||||
waila.keybind.wailaconfig=[Waila] Config-Bildschirm
|
||||
waila.keybind.wailadisplay=[Waila] Zeigen/Verstecken
|
||||
waila.keybind.liquid=[Waila] Zeige Flüssigkeiten
|
||||
waila.keybind.recipe=[Waila] Zeige Rezept
|
||||
waila.keybind.usage=[Waila] Zeige Nutzung
|
||||
waila.keybind.testing=[Waila] Testen
|
||||
|
||||
client.msg.norecipe=Kein Rezept gefunden.
|
||||
client.msg.nousage=Keine Nutzung gefunden.
|
||||
|
||||
hud.msg.none=<Nichts>
|
||||
hud.msg.empty=<Leer>
|
||||
hud.msg.output=Output
|
||||
hud.msg.input=Input
|
||||
hud.msg.out=Out
|
||||
hud.msg.in=In
|
||||
hud.msg.power=Energie
|
||||
hud.msg.storage=Gespeichert
|
||||
hud.msg.any=Jegliches
|
||||
hud.msg.mode=Modus
|
||||
hud.msg.maxpower=Max Energie
|
||||
hud.msg.trigger=Trigger
|
||||
hud.msg.maxio=Max IO
|
||||
|
||||
hud.msg.send=Senden
|
||||
hud.msg.recv=Empfangen
|
||||
hud.msg.item=Item
|
||||
hud.msg.fluid=Flüssigk.
|
||||
hud.msg.energ=Energie
|
||||
hud.msg.frequency=Frequenz
|
||||
|
||||
hud.msg.owner=Besitzer
|
||||
hud.msg.public=Öffentlich
|
||||
hud.msg.restricted=Eingeschränkt
|
||||
hud.msg.private=Privat
|
||||
|
||||
hud.msg.white=Weiß
|
||||
hud.msg.orange=Orange
|
||||
hud.msg.magenta=Magenta
|
||||
hud.msg.lblue=HBlau
|
||||
hud.msg.yellow=Gelb
|
||||
hud.msg.lime=HGrün
|
||||
hud.msg.pink=Pink
|
||||
hud.msg.gray=Grau
|
||||
hud.msg.lgray=HGrau
|
||||
hud.msg.cyan=Türkis
|
||||
hud.msg.purple=Violett
|
||||
hud.msg.blue=Blau
|
||||
hud.msg.brown=Braun
|
||||
hud.msg.green=Grün
|
||||
hud.msg.red=Rot
|
||||
hud.msg.black=Schwarz
|
||||
|
||||
hud.msg.growth=Wachstum
|
||||
hud.msg.mature=Erwachsen
|
||||
hud.msg.off=Aus
|
||||
hud.msg.on=An
|
||||
hud.msg.state=Status
|
||||
hud.msg.delay=Verzögerung
|
||||
hud.msg.comparator=Komparator
|
||||
hud.msg.substractor=Substraktor
|
||||
hud.msg.record=Platte
|
||||
|
||||
option.appeng.monitorcontent=Monitorinhalt
|
||||
option.bb.content=Fassinhalt
|
||||
option.bc.tankamount=Flüssigk.-Menge
|
||||
option.bc.tanktype=Flüssigk.-Typ
|
||||
option.enderstorage.colors=Farben
|
||||
option.ic2.inputeumach=Max EU-Input [Maschinen]
|
||||
option.ic2.inputeuother=Max EU-Input [Anderes]
|
||||
option.ic2.inputeu=Max EU-Input
|
||||
option.ic2.outputeu=Max EU-Output
|
||||
option.ic2.storage=Energie gespeichert
|
||||
option.thaumcraft.storedvis=Kondensatorspeicher
|
||||
option.thermalexpansion.energyhandler=Zeige RO-Speicher
|
||||
option.thermalexpansion.energycell=Zeige EZellen IN/OUT
|
||||
option.thermalexpansion.fluidtype=Zeige Flüssigk.-Typ
|
||||
option.thermalexpansion.fluidamount=Zeige Flüssigk.-Menge
|
||||
option.thermalexpansion.tankmode=Zeige Tankmodus
|
||||
option.thermalexpansion.tesssendrecv=Tesseraktmodus
|
||||
option.thermalexpansion.tessfreq=Tesseraktfrequenz
|
||||
option.thermalexpansion.owner=Zeige Besitzer
|
||||
option.thermalexpansion.conditemmode=Zeige Itemduktmodus
|
||||
option.vanilla.spawntype=Spawner-Typ
|
||||
option.vanilla.growthvalue=Wachstumswert
|
||||
option.vanilla.leverstate=Hebelstatus
|
||||
option.vanilla.repeater=Repeater-Verzögerung
|
||||
option.vanilla.comparator=Komparatormodus
|
||||
option.vanilla.redstone=Redstone-Stärke
|
||||
option.vanilla.jukebox=Musikbox-Platte
|
||||
option.etb.displaydata=Zeigel Sockeldaten
|
||||
option.enderio.inout=Zeige Input/Output
|
||||
option.enderio.storage=Zeige gespeicherte MJ
|
||||
option.enderio.owner=Zeige Block-Besitzer
|
||||
option.enderio.channel=Zeige Hypercube-Kanal
|
||||
option.bcapi.storage=Zeige gespeicherte MJ
|
||||
option.bcapi.consump=Zeige maximale Energie
|
||||
option.bcapi.trigger=Zeige Startenergie
|
||||
option.pr.showio=Zeige Gatter IO
|
||||
option.pr.showdata=Zeige Gatterdaten
|
||||
@@ -18,8 +18,6 @@ choice.showhidewaila=Show/Hide Waila
|
||||
choice.showhideidmeta=Show ID:Metadata
|
||||
choice.toggledmaintained=Toggled/Maintained
|
||||
choice.showliquids=Liquids
|
||||
choice.shifttoggledblock=Sneak toggle blocks
|
||||
choice.shifttoggledents=Sneak toggle entities
|
||||
screen.button.configureaspect=Configure aspect...
|
||||
|
||||
enchant.title.name=Name
|
||||
@@ -124,7 +122,6 @@ option.vanilla.repeater=Repeater delay
|
||||
option.vanilla.comparator=Comparator mode
|
||||
option.vanilla.redstone=Redstone power
|
||||
option.vanilla.jukebox=Jukebox disk
|
||||
option.vanilla.silverfish=Hide silverfish
|
||||
option.etb.displaydata=Show socket data
|
||||
option.enderio.inout=Show input/output
|
||||
option.enderio.storage=Show stored MJ
|
||||
@@ -135,14 +132,3 @@ option.bcapi.consump=Show maximum power
|
||||
option.bcapi.trigger=Show triggering energy
|
||||
option.pr.showio=Show gates IO
|
||||
option.pr.showdata=Show gates data
|
||||
option.extrautilities.fluidamount=Show fluid amount
|
||||
option.openblocks.fluidamount=Show fluid amount
|
||||
option.railcraft.fluidamount=Show fluid amount
|
||||
option.secretrooms.hide=Hide camo blocks
|
||||
option.carpenters.hide=Hide camo blocks
|
||||
option.stevescarts.showall=Show data
|
||||
option.stevescarts.colorblind=Colorblind mode
|
||||
option.stevescarts.shifttoggle=Shift toggle
|
||||
option.general.showhp=Show entities health
|
||||
option.general.showcrop=Show crop growth
|
||||
option.thaumcraft.aspects=Show aspects
|
||||
@@ -130,7 +130,4 @@ option.bcapi.storage=Afficher MJ stocké
|
||||
option.bcapi.consump=Afficher puissance maximale
|
||||
option.bcapi.trigger=Energie déclanchement
|
||||
option.pr.showio=Afficher plaques IO
|
||||
option.pr.showdata=Afficher plaques data
|
||||
option.extrautilities.fluidamount=Afficher niveau fluides
|
||||
option.openblocks.fluidamount=Afficher niveau fluides
|
||||
option.railcraft.fluidamount=Afficher niveau fluides
|
||||
option.pr.showdata=Afficher plaques data
|
||||
@@ -1,117 +1,114 @@
|
||||
screen.button.waila=Waila
|
||||
screen.button.modules=Modules
|
||||
screen.label.scale=Schaal
|
||||
screen.label.dragtuto=Sleep de HUD om zijn positie in te stellen.
|
||||
|
||||
screen.button.default=Standaard
|
||||
screen.button.cancel=Annuleren
|
||||
screen.button.ok=Ok
|
||||
screen.button.yes=Ja
|
||||
screen.button.no=Nee
|
||||
screen.button.back=Terug
|
||||
screen.button.hidden=Verborgen
|
||||
screen.button.visible=Zichtbaar
|
||||
screen.button.maintained=Gehandhaafd
|
||||
screen.button.toggled=Omgeschakeld
|
||||
|
||||
choice.showhidewaila=Toon/Verberg Waila
|
||||
choice.showhideidmeta=Toon ID:Metadata
|
||||
choice.toggledmaintained=Omgeschakeld/Gehandhaafd
|
||||
choice.showliquids=Vloeistoffen
|
||||
screen.button.configureaspect=Configureer aspect...
|
||||
|
||||
enchant.title.name=Naam
|
||||
enchant.title.minlvl=Min lvl
|
||||
enchant.title.maxlvl=Max lvl
|
||||
enchant.title.weight=Gewicht
|
||||
enchant.label.enchantability=Enchantbaarheid
|
||||
|
||||
keybind.configscreen=[Waila] Configuratiescherm
|
||||
keybind.showhide=[Waila] Toon/Verberg
|
||||
keybind.showliquid=[Waila] Toon vloeistoffen
|
||||
keybind.showrecipe=[Waila] Toon recepten
|
||||
keybind.showusage=[Waila] Toon gebruik
|
||||
keybind.testing=[Waila] Testen
|
||||
|
||||
client.msg.norecipe=Geen recept gevonden.
|
||||
client.msg.nousage=Geen gebruik gevonden.
|
||||
|
||||
hud.msg.none=<Geen>
|
||||
hud.msg.empty=<Leeg>
|
||||
hud.msg.output=Uitvoer
|
||||
hud.msg.input=Invoer
|
||||
hud.msg.out=Uit
|
||||
hud.msg.in=In
|
||||
hud.msg.power=Vermogen
|
||||
hud.msg.storage=Opslag
|
||||
hud.msg.any=Om het even welke
|
||||
hud.msg.mode=Modus
|
||||
|
||||
hud.msg.send=Zend
|
||||
hud.msg.recv=Ontv
|
||||
hud.msg.item=Item
|
||||
hud.msg.fluid=Vloeistof
|
||||
hud.msg.energ=Energie
|
||||
hud.msg.frequency=Frequentie
|
||||
|
||||
hud.msg.owner=Eigenaar
|
||||
hud.msg.public=Publiek
|
||||
hud.msg.restricted=Begrensd
|
||||
hud.msg.private=Privé
|
||||
|
||||
hud.msg.white=Wit
|
||||
hud.msg.orange=Oranje
|
||||
hud.msg.magenta=Magenta
|
||||
hud.msg.lblue=LBlauw
|
||||
hud.msg.yellow=Geel
|
||||
hud.msg.lime=Limoen
|
||||
hud.msg.pink=Roze
|
||||
hud.msg.gray=Grijs
|
||||
hud.msg.lgray=LGrijs
|
||||
hud.msg.cyan=Cyaan
|
||||
hud.msg.purple=Paars
|
||||
hud.msg.blue=Blauw
|
||||
hud.msg.brown=Bruin
|
||||
hud.msg.green=Groen
|
||||
hud.msg.red=Rood
|
||||
hud.msg.black=Zwart
|
||||
|
||||
hud.msg.growth=Groei
|
||||
hud.msg.mature=Volwassen
|
||||
hud.msg.off=Af
|
||||
hud.msg.on=Aan
|
||||
hud.msg.state=Status
|
||||
hud.msg.delay=Vertraging
|
||||
hud.msg.comparator=Vergelijker
|
||||
hud.msg.substractor=Aftrekker
|
||||
hud.msg.record=Neem op
|
||||
|
||||
option.appeng.monitorcontent=Scherm inhoud
|
||||
option.bb.content=Ton inhoud
|
||||
option.bc.tankamount=Vloeistofhoeveelheid
|
||||
option.bc.tanktype=Vloeistoftype
|
||||
option.enderstorage.colors=Kleuren
|
||||
option.ic2.inputeumach=Max EU invoer [Machines]
|
||||
option.ic2.inputeuother=Max EU invoer [Andere]
|
||||
option.ic2.inputeu=Max EU invoer
|
||||
option.ic2.outputeu=Max EU uitvoer
|
||||
option.ic2.storage=Opgeslagen energie
|
||||
option.thaumcraft.storedvis=Condensator opslag
|
||||
option.thermalexpansion.energyhandler=Toon RF opslag
|
||||
option.thermalexpansion.energycell=Toon ECell IN/UIT
|
||||
option.thermalexpansion.fluidtype=Toon vloeistoftype
|
||||
option.thermalexpansion.fluidamount=Toon vloeistofhoeveelheid
|
||||
option.thermalexpansion.tankmode=Toon tank modus
|
||||
option.thermalexpansion.tesssendrecv=Tesseract modus
|
||||
option.thermalexpansion.tessfreq=Tesseract frequentie
|
||||
option.thermalexpansion.owner=Toon eigenaar
|
||||
option.vanilla.spawntype=Spawner type
|
||||
option.vanilla.growthvalue=Groei hoeveelheid
|
||||
option.vanilla.leverstate=Hendel status
|
||||
option.vanilla.repeater=Herhaler vertraging
|
||||
option.vanilla.comparator=Vergelijker modus
|
||||
option.vanilla.redstone=Redstone vermogen
|
||||
option.vanilla.jukebox=Jukebox schijf
|
||||
option.extrautilities.fluidamount=Toon vloeistofhoeveelheid
|
||||
option.openblocks.fluidamount=Toon vloeistofhoeveelheid
|
||||
option.railcraft.fluidamount=Toon vloeistofhoeveelheid
|
||||
screen.button.waila=Waila
|
||||
screen.button.modules=Modules
|
||||
screen.label.scale=Schaal
|
||||
screen.label.dragtuto=Sleep de HUD om zijn positie in te stellen.
|
||||
|
||||
screen.button.default=Standaard
|
||||
screen.button.cancel=Annuleren
|
||||
screen.button.ok=Ok
|
||||
screen.button.yes=Ja
|
||||
screen.button.no=Nee
|
||||
screen.button.back=Terug
|
||||
screen.button.hidden=Verborgen
|
||||
screen.button.visible=Zichtbaar
|
||||
screen.button.maintained=Gehandhaafd
|
||||
screen.button.toggled=Omgeschakeld
|
||||
|
||||
choice.showhidewaila=Toon/Verberg Waila
|
||||
choice.showhideidmeta=Toon ID:Metadata
|
||||
choice.toggledmaintained=Omgeschakeld/Gehandhaafd
|
||||
choice.showliquids=Vloeistoffen
|
||||
screen.button.configureaspect=Configureer aspect...
|
||||
|
||||
enchant.title.name=Naam
|
||||
enchant.title.minlvl=Min lvl
|
||||
enchant.title.maxlvl=Max lvl
|
||||
enchant.title.weight=Gewicht
|
||||
enchant.label.enchantability=Enchantbaarheid
|
||||
|
||||
keybind.configscreen=[Waila] Configuratiescherm
|
||||
keybind.showhide=[Waila] Toon/Verberg
|
||||
keybind.showliquid=[Waila] Toon vloeistoffen
|
||||
keybind.showrecipe=[Waila] Toon recepten
|
||||
keybind.showusage=[Waila] Toon gebruik
|
||||
keybind.testing=[Waila] Testen
|
||||
|
||||
client.msg.norecipe=Geen recept gevonden.
|
||||
client.msg.nousage=Geen gebruik gevonden.
|
||||
|
||||
hud.msg.none=<Geen>
|
||||
hud.msg.empty=<Leeg>
|
||||
hud.msg.output=Uitvoer
|
||||
hud.msg.input=Invoer
|
||||
hud.msg.out=Uit
|
||||
hud.msg.in=In
|
||||
hud.msg.power=Vermogen
|
||||
hud.msg.storage=Opslag
|
||||
hud.msg.any=Om het even welke
|
||||
hud.msg.mode=Modus
|
||||
|
||||
hud.msg.send=Zend
|
||||
hud.msg.recv=Ontv
|
||||
hud.msg.item=Item
|
||||
hud.msg.fluid=Vloeistof
|
||||
hud.msg.energ=Energie
|
||||
hud.msg.frequency=Frequentie
|
||||
|
||||
hud.msg.owner=Eigenaar
|
||||
hud.msg.public=Publiek
|
||||
hud.msg.restricted=Begrensd
|
||||
hud.msg.private=Privé
|
||||
|
||||
hud.msg.white=Wit
|
||||
hud.msg.orange=Oranje
|
||||
hud.msg.magenta=Magenta
|
||||
hud.msg.lblue=LBlauw
|
||||
hud.msg.yellow=Geel
|
||||
hud.msg.lime=Limoen
|
||||
hud.msg.pink=Roze
|
||||
hud.msg.gray=Grijs
|
||||
hud.msg.lgray=LGrijs
|
||||
hud.msg.cyan=Cyaan
|
||||
hud.msg.purple=Paars
|
||||
hud.msg.blue=Blauw
|
||||
hud.msg.brown=Bruin
|
||||
hud.msg.green=Groen
|
||||
hud.msg.red=Rood
|
||||
hud.msg.black=Zwart
|
||||
|
||||
hud.msg.growth=Groei
|
||||
hud.msg.mature=Volwassen
|
||||
hud.msg.off=Af
|
||||
hud.msg.on=Aan
|
||||
hud.msg.state=Status
|
||||
hud.msg.delay=Vertraging
|
||||
hud.msg.comparator=Vergelijker
|
||||
hud.msg.substractor=Aftrekker
|
||||
hud.msg.record=Neem op
|
||||
|
||||
option.appeng.monitorcontent=Scherm inhoud
|
||||
option.bb.content=Ton inhoud
|
||||
option.bc.tankamount=Vloeistofhoeveelheid
|
||||
option.bc.tanktype=Vloeistoftype
|
||||
option.enderstorage.colors=Kleuren
|
||||
option.ic2.inputeumach=Max EU invoer [Machines]
|
||||
option.ic2.inputeuother=Max EU invoer [Andere]
|
||||
option.ic2.inputeu=Max EU invoer
|
||||
option.ic2.outputeu=Max EU uitvoer
|
||||
option.ic2.storage=Opgeslagen energie
|
||||
option.thaumcraft.storedvis=Condensator opslag
|
||||
option.thermalexpansion.energyhandler=Toon RF opslag
|
||||
option.thermalexpansion.energycell=Toon ECell IN/UIT
|
||||
option.thermalexpansion.fluidtype=Toon vloeistoftype
|
||||
option.thermalexpansion.fluidamount=Toon vloeistofhoeveelheid
|
||||
option.thermalexpansion.tankmode=Toon tank modus
|
||||
option.thermalexpansion.tesssendrecv=Tesseract modus
|
||||
option.thermalexpansion.tessfreq=Tesseract frequentie
|
||||
option.thermalexpansion.owner=Toon eigenaar
|
||||
option.vanilla.spawntype=Spawner type
|
||||
option.vanilla.growthvalue=Groei hoeveelheid
|
||||
option.vanilla.leverstate=Hendel status
|
||||
option.vanilla.repeater=Herhaler vertraging
|
||||
option.vanilla.comparator=Vergelijker modus
|
||||
option.vanilla.redstone=Redstone vermogen
|
||||
option.vanilla.jukebox=Jukebox schijf
|
||||
File renamed without changes.
|
Before Width: | Height: | Size: 5.0 KiB After Width: | Height: | Size: 5.0 KiB |
File renamed without changes.
|
Before Width: | Height: | Size: 82 KiB After Width: | Height: | Size: 82 KiB |
File renamed without changes.
|
Before Width: | Height: | Size: 82 KiB After Width: | Height: | Size: 82 KiB |
-135
@@ -1,135 +0,0 @@
|
||||
buildscript {
|
||||
repositories {
|
||||
mavenCentral()
|
||||
maven {
|
||||
name = "forge"
|
||||
url = "http://files.minecraftforge.net/maven"
|
||||
}
|
||||
maven {
|
||||
name = "sonatype"
|
||||
url = "https://oss.sonatype.org/content/repositories/snapshots/"
|
||||
}
|
||||
}
|
||||
dependencies {
|
||||
classpath 'net.minecraftforge.gradle:ForgeGradle:1.2-SNAPSHOT'
|
||||
}
|
||||
}
|
||||
|
||||
configurations {
|
||||
deployerJars
|
||||
}
|
||||
|
||||
//add dependency repositories
|
||||
repositories {
|
||||
mavenLocal()
|
||||
mavenCentral()
|
||||
maven {
|
||||
name = "chickenbones"
|
||||
url = "http://chickenbones.net/maven/"
|
||||
}
|
||||
}
|
||||
|
||||
apply plugin: 'java'
|
||||
apply plugin: 'forge'
|
||||
apply plugin: 'maven'
|
||||
|
||||
version = "1.5.2a"
|
||||
group= "mcp.mobius.waila" // http://maven.apache.org/guides/mini/guide-naming-conventions.html
|
||||
archivesBaseName = "Waila"
|
||||
|
||||
// Define properties file
|
||||
ext.configFile = file "build.properties"
|
||||
|
||||
configFile.withReader {
|
||||
// Load config. It shall from now be referenced as simply config or project.config
|
||||
def prop = new Properties()
|
||||
prop.load(it)
|
||||
project.ext.config = new ConfigSlurper().parse prop
|
||||
}
|
||||
|
||||
dependencies {
|
||||
compile "codechicken:CodeChickenLib:${config.mc_version}-${config.ccl_version}:dev"
|
||||
compile "codechicken:CodeChickenCore:${config.mc_version}-${config.ccc_version}:dev"
|
||||
compile "codechicken:NotEnoughItems:${config.mc_version}-${config.nei_version}:dev"
|
||||
deployerJars "org.apache.maven.wagon:wagon-ssh:2.2"
|
||||
}
|
||||
|
||||
minecraft {
|
||||
version = "1.7.10-10.13.0.1160"
|
||||
assetDir = "eclipse/assets"
|
||||
}
|
||||
|
||||
def root = project.projectDir.parentFile
|
||||
sourceSets {
|
||||
main {
|
||||
java {
|
||||
srcDir new File(root, "src")
|
||||
}
|
||||
resources {
|
||||
srcDir new File(root, "resources")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
processResources
|
||||
{
|
||||
// this will ensure that this task is redone when the versions change.
|
||||
inputs.property "version", project.version
|
||||
inputs.property "mcversion", project.minecraft.version
|
||||
|
||||
// replace stuff in mcmod.info, nothing else
|
||||
from(sourceSets.main.resources.srcDirs) {
|
||||
include 'mcmod.info'
|
||||
|
||||
// replace version and mcversion
|
||||
expand 'version':project.version, 'mcversion':project.minecraft.version
|
||||
}
|
||||
|
||||
// copy everything else, thats not the mcmod.info
|
||||
from(sourceSets.main.resources.srcDirs) {
|
||||
exclude 'mcmod.info'
|
||||
}
|
||||
}
|
||||
|
||||
jar {
|
||||
exclude "**/client/gui/inventory/GuiContainer.class"
|
||||
exclude "**/client/gui/inventory/GuiContainer.java"
|
||||
}
|
||||
|
||||
task sourceJar(type: Jar) {
|
||||
from sourceSets.main.java
|
||||
from new File(root, "dev")
|
||||
classifier = 'sources'
|
||||
}
|
||||
|
||||
task devJar(type: Jar) {
|
||||
from sourceSets.main.output
|
||||
classifier = 'dev'
|
||||
}
|
||||
|
||||
artifacts {
|
||||
archives sourceJar, devJar
|
||||
}
|
||||
|
||||
uploadArchives {
|
||||
dependsOn 'reobf'
|
||||
repositories.mavenDeployer {
|
||||
configuration = configurations.deployerJars
|
||||
repository(url: "scp://mobiusstrip.eu/home/mobius/web/maven"){
|
||||
authentication(userName: "mobius")
|
||||
}
|
||||
|
||||
pom {
|
||||
groupId = project.group
|
||||
version = project.version
|
||||
artifactId = project.archivesBaseName
|
||||
project {
|
||||
name project.archivesBaseName
|
||||
packaging 'jar'
|
||||
description 'Waila '
|
||||
url 'http://mobiusstrip.eu'
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,7 +0,0 @@
|
||||
mc_version=1.7.10
|
||||
forge_version=10.13.0.1160
|
||||
ccl_version=1.1.1.93
|
||||
ccc_version=1.0.1.8
|
||||
nei_version=1.0.2.15
|
||||
mod_version=1.0
|
||||
waila_version=1.5.2a
|
||||
Vendored
BIN
Binary file not shown.
-6
@@ -1,6 +0,0 @@
|
||||
#Tue May 06 21:57:37 CEST 2014
|
||||
distributionBase=GRADLE_USER_HOME
|
||||
distributionPath=wrapper/dists
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
zipStorePath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-1.12-bin.zip
|
||||
@@ -1,164 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
##############################################################################
|
||||
##
|
||||
## Gradle start up script for UN*X
|
||||
##
|
||||
##############################################################################
|
||||
|
||||
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
|
||||
DEFAULT_JVM_OPTS=""
|
||||
|
||||
APP_NAME="Gradle"
|
||||
APP_BASE_NAME=`basename "$0"`
|
||||
|
||||
# Use the maximum available, or set MAX_FD != -1 to use that value.
|
||||
MAX_FD="maximum"
|
||||
|
||||
warn ( ) {
|
||||
echo "$*"
|
||||
}
|
||||
|
||||
die ( ) {
|
||||
echo
|
||||
echo "$*"
|
||||
echo
|
||||
exit 1
|
||||
}
|
||||
|
||||
# OS specific support (must be 'true' or 'false').
|
||||
cygwin=false
|
||||
msys=false
|
||||
darwin=false
|
||||
case "`uname`" in
|
||||
CYGWIN* )
|
||||
cygwin=true
|
||||
;;
|
||||
Darwin* )
|
||||
darwin=true
|
||||
;;
|
||||
MINGW* )
|
||||
msys=true
|
||||
;;
|
||||
esac
|
||||
|
||||
# For Cygwin, ensure paths are in UNIX format before anything is touched.
|
||||
if $cygwin ; then
|
||||
[ -n "$JAVA_HOME" ] && JAVA_HOME=`cygpath --unix "$JAVA_HOME"`
|
||||
fi
|
||||
|
||||
# Attempt to set APP_HOME
|
||||
# Resolve links: $0 may be a link
|
||||
PRG="$0"
|
||||
# Need this for relative symlinks.
|
||||
while [ -h "$PRG" ] ; do
|
||||
ls=`ls -ld "$PRG"`
|
||||
link=`expr "$ls" : '.*-> \(.*\)$'`
|
||||
if expr "$link" : '/.*' > /dev/null; then
|
||||
PRG="$link"
|
||||
else
|
||||
PRG=`dirname "$PRG"`"/$link"
|
||||
fi
|
||||
done
|
||||
SAVED="`pwd`"
|
||||
cd "`dirname \"$PRG\"`/" >&-
|
||||
APP_HOME="`pwd -P`"
|
||||
cd "$SAVED" >&-
|
||||
|
||||
CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
|
||||
|
||||
# Determine the Java command to use to start the JVM.
|
||||
if [ -n "$JAVA_HOME" ] ; then
|
||||
if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
|
||||
# IBM's JDK on AIX uses strange locations for the executables
|
||||
JAVACMD="$JAVA_HOME/jre/sh/java"
|
||||
else
|
||||
JAVACMD="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
if [ ! -x "$JAVACMD" ] ; then
|
||||
die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
|
||||
|
||||
Please set the JAVA_HOME variable in your environment to match the
|
||||
location of your Java installation."
|
||||
fi
|
||||
else
|
||||
JAVACMD="java"
|
||||
which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
|
||||
|
||||
Please set the JAVA_HOME variable in your environment to match the
|
||||
location of your Java installation."
|
||||
fi
|
||||
|
||||
# Increase the maximum file descriptors if we can.
|
||||
if [ "$cygwin" = "false" -a "$darwin" = "false" ] ; then
|
||||
MAX_FD_LIMIT=`ulimit -H -n`
|
||||
if [ $? -eq 0 ] ; then
|
||||
if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
|
||||
MAX_FD="$MAX_FD_LIMIT"
|
||||
fi
|
||||
ulimit -n $MAX_FD
|
||||
if [ $? -ne 0 ] ; then
|
||||
warn "Could not set maximum file descriptor limit: $MAX_FD"
|
||||
fi
|
||||
else
|
||||
warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
|
||||
fi
|
||||
fi
|
||||
|
||||
# For Darwin, add options to specify how the application appears in the dock
|
||||
if $darwin; then
|
||||
GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
|
||||
fi
|
||||
|
||||
# For Cygwin, switch paths to Windows format before running java
|
||||
if $cygwin ; then
|
||||
APP_HOME=`cygpath --path --mixed "$APP_HOME"`
|
||||
CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
|
||||
|
||||
# We build the pattern for arguments to be converted via cygpath
|
||||
ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
|
||||
SEP=""
|
||||
for dir in $ROOTDIRSRAW ; do
|
||||
ROOTDIRS="$ROOTDIRS$SEP$dir"
|
||||
SEP="|"
|
||||
done
|
||||
OURCYGPATTERN="(^($ROOTDIRS))"
|
||||
# Add a user-defined pattern to the cygpath arguments
|
||||
if [ "$GRADLE_CYGPATTERN" != "" ] ; then
|
||||
OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
|
||||
fi
|
||||
# Now convert the arguments - kludge to limit ourselves to /bin/sh
|
||||
i=0
|
||||
for arg in "$@" ; do
|
||||
CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
|
||||
CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option
|
||||
|
||||
if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition
|
||||
eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
|
||||
else
|
||||
eval `echo args$i`="\"$arg\""
|
||||
fi
|
||||
i=$((i+1))
|
||||
done
|
||||
case $i in
|
||||
(0) set -- ;;
|
||||
(1) set -- "$args0" ;;
|
||||
(2) set -- "$args0" "$args1" ;;
|
||||
(3) set -- "$args0" "$args1" "$args2" ;;
|
||||
(4) set -- "$args0" "$args1" "$args2" "$args3" ;;
|
||||
(5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
|
||||
(6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
|
||||
(7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
|
||||
(8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
|
||||
(9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
|
||||
esac
|
||||
fi
|
||||
|
||||
# Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules
|
||||
function splitJvmOpts() {
|
||||
JVM_OPTS=("$@")
|
||||
}
|
||||
eval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS
|
||||
JVM_OPTS[${#JVM_OPTS[*]}]="-Dorg.gradle.appname=$APP_BASE_NAME"
|
||||
|
||||
exec "$JAVACMD" "${JVM_OPTS[@]}" -classpath "$CLASSPATH" org.gradle.wrapper.GradleWrapperMain "$@"
|
||||
Vendored
-90
@@ -1,90 +0,0 @@
|
||||
@if "%DEBUG%" == "" @echo off
|
||||
@rem ##########################################################################
|
||||
@rem
|
||||
@rem Gradle startup script for Windows
|
||||
@rem
|
||||
@rem ##########################################################################
|
||||
|
||||
@rem Set local scope for the variables with windows NT shell
|
||||
if "%OS%"=="Windows_NT" setlocal
|
||||
|
||||
@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
|
||||
set DEFAULT_JVM_OPTS=
|
||||
|
||||
set DIRNAME=%~dp0
|
||||
if "%DIRNAME%" == "" set DIRNAME=.
|
||||
set APP_BASE_NAME=%~n0
|
||||
set APP_HOME=%DIRNAME%
|
||||
|
||||
@rem Find java.exe
|
||||
if defined JAVA_HOME goto findJavaFromJavaHome
|
||||
|
||||
set JAVA_EXE=java.exe
|
||||
%JAVA_EXE% -version >NUL 2>&1
|
||||
if "%ERRORLEVEL%" == "0" goto init
|
||||
|
||||
echo.
|
||||
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
|
||||
echo.
|
||||
echo Please set the JAVA_HOME variable in your environment to match the
|
||||
echo location of your Java installation.
|
||||
|
||||
goto fail
|
||||
|
||||
:findJavaFromJavaHome
|
||||
set JAVA_HOME=%JAVA_HOME:"=%
|
||||
set JAVA_EXE=%JAVA_HOME%/bin/java.exe
|
||||
|
||||
if exist "%JAVA_EXE%" goto init
|
||||
|
||||
echo.
|
||||
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
|
||||
echo.
|
||||
echo Please set the JAVA_HOME variable in your environment to match the
|
||||
echo location of your Java installation.
|
||||
|
||||
goto fail
|
||||
|
||||
:init
|
||||
@rem Get command-line arguments, handling Windowz variants
|
||||
|
||||
if not "%OS%" == "Windows_NT" goto win9xME_args
|
||||
if "%@eval[2+2]" == "4" goto 4NT_args
|
||||
|
||||
:win9xME_args
|
||||
@rem Slurp the command line arguments.
|
||||
set CMD_LINE_ARGS=
|
||||
set _SKIP=2
|
||||
|
||||
:win9xME_args_slurp
|
||||
if "x%~1" == "x" goto execute
|
||||
|
||||
set CMD_LINE_ARGS=%*
|
||||
goto execute
|
||||
|
||||
:4NT_args
|
||||
@rem Get arguments from the 4NT Shell from JP Software
|
||||
set CMD_LINE_ARGS=%$
|
||||
|
||||
:execute
|
||||
@rem Setup the command line
|
||||
|
||||
set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
|
||||
|
||||
@rem Execute Gradle
|
||||
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
|
||||
|
||||
:end
|
||||
@rem End local scope for the variables with windows NT shell
|
||||
if "%ERRORLEVEL%"=="0" goto mainEnd
|
||||
|
||||
:fail
|
||||
rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
|
||||
rem the _cmd.exe /c_ return code!
|
||||
if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
|
||||
exit /b 1
|
||||
|
||||
:mainEnd
|
||||
if "%OS%"=="Windows_NT" endlocal
|
||||
|
||||
:omega
|
||||
+3
-10
@@ -1,4 +1,4 @@
|
||||
package mcp.mobius.waila.utils;
|
||||
package mcp.mobius.waila;
|
||||
|
||||
public final class Constants {
|
||||
public static String BIND_SCREEN_WIKI = "showwiki";
|
||||
@@ -22,11 +22,8 @@ public final class Constants {
|
||||
public static String CFG_WAILA_KEYBIND = "waila.cfg.keybind";
|
||||
public static String CFG_WAILA_POSX = "waila.cfg.posx";
|
||||
public static String CFG_WAILA_POSY = "waila.cfg.posy";
|
||||
public static String CFG_WAILA_SCALE = "waila.cfg.scale";
|
||||
public static String CFG_WAILA_SHIFTBLOCK = "waila.cfg.shiftblock";
|
||||
public static String CFG_WAILA_SHIFTENTS = "waila.cfg.shiftents";
|
||||
public static String CFG_WAILA_NHEARTS = "waila.cfg.heartsperline";
|
||||
public static String CFG_WAILA_MAXHP = "waila.cfg.maxhpbeforetext";
|
||||
public static String CFG_WAILA_SCALE = "waila.cfg.scale";
|
||||
|
||||
|
||||
public static String CFG_WAILA_ALPHA = "waila.cfg.alpha";
|
||||
public static String CFG_WAILA_BGCOLOR = "waila.cfg.bgcolor";
|
||||
@@ -34,9 +31,5 @@ public final class Constants {
|
||||
public static String CFG_WAILA_GRADIENT2 = "waila.cfg.gradient2";
|
||||
public static String CFG_WAILA_FONTCOLOR = "waila.cfg.fontcolor";
|
||||
|
||||
public static String CATEGORY_MODULES = "modules";
|
||||
public static String CATEGORY_SERVER = "server_forcing";
|
||||
public static boolean SERVER_FREE = false;
|
||||
public static boolean SERVER_FORCED = true;
|
||||
|
||||
}
|
||||
+3
-5
@@ -1,11 +1,9 @@
|
||||
package mcp.mobius.waila.utils;
|
||||
package mcp.mobius.waila;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.logging.Level;
|
||||
|
||||
import mcp.mobius.waila.Waila;
|
||||
|
||||
public class WailaExceptionHandler {
|
||||
|
||||
public WailaExceptionHandler() {}
|
||||
@@ -17,11 +15,11 @@ public class WailaExceptionHandler {
|
||||
errs.add(className);
|
||||
|
||||
for (StackTraceElement elem : e.getStackTrace()){
|
||||
Waila.log.log(Level.WARNING, String.format("%s.%s:%s",elem.getClassName(), elem.getMethodName(), elem.getLineNumber()));
|
||||
mod_Waila.log.log(Level.WARNING, String.format("%s.%s:%s",elem.getClassName(), elem.getMethodName(), elem.getLineNumber()));
|
||||
if (elem.getClassName().contains("waila")) break;
|
||||
}
|
||||
|
||||
Waila.log.log(Level.WARNING, String.format("Catched unhandled exception : [%s] %s",className,e));
|
||||
mod_Waila.log.log(Level.WARNING, String.format("Catched unhandled exception : [%s] %s",className,e));
|
||||
}
|
||||
if (currenttip != null)
|
||||
currenttip.add("<ERROR>");
|
||||
@@ -0,0 +1,103 @@
|
||||
package mcp.mobius.waila.addons;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.LinkedHashMap;
|
||||
import java.util.Set;
|
||||
|
||||
import mcp.mobius.waila.mod_Waila;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import net.minecraftforge.common.Configuration;
|
||||
import net.minecraftforge.common.Property;
|
||||
|
||||
public class ConfigHandler implements IWailaConfigHandler {
|
||||
|
||||
private static ConfigHandler instance = null;
|
||||
private LinkedHashMap<String, ConfigModule> modules = new LinkedHashMap<String, ConfigModule>();
|
||||
private ArrayList<String> serverconfigs = new ArrayList<String>();
|
||||
|
||||
private ConfigHandler() {
|
||||
instance = this;
|
||||
}
|
||||
|
||||
public static ConfigHandler instance(){
|
||||
if (ConfigHandler.instance == null)
|
||||
ConfigHandler.instance = new ConfigHandler();
|
||||
return ConfigHandler.instance;
|
||||
}
|
||||
|
||||
public void addModule(String modName, HashMap<String, String> options){
|
||||
this.addModule(modName, new ConfigModule(modName, options));
|
||||
}
|
||||
|
||||
public void addModule(String modName, ConfigModule options){
|
||||
this.modules.put(modName, options);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Set<String> getModuleNames(){
|
||||
return this.modules.keySet();
|
||||
}
|
||||
|
||||
@Override
|
||||
public HashMap<String, String> getConfigKeys(String modName){
|
||||
if (this.modules.containsKey(modName))
|
||||
return this.modules.get(modName).options;
|
||||
else
|
||||
return null;
|
||||
}
|
||||
|
||||
public void addConfig(String modName, String key, String name){
|
||||
if (!this.modules.containsKey(modName))
|
||||
this.modules.put(modName, new ConfigModule(modName));
|
||||
|
||||
this.modules.get(modName).addOption(key, name);
|
||||
}
|
||||
|
||||
public void addConfigServer(String modName, String key, String name){
|
||||
if (!this.modules.containsKey(modName))
|
||||
this.modules.put(modName, new ConfigModule(modName));
|
||||
|
||||
this.modules.get(modName).addOption(key, name);
|
||||
this.serverconfigs.add(key);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean getConfig(String key, boolean defvalue){
|
||||
mod_Waila.instance.config.load();
|
||||
|
||||
if (this.serverconfigs.contains(key) && !mod_Waila.instance.serverPresent)
|
||||
return false;
|
||||
|
||||
Property prop = mod_Waila.instance.config.get(Configuration.CATEGORY_GENERAL, key, defvalue);
|
||||
return prop.getBoolean(defvalue);
|
||||
}
|
||||
|
||||
public boolean isServerRequired(String key){
|
||||
return this.serverconfigs.contains(key);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean getConfig(String key){
|
||||
return this.getConfig(key, true);
|
||||
}
|
||||
|
||||
public int getConfigInt(String key){
|
||||
mod_Waila.instance.config.load();
|
||||
Property prop = mod_Waila.instance.config.get(Configuration.CATEGORY_GENERAL, key, 0);
|
||||
return prop.getInt();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setConfig(String key, boolean value){
|
||||
mod_Waila.instance.config.load();
|
||||
mod_Waila.instance.config.get(Configuration.CATEGORY_GENERAL, key, true).set(value);;
|
||||
mod_Waila.instance.config.save();
|
||||
}
|
||||
|
||||
public void setConfigInt(String key, int value){
|
||||
mod_Waila.instance.config.load();
|
||||
mod_Waila.instance.config.get(Configuration.CATEGORY_GENERAL, key, 0).set(value);;
|
||||
mod_Waila.instance.config.save();
|
||||
}
|
||||
}
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
package mcp.mobius.waila.api.impl;
|
||||
package mcp.mobius.waila.addons;
|
||||
|
||||
import java.util.HashMap;
|
||||
|
||||
@@ -0,0 +1,397 @@
|
||||
package mcp.mobius.waila.addons;
|
||||
|
||||
import java.io.BufferedReader;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.io.InputStreamReader;
|
||||
import java.util.ArrayList;
|
||||
import java.util.LinkedHashMap;
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
import java.util.logging.Level;
|
||||
|
||||
import au.com.bytecode.opencsv.CSVReader;
|
||||
import net.minecraft.block.Block;
|
||||
import codechicken.lib.lang.LangUtil;
|
||||
import codechicken.nei.api.API;
|
||||
import mcp.mobius.waila.mod_Waila;
|
||||
import mcp.mobius.waila.api.IWailaBlockDecorator;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
import mcp.mobius.waila.api.IWailaRegistrar;
|
||||
import mcp.mobius.waila.api.IWailaSummaryProvider;
|
||||
import mcp.mobius.waila.handlers.hud.HUDHandlerExternal;
|
||||
|
||||
public class ExternalModulesHandler implements IWailaRegistrar {
|
||||
|
||||
private static ExternalModulesHandler instance = null;
|
||||
public LinkedHashMap<Integer, ArrayList<IWailaDataProvider>> headProviders = new LinkedHashMap<Integer, ArrayList<IWailaDataProvider>>();
|
||||
public LinkedHashMap<Integer, ArrayList<IWailaDataProvider>> bodyProviders = new LinkedHashMap<Integer, ArrayList<IWailaDataProvider>>();
|
||||
public LinkedHashMap<Integer, ArrayList<IWailaDataProvider>> tailProviders = new LinkedHashMap<Integer, ArrayList<IWailaDataProvider>>();
|
||||
public LinkedHashMap<Integer, ArrayList<IWailaDataProvider>> stackProviders = new LinkedHashMap<Integer, ArrayList<IWailaDataProvider>>();
|
||||
|
||||
public LinkedHashMap<Class, ArrayList<IWailaDataProvider>> headBlockProviders = new LinkedHashMap<Class, ArrayList<IWailaDataProvider>>();
|
||||
public LinkedHashMap<Class, ArrayList<IWailaDataProvider>> bodyBlockProviders = new LinkedHashMap<Class, ArrayList<IWailaDataProvider>>();
|
||||
public LinkedHashMap<Class, ArrayList<IWailaDataProvider>> tailBlockProviders = new LinkedHashMap<Class, ArrayList<IWailaDataProvider>>();
|
||||
public LinkedHashMap<Class, ArrayList<IWailaDataProvider>> stackBlockProviders = new LinkedHashMap<Class, ArrayList<IWailaDataProvider>>();
|
||||
|
||||
public LinkedHashMap<Integer, ArrayList<IWailaBlockDecorator>> blockIdDecorators = new LinkedHashMap<Integer, ArrayList<IWailaBlockDecorator>>();
|
||||
public LinkedHashMap<Class, ArrayList<IWailaBlockDecorator>> blockClassDecorators = new LinkedHashMap<Class, ArrayList<IWailaBlockDecorator>>();
|
||||
|
||||
public LinkedHashMap<String, LinkedHashMap <String, LinkedHashMap <String, String>>> wikiDescriptions = new LinkedHashMap<String, LinkedHashMap <String, LinkedHashMap <String, String>>>();
|
||||
|
||||
public LinkedHashMap<Class, ArrayList<IWailaSummaryProvider>> summaryProviders = new LinkedHashMap<Class, ArrayList<IWailaSummaryProvider>>();
|
||||
|
||||
private ExternalModulesHandler() {
|
||||
instance = this;
|
||||
}
|
||||
|
||||
public static ExternalModulesHandler instance(){
|
||||
if (ExternalModulesHandler.instance == null)
|
||||
ExternalModulesHandler.instance = new ExternalModulesHandler();
|
||||
return ExternalModulesHandler.instance;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addConfig(String modname, String key, String configname) {
|
||||
ConfigHandler.instance().addConfig(modname, key, LangUtil.translateG(configname));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addConfigRemote(String modname, String key, String configname) {
|
||||
ConfigHandler.instance().addConfigServer(modname, key, LangUtil.translateG(configname));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addConfig(String modname, String key) {
|
||||
ConfigHandler.instance().addConfig(modname, key, LangUtil.translateG("option." + key));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addConfigRemote(String modname, String key) {
|
||||
ConfigHandler.instance().addConfigServer(modname, key, LangUtil.translateG("option." + key));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void registerHeadProvider(IWailaDataProvider dataProvider, int blockID) {
|
||||
if (!this.headProviders.containsKey(blockID))
|
||||
this.headProviders.put(blockID, new ArrayList<IWailaDataProvider>());
|
||||
this.headProviders.get(blockID).add(dataProvider);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void registerHeadProvider(IWailaDataProvider dataProvider, Class block) {
|
||||
if (!this.headBlockProviders.containsKey(block))
|
||||
this.headBlockProviders.put(block, new ArrayList<IWailaDataProvider>());
|
||||
this.headBlockProviders.get(block).add(dataProvider);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void registerBodyProvider(IWailaDataProvider dataProvider, int blockID) {
|
||||
if (!this.bodyProviders.containsKey(blockID))
|
||||
this.bodyProviders.put(blockID, new ArrayList<IWailaDataProvider>());
|
||||
this.bodyProviders.get(blockID).add(dataProvider);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void registerBodyProvider(IWailaDataProvider dataProvider, Class block) {
|
||||
if (!this.bodyBlockProviders.containsKey(block))
|
||||
this.bodyBlockProviders.put(block, new ArrayList<IWailaDataProvider>());
|
||||
this.bodyBlockProviders.get(block).add(dataProvider);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void registerTailProvider(IWailaDataProvider dataProvider, int blockID) {
|
||||
if (!this.tailProviders.containsKey(blockID))
|
||||
this.tailProviders.put(blockID, new ArrayList<IWailaDataProvider>());
|
||||
this.tailProviders.get(blockID).add(dataProvider);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void registerTailProvider(IWailaDataProvider dataProvider, Class block) {
|
||||
if (!this.tailBlockProviders.containsKey(block))
|
||||
this.tailBlockProviders.put(block, new ArrayList<IWailaDataProvider>());
|
||||
this.tailBlockProviders.get(block).add(dataProvider);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void registerStackProvider(IWailaDataProvider dataProvider, int blockID) {
|
||||
if (!this.stackProviders.containsKey(blockID))
|
||||
this.stackProviders.put(blockID, new ArrayList<IWailaDataProvider>());
|
||||
this.stackProviders.get(blockID).add(dataProvider);
|
||||
API.registerHighlightIdentifier(blockID, new HUDHandlerExternal());
|
||||
}
|
||||
|
||||
@Override
|
||||
public void registerStackProvider(IWailaDataProvider dataProvider, Class block) {
|
||||
for (int i = 0; i < Block.blocksList.length; i++)
|
||||
if (block.isInstance(Block.blocksList[i])){
|
||||
this.registerStackProvider(dataProvider, i);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void registerShortDataProvider(IWailaSummaryProvider dataProvider, Class item) {
|
||||
if (!this.summaryProviders.containsKey(item))
|
||||
this.summaryProviders.put(item, new ArrayList<IWailaSummaryProvider>());
|
||||
this.summaryProviders.get(item).add(dataProvider);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void registerBlockDecorator(IWailaBlockDecorator decorator, int blockID) {
|
||||
if (!this.blockIdDecorators.containsKey(blockID))
|
||||
this.blockIdDecorators.put(blockID, new ArrayList<IWailaBlockDecorator>());
|
||||
this.blockIdDecorators.get(blockID).add(decorator);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void registerBlockDecorator(IWailaBlockDecorator decorator, Class block) {
|
||||
if (!this.blockClassDecorators.containsKey(block))
|
||||
this.blockClassDecorators.put(block, new ArrayList<IWailaBlockDecorator>());
|
||||
this.blockClassDecorators.get(block).add(decorator);
|
||||
}
|
||||
|
||||
/* Arrays getters */
|
||||
|
||||
public ArrayList<IWailaDataProvider> getHeadProviders(int blockID) {
|
||||
return this.headProviders.get(blockID);
|
||||
}
|
||||
|
||||
public ArrayList<IWailaDataProvider> getBodyProviders(int blockID) {
|
||||
return this.bodyProviders.get(blockID);
|
||||
}
|
||||
|
||||
public ArrayList<IWailaDataProvider> getTailProviders(int blockID) {
|
||||
return this.tailProviders.get(blockID);
|
||||
}
|
||||
|
||||
public ArrayList<IWailaDataProvider> getHeadProviders(Object block) {
|
||||
ArrayList<IWailaDataProvider> returnList = new ArrayList<IWailaDataProvider>();
|
||||
for (Class clazz : this.headBlockProviders.keySet())
|
||||
if (clazz.isInstance(block))
|
||||
returnList.addAll(this.headBlockProviders.get(clazz));
|
||||
|
||||
return returnList;
|
||||
}
|
||||
|
||||
public ArrayList<IWailaDataProvider> getBodyProviders(Object block) {
|
||||
ArrayList<IWailaDataProvider> returnList = new ArrayList<IWailaDataProvider>();
|
||||
for (Class clazz : this.bodyBlockProviders.keySet())
|
||||
if (clazz.isInstance(block))
|
||||
returnList.addAll(this.bodyBlockProviders.get(clazz));
|
||||
|
||||
return returnList;
|
||||
}
|
||||
|
||||
public ArrayList<IWailaDataProvider> getTailProviders(Object block) {
|
||||
ArrayList<IWailaDataProvider> returnList = new ArrayList<IWailaDataProvider>();
|
||||
for (Class clazz : this.bodyBlockProviders.keySet())
|
||||
if (clazz.isInstance(block))
|
||||
returnList.addAll(this.bodyBlockProviders.get(clazz));
|
||||
|
||||
return returnList;
|
||||
}
|
||||
|
||||
public ArrayList<IWailaDataProvider> getStackProviders(int blockID) {
|
||||
return this.stackProviders.get(blockID);
|
||||
}
|
||||
|
||||
public ArrayList<IWailaSummaryProvider> getSummaryProvider(Object item){
|
||||
ArrayList<IWailaSummaryProvider> returnList = new ArrayList<IWailaSummaryProvider>();
|
||||
for (Class clazz : this.summaryProviders.keySet())
|
||||
if (clazz.isInstance(item))
|
||||
returnList.addAll(this.summaryProviders.get(clazz));
|
||||
|
||||
return returnList;
|
||||
}
|
||||
|
||||
public ArrayList<IWailaBlockDecorator> getBlockDecorators(int blockID){
|
||||
return this.blockIdDecorators.get(blockID);
|
||||
}
|
||||
|
||||
public ArrayList<IWailaBlockDecorator> getBlockDecorators(Object block){
|
||||
ArrayList<IWailaBlockDecorator> returnList = new ArrayList<IWailaBlockDecorator>();
|
||||
for (Class clazz : this.blockClassDecorators.keySet())
|
||||
if (clazz.isInstance(block))
|
||||
returnList.addAll(this.blockClassDecorators.get(clazz));
|
||||
|
||||
return returnList;
|
||||
}
|
||||
|
||||
/* Providers querry methods */
|
||||
|
||||
public boolean hasHeadProviders(int blockID){
|
||||
return this.headProviders.containsKey(blockID);
|
||||
}
|
||||
|
||||
public boolean hasBodyProviders(int blockID){
|
||||
return this.bodyProviders.containsKey(blockID);
|
||||
}
|
||||
|
||||
public boolean hasTailProviders(int blockID){
|
||||
return this.tailProviders.containsKey(blockID);
|
||||
}
|
||||
|
||||
public boolean hasStackProviders(int blockID){
|
||||
return this.stackProviders.containsKey(blockID);
|
||||
}
|
||||
|
||||
public boolean hasHeadProviders(Object block){
|
||||
for (Class clazz : this.headBlockProviders.keySet())
|
||||
if (clazz.isInstance(block))
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
public boolean hasBodyProviders(Object block){
|
||||
for (Class clazz : this.bodyBlockProviders.keySet())
|
||||
if (clazz.isInstance(block))
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
public boolean hasTailProviders(Object block){
|
||||
for (Class clazz : this.tailBlockProviders.keySet())
|
||||
if (clazz.isInstance(block))
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
public boolean hasSummaryProvider(Class item){
|
||||
return this.summaryProviders.containsKey(item);
|
||||
}
|
||||
|
||||
public boolean hasBlockDecorator(int blockID){
|
||||
return this.blockIdDecorators.containsKey(blockID);
|
||||
}
|
||||
|
||||
public boolean hasBlockDecorator(Object block){
|
||||
for (Class clazz : this.blockClassDecorators.keySet())
|
||||
if (clazz.isInstance(block))
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
/* ----------------- */
|
||||
@Override
|
||||
public void registerDocTextFile(String filename) {
|
||||
List<String[]> docData = null;
|
||||
int nentries = 0;
|
||||
|
||||
|
||||
try{
|
||||
docData = this.readFileAsString(filename);
|
||||
} catch (IOException e){
|
||||
mod_Waila.log.log(Level.WARNING, String.format("Error while accessing file %s : %s", filename, e));
|
||||
return;
|
||||
}
|
||||
|
||||
for (String[] ss : docData){
|
||||
String modid = ss[0];
|
||||
String name = ss[1];
|
||||
String meta = ss[2];
|
||||
String desc = ss[5].replace('$', '\n');
|
||||
if (!(desc.trim().equals(""))){
|
||||
if (!this.wikiDescriptions.containsKey(modid))
|
||||
this.wikiDescriptions.put(modid, new LinkedHashMap <String, LinkedHashMap <String, String>>());
|
||||
if (!this.wikiDescriptions.get(modid).containsKey(name))
|
||||
this.wikiDescriptions.get(modid).put(name, new LinkedHashMap<String, String>());
|
||||
|
||||
this.wikiDescriptions.get(modid).get(name).put(meta, desc);
|
||||
System.out.printf("Registered %s %s %s\n", modid, name, meta);
|
||||
nentries += 1;
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
String[] sections = docData.split(">>>>");
|
||||
for (String s : sections){
|
||||
s.trim();
|
||||
if (!s.equals("")){
|
||||
try{
|
||||
String name = s.split("\r?\n",2)[0].trim();
|
||||
String desc = s.split("\r?\n",2)[1].trim();
|
||||
if (!this.wikiDescriptions.containsKey(modid))
|
||||
this.wikiDescriptions.put(modid, new LinkedHashMap <String, String>());
|
||||
this.wikiDescriptions.get(modid).put(name, desc);
|
||||
nentries += 1;
|
||||
}catch (Exception e){
|
||||
System.out.printf("%s\n", e);
|
||||
}
|
||||
}
|
||||
}
|
||||
*/
|
||||
mod_Waila.log.log(Level.INFO, String.format("Registered %s entries from %s", nentries, filename));
|
||||
}
|
||||
|
||||
public boolean hasDocTextModID(String modid){
|
||||
return this.wikiDescriptions.containsKey(modid);
|
||||
}
|
||||
|
||||
public boolean hasDocTextItem(String modid, String item){
|
||||
if (this.hasDocTextModID(modid))
|
||||
return this.wikiDescriptions.get(modid).containsKey(item);
|
||||
return false;
|
||||
}
|
||||
|
||||
public boolean hasDocTextMeta(String modid, String item, String meta){
|
||||
if (this.hasDocTextItem(modid, item))
|
||||
return this.wikiDescriptions.get(modid).get(item).containsKey(meta);
|
||||
return false;
|
||||
}
|
||||
|
||||
public LinkedHashMap<String, String> getDocText(String modid, String name){
|
||||
return this.wikiDescriptions.get(modid).get(name);
|
||||
}
|
||||
|
||||
public String getDocText(String modid, String name, String meta){
|
||||
return this.wikiDescriptions.get(modid).get(name).get(meta);
|
||||
}
|
||||
|
||||
public boolean hasDocTextSpecificMeta(String modid, String name, String meta){
|
||||
for (String s : this.getDocText(modid, name).keySet())
|
||||
if (s.equals(meta))
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
public String getDoxTextWildcardMatch(String modid, String name){
|
||||
Set<String> keys = this.wikiDescriptions.get(modid).keySet();
|
||||
for (String s : keys){
|
||||
String regexed = s;
|
||||
regexed = regexed.replace(".", "\\.");
|
||||
regexed = regexed.replace("*", ".*");
|
||||
|
||||
if (name.matches(s))
|
||||
return s;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
private List<String[]> readFileAsString(String filePath) throws IOException {
|
||||
// URL fileURL = this.getClass().getResource(filePath);
|
||||
// File filedata = new File(fileURL);
|
||||
// Reader paramReader = new InputStreamReader(this.getClass().getResourceAsStream(filePath));
|
||||
|
||||
InputStream in = getClass().getResourceAsStream(filePath);
|
||||
BufferedReader input = new BufferedReader(new InputStreamReader(in));
|
||||
CSVReader reader = new CSVReader(input);
|
||||
|
||||
List<String[]> myEntries = reader.readAll();
|
||||
reader.close();
|
||||
|
||||
return myEntries;
|
||||
/*
|
||||
StringBuffer fileData = new StringBuffer();
|
||||
//BufferedReader reader = new BufferedReader(paramReader);
|
||||
|
||||
char[] buf = new char[1024];
|
||||
int numRead=0;
|
||||
while((numRead=input.read(buf)) != -1){
|
||||
String readData = String.valueOf(buf, 0, numRead);
|
||||
fileData.append(readData);
|
||||
}
|
||||
input.close();
|
||||
return fileData.toString();
|
||||
*/
|
||||
}
|
||||
}
|
||||
+10
-9
@@ -4,8 +4,10 @@ import java.lang.reflect.Field;
|
||||
import java.lang.reflect.Method;
|
||||
import java.util.logging.Level;
|
||||
|
||||
import mcp.mobius.waila.Waila;
|
||||
import mcp.mobius.waila.api.impl.ModuleRegistrar;
|
||||
import codechicken.lib.lang.LangUtil;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import mcp.mobius.waila.mod_Waila;
|
||||
import mcp.mobius.waila.addons.ExternalModulesHandler;
|
||||
|
||||
public class AppEngModule {
|
||||
|
||||
@@ -24,19 +26,18 @@ public class AppEngModule {
|
||||
IAEItemStack_getItemStack = IAEItemStack.getMethod("getItemStack");
|
||||
|
||||
} catch (ClassNotFoundException e){
|
||||
Waila.log.log(Level.WARNING, "[AppEng] Class not found. " + e);
|
||||
mod_Waila.log.log(Level.WARNING, "[AppEng] Class not found. " + e);
|
||||
return;
|
||||
} catch (SecurityException e) {
|
||||
Waila.log.log(Level.WARNING, "[AppEng] Security Exception. " + e);
|
||||
mod_Waila.log.log(Level.WARNING, "[AppEng] Security Exception. " + e);
|
||||
return;
|
||||
} catch (NoSuchMethodException e) {
|
||||
Waila.log.log(Level.WARNING, "[AppEng] Method not found. " + e);
|
||||
mod_Waila.log.log(Level.WARNING, "[AppEng] Method not found. " + e);
|
||||
return;
|
||||
}
|
||||
|
||||
Waila.log.log(Level.INFO, "AppEng mod found.");
|
||||
ModuleRegistrar.instance().addConfig("Applied Energetic", "appeng.monitorcontent");
|
||||
ModuleRegistrar.instance().registerBodyProvider(new HUDAppEngMonitor(), TileStorageMonitor);
|
||||
ModuleRegistrar.instance().registerSyncedNBTKey("*", TileStorageMonitor);
|
||||
mod_Waila.log.log(Level.INFO, "AppEng mod found.");
|
||||
ExternalModulesHandler.instance().addConfig("Applied Energetic", "appeng.monitorcontent");
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDAppEngMonitor(), TileStorageMonitor);
|
||||
}
|
||||
}
|
||||
+1
-1
@@ -3,12 +3,12 @@ package mcp.mobius.waila.addons.appeng;
|
||||
import java.lang.reflect.InvocationTargetException;
|
||||
import java.util.List;
|
||||
|
||||
import codechicken.lib.lang.LangUtil;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
import mcp.mobius.waila.cbcore.LangUtil;
|
||||
|
||||
public class HUDAppEngMonitor implements IWailaDataProvider {
|
||||
|
||||
+9
-8
@@ -4,8 +4,9 @@ import java.lang.reflect.Field;
|
||||
import java.lang.reflect.Method;
|
||||
import java.util.logging.Level;
|
||||
|
||||
import mcp.mobius.waila.Waila;
|
||||
import mcp.mobius.waila.api.impl.ModuleRegistrar;
|
||||
import mcp.mobius.waila.mod_Waila;
|
||||
import mcp.mobius.waila.addons.ExternalModulesHandler;
|
||||
import codechicken.lib.lang.LangUtil;
|
||||
import codechicken.nei.api.API;
|
||||
import codechicken.nei.api.ItemInfo;
|
||||
|
||||
@@ -23,17 +24,17 @@ public class BetterBarrelsModule {
|
||||
IBarrelStorage_getItem = IBarrelStorage.getMethod("getItem");
|
||||
|
||||
} catch (ClassNotFoundException e){
|
||||
Waila.log.log(Level.WARNING, "[BB] BetterBarrel classes not found.");
|
||||
mod_Waila.log.log(Level.WARNING, "[BB] BetterBarrel classes not found.");
|
||||
} catch (NoSuchFieldException e){
|
||||
Waila.log.log(Level.WARNING, "[BB] Storage field not found.");
|
||||
mod_Waila.log.log(Level.WARNING, "[BB] Storage field not found.");
|
||||
} catch (NoSuchMethodException e){
|
||||
Waila.log.log(Level.WARNING, "[BB] getItem() not found.");
|
||||
mod_Waila.log.log(Level.WARNING, "[BB] getItem() not found.");
|
||||
}
|
||||
|
||||
if (IBarrelStorage_getItem != null){
|
||||
Waila.log.log(Level.INFO, "Waila module BetterBarrel succefully hooked.");
|
||||
ModuleRegistrar.instance().addConfig("BetterBarrels", "bb.content");
|
||||
ModuleRegistrar.instance().registerBodyProvider(new HUDHandlerBBContent(), TileEntityBarrel);
|
||||
mod_Waila.log.log(Level.INFO, "Waila module BetterBarrel succefully hooked.");
|
||||
ExternalModulesHandler.instance().addConfig("BetterBarrels", "bb.content");
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerBBContent(), TileEntityBarrel);
|
||||
}
|
||||
}
|
||||
|
||||
+3
-3
@@ -5,7 +5,7 @@ import java.lang.reflect.Method;
|
||||
import java.util.List;
|
||||
import java.util.logging.Level;
|
||||
|
||||
import mcp.mobius.waila.Waila;
|
||||
import mcp.mobius.waila.mod_Waila;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
@@ -15,7 +15,7 @@ import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.MovingObjectPosition;
|
||||
import net.minecraft.world.World;
|
||||
import mcp.mobius.waila.cbcore.LangUtil;
|
||||
import codechicken.lib.lang.LangUtil;
|
||||
import codechicken.nei.api.API;
|
||||
import codechicken.nei.api.ItemInfo;
|
||||
import codechicken.nei.api.ItemInfo.Layout;
|
||||
@@ -43,7 +43,7 @@ public class HUDHandlerBBContent implements IWailaDataProvider {
|
||||
try {
|
||||
stack = (ItemStack) BetterBarrelsModule.IBarrelStorage_getItem.invoke(BetterBarrelsModule.TileEntityBarrel_Storage.get(entity));
|
||||
} catch (Exception e){
|
||||
Waila.log.log(Level.SEVERE, "[BB] Unhandled exception trying to access a barrel storage for display !.\n" + String.valueOf(e));
|
||||
mod_Waila.log.log(Level.SEVERE, "[BB] Unhandled exception trying to access a barrel storage for display !.\n" + String.valueOf(e));
|
||||
currenttip.add("<ERROR!>");
|
||||
return currenttip;
|
||||
}
|
||||
+11
-12
@@ -3,9 +3,9 @@ package mcp.mobius.waila.addons.buildcraft;
|
||||
import java.lang.reflect.Method;
|
||||
import java.util.logging.Level;
|
||||
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
import mcp.mobius.waila.Waila;
|
||||
import mcp.mobius.waila.api.impl.ModuleRegistrar;
|
||||
import mcp.mobius.waila.mod_Waila;
|
||||
import mcp.mobius.waila.addons.ExternalModulesHandler;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
|
||||
public class BCModule {
|
||||
|
||||
@@ -20,9 +20,9 @@ public class BCModule {
|
||||
public static void register(){
|
||||
try {
|
||||
Class ModBuildcraftFactory = Class.forName("buildcraft.BuildCraftFactory");
|
||||
Waila.log.log(Level.INFO, "Buildcraft|Factory mod found.");
|
||||
mod_Waila.log.log(Level.INFO, "Buildcraft|Factory mod found.");
|
||||
} catch (ClassNotFoundException e){
|
||||
Waila.log.log(Level.INFO, "Buildcraft|Factory mod not found. Skipping.");
|
||||
mod_Waila.log.log(Level.INFO, "Buildcraft|Factory mod not found. Skipping.");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -31,18 +31,17 @@ public class BCModule {
|
||||
TileTank_getTankInfo = TileTank.getMethod("getTankInfo", ForgeDirection.class);
|
||||
|
||||
} catch (ClassNotFoundException e){
|
||||
Waila.log.log(Level.WARNING, "[BC] Class not found. " + e);
|
||||
mod_Waila.log.log(Level.WARNING, "[BC] Class not found. " + e);
|
||||
return;
|
||||
} catch (NoSuchMethodException e){
|
||||
Waila.log.log(Level.WARNING, "[BC] Method not found." + e);
|
||||
mod_Waila.log.log(Level.WARNING, "[BC] Method not found." + e);
|
||||
return;
|
||||
}
|
||||
|
||||
ModuleRegistrar.instance().addConfig("Buildcraft", "bc.tankamount");
|
||||
ModuleRegistrar.instance().addConfig("Buildcraft", "bc.tanktype");
|
||||
ModuleRegistrar.instance().registerHeadProvider(new HUDHandlerBCTanks(), TileTank);
|
||||
ModuleRegistrar.instance().registerBodyProvider(new HUDHandlerBCTanks(), TileTank);
|
||||
ModuleRegistrar.instance().registerSyncedNBTKey("*", TileTank);
|
||||
ExternalModulesHandler.instance().addConfig("Buildcraft", "bc.tankamount");
|
||||
ExternalModulesHandler.instance().addConfig("Buildcraft", "bc.tanktype");
|
||||
ExternalModulesHandler.instance().registerHeadProvider(new HUDHandlerBCTanks(), TileTank);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerBCTanks(), TileTank);
|
||||
}
|
||||
|
||||
}
|
||||
+12
-13
@@ -4,9 +4,9 @@ import java.lang.reflect.Field;
|
||||
import java.lang.reflect.Method;
|
||||
import java.util.logging.Level;
|
||||
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
import mcp.mobius.waila.Waila;
|
||||
import mcp.mobius.waila.api.impl.ModuleRegistrar;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import mcp.mobius.waila.mod_Waila;
|
||||
import mcp.mobius.waila.addons.ExternalModulesHandler;
|
||||
|
||||
public class BCPowerAPIModule {
|
||||
|
||||
@@ -30,9 +30,9 @@ public class BCPowerAPIModule {
|
||||
public static void register(){
|
||||
try{
|
||||
Class ModClass = Class.forName("buildcraft.api.power.IPowerReceptor");
|
||||
Waila.log.log(Level.INFO, "Buildcraft Power API found.");
|
||||
mod_Waila.log.log(Level.INFO, "Buildcraft Power API found.");
|
||||
} catch (ClassNotFoundException e){
|
||||
Waila.log.log(Level.INFO, "[Buildcraft Power API] Buildcraft Power API mod not found.");
|
||||
mod_Waila.log.log(Level.INFO, "[Buildcraft Power API] Buildcraft Power API mod not found.");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -56,24 +56,23 @@ public class BCPowerAPIModule {
|
||||
|
||||
|
||||
} catch (ClassNotFoundException e){
|
||||
Waila.log.log(Level.WARNING, "[EnderStorage] Class not found. " + e);
|
||||
mod_Waila.log.log(Level.WARNING, "[EnderStorage] Class not found. " + e);
|
||||
return;
|
||||
} catch (NoSuchMethodException e){
|
||||
Waila.log.log(Level.WARNING, "[EnderStorage] Method not found." + e);
|
||||
mod_Waila.log.log(Level.WARNING, "[EnderStorage] Method not found." + e);
|
||||
return;
|
||||
// } catch (NoSuchFieldException e){
|
||||
// mod_Waila.log.log(Level.WARNING, "[EnderStorage] Field not found." + e);
|
||||
// return;
|
||||
} catch (Exception e){
|
||||
Waila.log.log(Level.WARNING, "[EnderStorage] Unhandled exception." + e);
|
||||
mod_Waila.log.log(Level.WARNING, "[EnderStorage] Unhandled exception." + e);
|
||||
return;
|
||||
}
|
||||
|
||||
ModuleRegistrar.instance().addConfigRemote("BuildcraftAPI", "bcapi.storage");
|
||||
ModuleRegistrar.instance().addConfig("BuildcraftAPI", "bcapi.consump");
|
||||
ModuleRegistrar.instance().addConfig("BuildcraftAPI", "bcapi.trigger");
|
||||
ModuleRegistrar.instance().registerBodyProvider(new HUDHandlerIPowerReceptor(), IPowerReceptor);
|
||||
ModuleRegistrar.instance().registerSyncedNBTKey("*", IPowerReceptor);
|
||||
ExternalModulesHandler.instance().addConfigRemote("BuildcraftAPI", "bcapi.storage");
|
||||
ExternalModulesHandler.instance().addConfig("BuildcraftAPI", "bcapi.consump");
|
||||
ExternalModulesHandler.instance().addConfig("BuildcraftAPI", "bcapi.trigger");
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerIPowerReceptor(), IPowerReceptor);
|
||||
|
||||
}
|
||||
|
||||
+12
-5
@@ -5,17 +5,24 @@ import java.util.logging.Level;
|
||||
|
||||
//import buildcraft.factory.TileTank;
|
||||
|
||||
import mcp.mobius.waila.Waila;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
import codechicken.lib.lang.LangUtil;
|
||||
import mcp.mobius.waila.mod_Waila;
|
||||
import mcp.mobius.waila.addons.ConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
import mcp.mobius.waila.api.impl.ConfigHandler;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import net.minecraftforge.fluids.FluidStack;
|
||||
import net.minecraftforge.fluids.FluidTankInfo;
|
||||
import net.minecraftforge.fluids.IFluidHandler;
|
||||
import mcp.mobius.waila.cbcore.LangUtil;
|
||||
import net.minecraftforge.liquids.ILiquidTank;
|
||||
import net.minecraftforge.liquids.LiquidStack;
|
||||
|
||||
public class HUDHandlerBCTanks implements IWailaDataProvider {
|
||||
|
||||
@@ -62,7 +69,7 @@ public class HUDHandlerBCTanks implements IWailaDataProvider {
|
||||
try{
|
||||
tank = ((FluidTankInfo[])BCModule.TileTank_getTankInfo.invoke(BCModule.TileTank.cast(accessor.getTileEntity()), ForgeDirection.UNKNOWN))[0];
|
||||
} catch (Exception e){
|
||||
Waila.log.log(Level.SEVERE, "[BC] Unhandled exception trying to access a tank for display !.\n" + String.valueOf(e));
|
||||
mod_Waila.log.log(Level.SEVERE, "[BC] Unhandled exception trying to access a tank for display !.\n" + String.valueOf(e));
|
||||
return null;
|
||||
}
|
||||
return tank;
|
||||
+4
-6
@@ -2,13 +2,13 @@ package mcp.mobius.waila.addons.buildcraft;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import codechicken.lib.lang.LangUtil;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import mcp.mobius.waila.WailaExceptionHandler;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
import mcp.mobius.waila.cbcore.LangUtil;
|
||||
import mcp.mobius.waila.utils.WailaExceptionHandler;
|
||||
|
||||
public class HUDHandlerIPowerReceptor implements IWailaDataProvider {
|
||||
|
||||
@@ -52,14 +52,12 @@ public class HUDHandlerIPowerReceptor implements IWailaDataProvider {
|
||||
currenttip.add(String.format("%.1f / %.1f MJ", energyStored, maxEnergyStor));
|
||||
}
|
||||
|
||||
/*
|
||||
if (maxEnergyRecv != 0.0f && config.getConfig("bcapi.consump"))
|
||||
//currenttip.add(String.format("Min/Max Input : %.1f / %.1f MJ/t", minEnergyRecv, maxEnergyRecv));
|
||||
currenttip.add(String.format("%s : %.1f MJ/t", maxPowerStr, maxEnergyRecv));
|
||||
|
||||
if (activation != 0.0f && config.getConfig("bcapi.trigger"))
|
||||
currenttip.add(String.format("%s : %.1f MJ", triggerStr, activation));
|
||||
*/
|
||||
currenttip.add(String.format("%s : %.1f MJ", triggerStr, activation));
|
||||
|
||||
}
|
||||
|
||||
File renamed without changes.
+14
-15
@@ -4,8 +4,9 @@ import java.lang.reflect.Field;
|
||||
import java.lang.reflect.Method;
|
||||
import java.util.logging.Level;
|
||||
|
||||
import mcp.mobius.waila.Waila;
|
||||
import mcp.mobius.waila.api.impl.ModuleRegistrar;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import mcp.mobius.waila.mod_Waila;
|
||||
import mcp.mobius.waila.addons.ExternalModulesHandler;
|
||||
|
||||
public class EnderIOModule {
|
||||
|
||||
@@ -21,9 +22,9 @@ public class EnderIOModule {
|
||||
public static void register(){
|
||||
try{
|
||||
Class ModClass = Class.forName("crazypants.enderio.EnderIO");
|
||||
Waila.log.log(Level.INFO, "EnderIO mod found.");
|
||||
mod_Waila.log.log(Level.INFO, "EnderIO mod found.");
|
||||
} catch (ClassNotFoundException e){
|
||||
Waila.log.log(Level.INFO, "[EnderIO] EnderIO mod not found.");
|
||||
mod_Waila.log.log(Level.INFO, "[EnderIO] EnderIO mod not found.");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -39,27 +40,25 @@ public class EnderIOModule {
|
||||
TileTesseract = Class.forName("crazypants.enderio.machine.hypercube.TileHyperCube");
|
||||
|
||||
} catch (ClassNotFoundException e){
|
||||
Waila.log.log(Level.WARNING, "[EnderStorage] Class not found. " + e);
|
||||
mod_Waila.log.log(Level.WARNING, "[EnderStorage] Class not found. " + e);
|
||||
return;
|
||||
} catch (NoSuchMethodException e){
|
||||
Waila.log.log(Level.WARNING, "[EnderStorage] Method not found." + e);
|
||||
mod_Waila.log.log(Level.WARNING, "[EnderStorage] Method not found." + e);
|
||||
return;
|
||||
// } catch (NoSuchFieldException e){
|
||||
// mod_Waila.log.log(Level.WARNING, "[EnderStorage] Field not found." + e);
|
||||
// return;
|
||||
} catch (Exception e){
|
||||
Waila.log.log(Level.WARNING, "[EnderStorage] Unhandled exception." + e);
|
||||
mod_Waila.log.log(Level.WARNING, "[EnderStorage] Unhandled exception." + e);
|
||||
return;
|
||||
}
|
||||
|
||||
ModuleRegistrar.instance().addConfig("EnderIO", "enderio.inout");
|
||||
ModuleRegistrar.instance().addConfig("EnderIO", "enderio.storage");
|
||||
ModuleRegistrar.instance().addConfig("EnderIO", "enderio.owner");
|
||||
ModuleRegistrar.instance().addConfig("EnderIO", "enderio.channel");
|
||||
ModuleRegistrar.instance().registerBodyProvider(new HUDHandlerCapacitor(), TileCapacitorBank);
|
||||
ModuleRegistrar.instance().registerBodyProvider(new HUDHandlerTesseract(), TileTesseract);
|
||||
ModuleRegistrar.instance().registerSyncedNBTKey("*", TileCapacitorBank);
|
||||
ModuleRegistrar.instance().registerSyncedNBTKey("*", TileTesseract);
|
||||
ExternalModulesHandler.instance().addConfig("EnderIO", "enderio.inout");
|
||||
ExternalModulesHandler.instance().addConfig("EnderIO", "enderio.storage");
|
||||
ExternalModulesHandler.instance().addConfig("EnderIO", "enderio.owner");
|
||||
ExternalModulesHandler.instance().addConfig("EnderIO", "enderio.channel");
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerCapacitor(), TileCapacitorBank);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerTesseract(), TileTesseract);
|
||||
}
|
||||
|
||||
}
|
||||
+2
-2
@@ -2,12 +2,12 @@ package mcp.mobius.waila.addons.enderio;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import mcp.mobius.waila.cbcore.LangUtil;
|
||||
import codechicken.lib.lang.LangUtil;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import mcp.mobius.waila.WailaExceptionHandler;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
import mcp.mobius.waila.utils.WailaExceptionHandler;
|
||||
|
||||
public class HUDHandlerCapacitor implements IWailaDataProvider{
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@ package mcp.mobius.waila.addons.enderio;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import mcp.mobius.waila.cbcore.LangUtil;
|
||||
import codechicken.lib.lang.LangUtil;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
+10
-11
@@ -4,8 +4,8 @@ import java.lang.reflect.Field;
|
||||
import java.lang.reflect.Method;
|
||||
import java.util.logging.Level;
|
||||
|
||||
import mcp.mobius.waila.Waila;
|
||||
import mcp.mobius.waila.api.impl.ModuleRegistrar;
|
||||
import mcp.mobius.waila.mod_Waila;
|
||||
import mcp.mobius.waila.addons.ExternalModulesHandler;
|
||||
|
||||
public class EnderStorageModule {
|
||||
|
||||
@@ -20,9 +20,9 @@ public class EnderStorageModule {
|
||||
public static void register(){
|
||||
try{
|
||||
Class EnderStorage = Class.forName("codechicken.enderstorage.EnderStorage");
|
||||
Waila.log.log(Level.INFO, "EnderStorage mod found.");
|
||||
mod_Waila.log.log(Level.INFO, "EnderStorage mod found.");
|
||||
} catch (ClassNotFoundException e){
|
||||
Waila.log.log(Level.INFO, "[EnderStorage] EnderStorage mod not found.");
|
||||
mod_Waila.log.log(Level.INFO, "[EnderStorage] EnderStorage mod not found.");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -37,21 +37,20 @@ public class EnderStorageModule {
|
||||
TileEnderTank = Class.forName("codechicken.enderstorage.storage.liquid.TileEnderTank");
|
||||
|
||||
} catch (ClassNotFoundException e){
|
||||
Waila.log.log(Level.WARNING, "[EnderStorage] Class not found. " + e);
|
||||
mod_Waila.log.log(Level.WARNING, "[EnderStorage] Class not found. " + e);
|
||||
return;
|
||||
} catch (NoSuchMethodException e){
|
||||
Waila.log.log(Level.WARNING, "[EnderStorage] Method not found." + e);
|
||||
mod_Waila.log.log(Level.WARNING, "[EnderStorage] Method not found." + e);
|
||||
return;
|
||||
} catch (NoSuchFieldException e){
|
||||
Waila.log.log(Level.WARNING, "[EnderStorage] Field not found." + e);
|
||||
mod_Waila.log.log(Level.WARNING, "[EnderStorage] Field not found." + e);
|
||||
return;
|
||||
} catch (Exception e){
|
||||
Waila.log.log(Level.WARNING, "[EnderStorage] Unhandled exception." + e);
|
||||
mod_Waila.log.log(Level.WARNING, "[EnderStorage] Unhandled exception." + e);
|
||||
return;
|
||||
}
|
||||
|
||||
ModuleRegistrar.instance().addConfig("EnderStorage", "enderstorage.colors");
|
||||
ModuleRegistrar.instance().registerBodyProvider(new HUDHandlerStorage(), TileFrequencyOwner);
|
||||
ModuleRegistrar.instance().registerSyncedNBTKey("*", TileFrequencyOwner);
|
||||
ExternalModulesHandler.instance().addConfig("EnderStorage", "enderstorage.colors");
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerStorage(), TileFrequencyOwner);
|
||||
}
|
||||
}
|
||||
+2
-2
@@ -2,12 +2,12 @@ package mcp.mobius.waila.addons.enderstorage;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import mcp.mobius.waila.cbcore.LangUtil;
|
||||
import codechicken.lib.lang.LangUtil;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import mcp.mobius.waila.WailaExceptionHandler;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
import mcp.mobius.waila.utils.WailaExceptionHandler;
|
||||
|
||||
public class HUDHandlerStorage implements IWailaDataProvider {
|
||||
|
||||
+10
-10
@@ -4,8 +4,8 @@ import java.lang.reflect.Field;
|
||||
import java.util.logging.Level;
|
||||
|
||||
import net.minecraft.item.Item;
|
||||
import mcp.mobius.waila.Waila;
|
||||
import mcp.mobius.waila.api.impl.ModuleRegistrar;
|
||||
import mcp.mobius.waila.mod_Waila;
|
||||
import mcp.mobius.waila.addons.ExternalModulesHandler;
|
||||
|
||||
public class ETBModule {
|
||||
|
||||
@@ -29,9 +29,9 @@ public class ETBModule {
|
||||
public static void register(){
|
||||
try{
|
||||
Class ModClass = Class.forName("emasher.sockets.TileSocket");
|
||||
Waila.log.log(Level.INFO, "Engineer Toolbox mod found.");
|
||||
mod_Waila.log.log(Level.INFO, "Engineer Toolbox mod found.");
|
||||
} catch (ClassNotFoundException e){
|
||||
Waila.log.log(Level.INFO, "[Engineer Toolbox] Engineer Toolbox mod not found.");
|
||||
mod_Waila.log.log(Level.INFO, "[Engineer Toolbox] Engineer Toolbox mod not found.");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -63,21 +63,21 @@ public class ETBModule {
|
||||
|
||||
|
||||
} catch (ClassNotFoundException e){
|
||||
Waila.log.log(Level.WARNING, "[Engineer Toolbox] Class not found. " + e);
|
||||
mod_Waila.log.log(Level.WARNING, "[Engineer Toolbox] Class not found. " + e);
|
||||
return;
|
||||
// } catch (NoSuchMethodException e){
|
||||
// mod_Waila.log.log(Level.WARNING, "[Engineer Toolbox] Method not found." + e);
|
||||
// return;
|
||||
} catch (NoSuchFieldException e){
|
||||
Waila.log.log(Level.WARNING, "[Engineer Toolbox] Field not found." + e);
|
||||
mod_Waila.log.log(Level.WARNING, "[Engineer Toolbox] Field not found." + e);
|
||||
return;
|
||||
} catch (Exception e){
|
||||
Waila.log.log(Level.WARNING, "[Engineer Toolbox] Unhandled exception." + e);
|
||||
mod_Waila.log.log(Level.WARNING, "[Engineer Toolbox] Unhandled exception." + e);
|
||||
return;
|
||||
}
|
||||
|
||||
ModuleRegistrar.instance().addConfig("Engineer Toolbox", "etb.displaydata");
|
||||
ModuleRegistrar.instance().registerBodyProvider(new HUDHandlerSocket(), TileSocket);
|
||||
ModuleRegistrar.instance().registerSyncedNBTKey("*", TileSocket);
|
||||
ExternalModulesHandler.instance().addConfig("Engineer Toolbox", "etb.displaydata");
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerSocket(), TileSocket);
|
||||
|
||||
}
|
||||
}
|
||||
+2
-2
@@ -5,11 +5,11 @@ import java.util.List;
|
||||
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import mcp.mobius.waila.WailaExceptionHandler;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
import mcp.mobius.waila.utils.WailaExceptionHandler;
|
||||
|
||||
public class HUDHandlerSocket implements IWailaDataProvider {
|
||||
|
||||
+6
-7
@@ -2,8 +2,8 @@ package mcp.mobius.waila.addons.gravestone;
|
||||
|
||||
import java.util.logging.Level;
|
||||
|
||||
import mcp.mobius.waila.Waila;
|
||||
import mcp.mobius.waila.api.impl.ModuleRegistrar;
|
||||
import mcp.mobius.waila.mod_Waila;
|
||||
import mcp.mobius.waila.addons.ExternalModulesHandler;
|
||||
|
||||
public class GravestoneModule {
|
||||
|
||||
@@ -13,21 +13,20 @@ public class GravestoneModule {
|
||||
|
||||
try{
|
||||
Class ModGravestone = Class.forName("GraveStone.ModGraveStone");
|
||||
Waila.log.log(Level.INFO, "GraveStone mod found.");
|
||||
mod_Waila.log.log(Level.INFO, "GraveStone mod found.");
|
||||
} catch (ClassNotFoundException e){
|
||||
Waila.log.log(Level.INFO, "[GraveStone] GraveStone mod not found.");
|
||||
mod_Waila.log.log(Level.INFO, "[GraveStone] GraveStone mod not found.");
|
||||
return;
|
||||
}
|
||||
|
||||
try {
|
||||
BlockGraveStone = Class.forName("GraveStone.block.BlockGSGraveStone");
|
||||
} catch (ClassNotFoundException e) {
|
||||
Waila.log.log(Level.WARNING, "[GraveStone] Class not found. " + e);
|
||||
mod_Waila.log.log(Level.WARNING, "[GraveStone] Class not found. " + e);
|
||||
}
|
||||
|
||||
|
||||
ModuleRegistrar.instance().registerStackProvider(new HUDHandlerGravestone(), BlockGraveStone);
|
||||
ModuleRegistrar.instance().registerSyncedNBTKey("*", BlockGraveStone);
|
||||
ExternalModulesHandler.instance().registerStackProvider(new HUDHandlerGravestone(), BlockGraveStone);
|
||||
}
|
||||
|
||||
}
|
||||
File renamed without changes.
+5
-6
@@ -2,14 +2,13 @@ package mcp.mobius.waila.addons.ic2;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import mcp.mobius.waila.cbcore.LangUtil;
|
||||
import codechicken.lib.lang.LangUtil;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import mcp.mobius.waila.WailaExceptionHandler;
|
||||
import mcp.mobius.waila.addons.ConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
import mcp.mobius.waila.api.impl.ConfigHandler;
|
||||
import mcp.mobius.waila.utils.WailaExceptionHandler;
|
||||
import static mcp.mobius.waila.api.SpecialChars.*;
|
||||
|
||||
public class HUDHandlerTEBaseGenerator implements IWailaDataProvider {
|
||||
|
||||
@@ -51,7 +50,7 @@ public class HUDHandlerTEBaseGenerator implements IWailaDataProvider {
|
||||
double stored = IC2Module.getStoredEnergy(accessor);
|
||||
|
||||
if ( stored >= 0.0 && storage > 0)
|
||||
currenttip.add(String.format("%s%s\u00a7f%d\u00a7r / \u00a7f%d\u00a7r EU", storedStr, TAB + ALIGNRIGHT, Math.round(Math.min(stored,storage)), storage));
|
||||
currenttip.add(String.format("%s : \u00a7f%d\u00a7r / \u00a7f%d\u00a7r EU", storedStr, Math.round(Math.min(stored,storage)), storage));
|
||||
|
||||
//else if (stored >= 0.0)
|
||||
// currenttip.add(String.format("Stored : %d EU", stored));
|
||||
@@ -59,7 +58,7 @@ public class HUDHandlerTEBaseGenerator implements IWailaDataProvider {
|
||||
|
||||
if (ConfigHandler.instance().getConfig("ic2.outputeu")){
|
||||
if ( production > 0)
|
||||
currenttip.add(String.format("%s%s\u00a7f%d\u00a7r EU/t", outputStr, TAB + ALIGNRIGHT, production));
|
||||
currenttip.add(String.format("%s : \u00a7f%d\u00a7r EU/t", outputStr, production));
|
||||
}
|
||||
|
||||
} catch (Exception e){
|
||||
+5
-6
@@ -2,14 +2,13 @@ package mcp.mobius.waila.addons.ic2;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import mcp.mobius.waila.cbcore.LangUtil;
|
||||
import codechicken.lib.lang.LangUtil;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import mcp.mobius.waila.WailaExceptionHandler;
|
||||
import mcp.mobius.waila.addons.ConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
import mcp.mobius.waila.api.impl.ConfigHandler;
|
||||
import mcp.mobius.waila.utils.WailaExceptionHandler;
|
||||
import static mcp.mobius.waila.api.SpecialChars.*;
|
||||
|
||||
public class HUDHandlerTEElectricBlock implements IWailaDataProvider {
|
||||
|
||||
@@ -38,13 +37,13 @@ public class HUDHandlerTEElectricBlock implements IWailaDataProvider {
|
||||
int storage = IC2Module.TEEB_MaxStorage.getInt(accessor.getTileEntity());
|
||||
|
||||
if ( stored >= 0.0 )
|
||||
currenttip.add(String.format("%s%s\u00a7f%d\u00a7r / \u00a7f%d\u00a7r EU", storedStr, TAB + ALIGNRIGHT, Math.round(Math.min(stored,storage)), storage));
|
||||
currenttip.add(String.format("%s : \u00a7f%d\u00a7r / \u00a7f%d\u00a7r EU", storedStr, Math.round(Math.min(stored,storage)), storage));
|
||||
}
|
||||
|
||||
if (ConfigHandler.instance().getConfig("ic2.outputeu")){
|
||||
int production = IC2Module.TEEB_Output.getInt(accessor.getTileEntity());
|
||||
if ( production > 0)
|
||||
currenttip.add(String.format("%s%s\u00a7f%d\u00a7r EU/t", outputStr, TAB + ALIGNRIGHT, production));
|
||||
currenttip.add(String.format("%s : \u00a7f%d\u00a7r EU/t", outputStr, production));
|
||||
}
|
||||
|
||||
} catch (Exception e){
|
||||
+6
-7
@@ -2,14 +2,13 @@ package mcp.mobius.waila.addons.ic2;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import mcp.mobius.waila.cbcore.LangUtil;
|
||||
import codechicken.lib.lang.LangUtil;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import mcp.mobius.waila.WailaExceptionHandler;
|
||||
import mcp.mobius.waila.addons.ConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
import mcp.mobius.waila.api.impl.ConfigHandler;
|
||||
import mcp.mobius.waila.utils.WailaExceptionHandler;
|
||||
import static mcp.mobius.waila.api.SpecialChars.*;
|
||||
|
||||
public class HUDHandlerTEStandardMachine implements IWailaDataProvider {
|
||||
|
||||
@@ -54,17 +53,17 @@ public class HUDHandlerTEStandardMachine implements IWailaDataProvider {
|
||||
/* EU Storage */
|
||||
if (ConfigHandler.instance().getConfig("ic2.storage")){
|
||||
if ( stored >= 0.0 )
|
||||
currenttip.add(String.format("%s%s\u00a7f%d\u00a7r / \u00a7f%d\u00a7r EU", storedStr, TAB + ALIGNRIGHT, Math.round(Math.min(stored,storage)), storage));
|
||||
currenttip.add(String.format("%s : \u00a7f%d\u00a7r / \u00a7f%d\u00a7r EU", storedStr, Math.round(Math.min(stored,storage)), storage));
|
||||
}
|
||||
|
||||
if (ConfigHandler.instance().getConfig("ic2.consump")){
|
||||
if ( consumption > 0)
|
||||
currenttip.add(String.format("%s%s\u00a7f%d\u00a7r EU/t", powerStr, TAB + ALIGNRIGHT, consumption ));
|
||||
currenttip.add(String.format("%s : \u00a7f%d\u00a7r EU/t", powerStr, consumption ));
|
||||
}
|
||||
|
||||
if (ConfigHandler.instance().getConfig("ic2.inputeu")){
|
||||
if ( maxinput > 0)
|
||||
currenttip.add(String.format("%s%s\u00a7f%d\u00a7r EU/t", maxPowerStr, TAB + ALIGNRIGHT, maxinput ));
|
||||
currenttip.add(String.format("%s : \u00a7f%d\u00a7r EU/t", maxPowerStr, maxinput ));
|
||||
}
|
||||
|
||||
} catch (Exception e){
|
||||
+6
-7
@@ -2,15 +2,14 @@ package mcp.mobius.waila.addons.ic2;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import mcp.mobius.waila.cbcore.LangUtil;
|
||||
import codechicken.lib.lang.LangUtil;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.nbt.NBTTagList;
|
||||
import mcp.mobius.waila.addons.ConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
import mcp.mobius.waila.api.impl.ConfigHandler;
|
||||
import static mcp.mobius.waila.api.SpecialChars.*;
|
||||
|
||||
public class HUDHandlerTETradeOMat implements IWailaDataProvider {
|
||||
|
||||
@@ -26,7 +25,7 @@ public class HUDHandlerTETradeOMat implements IWailaDataProvider {
|
||||
|
||||
@Override
|
||||
public List<String> getWailaBody(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
/*
|
||||
|
||||
if (!ConfigHandler.instance().getConfig("ic2.tradeomat")) return currenttip;
|
||||
|
||||
NBTTagCompound slots = accessor.getNBTData().getCompoundTag("InvSlots");
|
||||
@@ -39,15 +38,15 @@ public class HUDHandlerTETradeOMat implements IWailaDataProvider {
|
||||
if (offer.tagCount() == 1){
|
||||
NBTTagCompound subtag = (NBTTagCompound)offer.tagAt(0);
|
||||
ItemStack is = new ItemStack(subtag.getShort("id"), subtag.getByte("Count"), subtag.getShort("Damage"));
|
||||
currenttip.add(String.format("%s%s\u00a7f%d\u00a7r x \u00a7f%s\u00a7r", offersStr, TAB + ALIGNRIGHT, is.stackSize, is.getDisplayName()));
|
||||
currenttip.add(String.format("%s : \u00a7f%d\u00a7r x \u00a7f%s\u00a7r", offersStr, is.stackSize, is.getDisplayName()));
|
||||
}
|
||||
|
||||
if (demand.tagCount() == 1){
|
||||
NBTTagCompound subtag = (NBTTagCompound)demand.tagAt(0);
|
||||
ItemStack is = new ItemStack(subtag.getShort("id"), subtag.getByte("Count"), subtag.getShort("Damage"));
|
||||
currenttip.add(String.format("%s%s\u00a7f%d\u00a7r x \u00a7f%s\u00a7r", demandsStr, TAB + ALIGNRIGHT, is.stackSize, is.getDisplayName()));
|
||||
currenttip.add(String.format("%s : \u00a7f%d\u00a7r x \u00a7f%s\u00a7r", demandsStr, is.stackSize, is.getDisplayName()));
|
||||
}
|
||||
*/
|
||||
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
+26
-44
@@ -2,18 +2,15 @@ package mcp.mobius.waila.addons.ic2;
|
||||
|
||||
import java.lang.reflect.Field;
|
||||
import java.lang.reflect.Method;
|
||||
import java.util.List;
|
||||
import java.util.logging.Level;
|
||||
|
||||
import cpw.mods.fml.common.ObfuscationReflectionHelper;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.nbt.NBTTagList;
|
||||
import mcp.mobius.waila.Waila;
|
||||
import mcp.mobius.waila.mod_Waila;
|
||||
import mcp.mobius.waila.addons.ConfigHandler;
|
||||
import mcp.mobius.waila.addons.ExternalModulesHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.impl.ConfigHandler;
|
||||
import mcp.mobius.waila.api.impl.ModuleRegistrar;
|
||||
import mcp.mobius.waila.utils.AccessHelper;
|
||||
|
||||
public class IC2Module {
|
||||
|
||||
@@ -54,7 +51,7 @@ public class IC2Module {
|
||||
public static ItemStack OverclockerUpgradeStack = null;
|
||||
|
||||
public static void register(){
|
||||
/*
|
||||
|
||||
|
||||
try{
|
||||
TileEntityStandardMachine = Class.forName("ic2.core.block.machine.tileentity.TileEntityStandardMachine");
|
||||
@@ -96,56 +93,46 @@ public class IC2Module {
|
||||
TileEntityTradeOMat = Class.forName("ic2.core.block.personal.TileEntityTradeOMat");
|
||||
|
||||
} catch (ClassNotFoundException e){
|
||||
//e.printStackTrace();
|
||||
Waila.log.log(Level.WARNING, "[IC2] Class not found. " + e);
|
||||
e.printStackTrace();
|
||||
mod_Waila.log.log(Level.WARNING, "[IC2] Class not found. " + e);
|
||||
return;
|
||||
} catch (NoSuchMethodException e){
|
||||
//e.printStackTrace();
|
||||
Waila.log.log(Level.WARNING, "[IC2] Method not found." + e);
|
||||
e.printStackTrace();
|
||||
mod_Waila.log.log(Level.WARNING, "[IC2] Method not found." + e);
|
||||
return;
|
||||
} catch (NoSuchFieldException e){
|
||||
//e.printStackTrace();
|
||||
Waila.log.log(Level.WARNING, "[IC2] Field not found." + e);
|
||||
e.printStackTrace();
|
||||
mod_Waila.log.log(Level.WARNING, "[IC2] Field not found." + e);
|
||||
return;
|
||||
} catch (Exception e){
|
||||
//e.printStackTrace();
|
||||
Waila.log.log(Level.WARNING, "[IC2] Unhandled exception." + e);
|
||||
e.printStackTrace();
|
||||
mod_Waila.log.log(Level.WARNING, "[IC2] Unhandled exception." + e);
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
ModuleRegistrar.instance().addConfigRemote("IndustrialCraft2", "ic2.storage");
|
||||
ModuleRegistrar.instance().addConfig("IndustrialCraft2", "ic2.outputeu");
|
||||
ModuleRegistrar.instance().addConfigRemote("IndustrialCraft2", "ic2.inputeu");
|
||||
ModuleRegistrar.instance().addConfigRemote("IndustrialCraft2", "ic2.consump");
|
||||
ModuleRegistrar.instance().addConfigRemote("IndustrialCraft2", "ic2.tradeomat");
|
||||
ExternalModulesHandler.instance().addConfigRemote("IndustrialCraft2", "ic2.storage");
|
||||
ExternalModulesHandler.instance().addConfig("IndustrialCraft2", "ic2.outputeu");
|
||||
ExternalModulesHandler.instance().addConfigRemote("IndustrialCraft2", "ic2.inputeu");
|
||||
ExternalModulesHandler.instance().addConfigRemote("IndustrialCraft2", "ic2.consump");
|
||||
ExternalModulesHandler.instance().addConfigRemote("IndustrialCraft2", "ic2.tradeomat");
|
||||
|
||||
ModuleRegistrar.instance().registerBodyProvider(new HUDHandlerTEStandardMachine(), TileEntityStandardMachine);
|
||||
ModuleRegistrar.instance().registerBodyProvider(new HUDHandlerTEBaseGenerator(), TileEntityBaseGenerator);
|
||||
ModuleRegistrar.instance().registerBodyProvider(new HUDHandlerTEBaseGenerator(), TileEntitySemifluidGenerator);
|
||||
ModuleRegistrar.instance().registerBodyProvider(new HUDHandlerTEBaseGenerator(), TileEntityGeoGenerator);
|
||||
ModuleRegistrar.instance().registerBodyProvider(new HUDHandlerTEElectricBlock(), TileEntityElectricBlock);
|
||||
ModuleRegistrar.instance().registerBodyProvider(new HUDHandlerTETradeOMat(), TileEntityTradeOMat);
|
||||
|
||||
ModuleRegistrar.instance().registerSyncedNBTKey("*", TileEntityStandardMachine);
|
||||
ModuleRegistrar.instance().registerSyncedNBTKey("*", TileEntityBaseGenerator);
|
||||
ModuleRegistrar.instance().registerSyncedNBTKey("*", TileEntitySemifluidGenerator);
|
||||
ModuleRegistrar.instance().registerSyncedNBTKey("*", TileEntityGeoGenerator);
|
||||
ModuleRegistrar.instance().registerSyncedNBTKey("*", TileEntityElectricBlock);
|
||||
ModuleRegistrar.instance().registerSyncedNBTKey("*", TileEntityTradeOMat);
|
||||
*/
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerTEStandardMachine(), TileEntityStandardMachine);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerTEBaseGenerator(), TileEntityBaseGenerator);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerTEBaseGenerator(), TileEntitySemifluidGenerator);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerTEBaseGenerator(), TileEntityGeoGenerator);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerTEElectricBlock(), TileEntityElectricBlock);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerTETradeOMat(), TileEntityTradeOMat);
|
||||
}
|
||||
|
||||
/* Retuns the current stored energy if available in the nbt and config is true */
|
||||
public static double getStoredEnergy(IWailaDataAccessor accessor){
|
||||
/*
|
||||
if (ConfigHandler.instance().getConfig("ic2.storage")){
|
||||
if (accessor.getNBTData().hasKey("energy"))
|
||||
return accessor.getNBTData().getDouble("energy");
|
||||
else if (accessor.getNBTData().hasKey("storage"))
|
||||
return accessor.getNBTData().getDouble("storage");
|
||||
}
|
||||
*/
|
||||
return -1.0;
|
||||
}
|
||||
|
||||
@@ -153,19 +140,14 @@ public class IC2Module {
|
||||
|
||||
NBTTagCompound nbt = accessor.getNBTData();
|
||||
IC2Upgrades upgrades = new IC2Upgrades();
|
||||
|
||||
/*
|
||||
|
||||
if (!nbt.hasKey("InvSlots")) return null;
|
||||
|
||||
NBTTagCompound inventory = nbt.getCompoundTag("InvSlots");
|
||||
if (!inventory.hasKey("upgrade")) return null;
|
||||
|
||||
NBTTagList nbtupgrades = inventory.getCompoundTag("upgrade").getTagList("Contents");
|
||||
|
||||
//List tagList = (List)AccessHelper.getField("net.minecraft.nbt.NBTTagList", "tagList", nbtupgrades);
|
||||
List tagList = ObfuscationReflectionHelper.getPrivateValue(NBTTagList.class, nbtupgrades, "field_74747_a");
|
||||
|
||||
for (Object subobj : tagList){
|
||||
for (Object subobj : nbtupgrades.tagList){
|
||||
NBTTagCompound subtag = (NBTTagCompound)subobj;
|
||||
int id = subtag.getShort("id");
|
||||
int meta = subtag.getShort("Damage");
|
||||
@@ -179,7 +161,7 @@ public class IC2Module {
|
||||
if (OverclockerUpgradeStack.getItemDamage() == meta && OverclockerUpgradeStack.itemID == id)
|
||||
upgrades.overclocker += count;
|
||||
}
|
||||
*/
|
||||
|
||||
return upgrades;
|
||||
}
|
||||
|
||||
File renamed without changes.
+24
-37
@@ -4,16 +4,13 @@ import net.minecraft.client.renderer.Tessellator;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.nbt.NBTTagList;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import mcp.mobius.waila.api.IWailaBlockDecorator;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaFMPAccessor;
|
||||
import mcp.mobius.waila.api.IWailaFMPDecorator;
|
||||
import mcp.mobius.waila.gui.helpers.UIHelper;
|
||||
import mcp.mobius.waila.utils.NBTUtil;
|
||||
|
||||
public class HUDDecoratorRsGateLogic implements IWailaFMPDecorator {
|
||||
public class HUDDecoratorRsGateLogic implements IWailaBlockDecorator {
|
||||
|
||||
static byte[][] IOARRAY={
|
||||
{1,1,2,1} /* OR */, {1,1,2,1} /* NOR */, {1,2,2,2} /* NOT */, {1,1,2,1} /* AND */,
|
||||
@@ -25,28 +22,36 @@ public class HUDDecoratorRsGateLogic implements IWailaFMPDecorator {
|
||||
{11,12,11,12} /* Inver */, {11,12,11,12} /* Buff */, {1,9,2,8} /* Cmp */, {1,12,2,12} /* And */,
|
||||
};
|
||||
|
||||
|
||||
static byte[][] IOARRAYALTER={
|
||||
{1,8,2,9} /* Cmp 1*/, {1,6,2,2} /* State 1*/, {2,8,2,9} /* Count 1*/, {6,2,2,1} /* Transp 1*/,
|
||||
{2,1,2,1} /* Latch 1*/, {2,1,2,1} /* Latch 2*/, {2,1,2,1} /* Latch 3*/
|
||||
};
|
||||
|
||||
static String[] IONAMES={ "", "IN", "OUT", "SWAP", "IN_A", "IN_B", "LOCK", "IO", "POS", "NEG", "BUS", "A", "B"};
|
||||
|
||||
@Override
|
||||
public void decorateBlock(ItemStack itemStack, IWailaFMPAccessor accessor, IWailaConfigHandler config) {
|
||||
|
||||
public void decorateBlock(ItemStack itemStack, IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
if (!config.getConfig("pr.showio")) return;
|
||||
|
||||
|
||||
int orient = 0;
|
||||
int subID = 0;
|
||||
int shape = 0;
|
||||
boolean found = false;
|
||||
|
||||
orient = NBTUtil.getNBTInteger(accessor.getNBTData(), "orient");
|
||||
subID = NBTUtil.getNBTInteger(accessor.getNBTData(), "subID");
|
||||
shape = NBTUtil.getNBTInteger(accessor.getNBTData(), "shape");
|
||||
if (!accessor.getNBTData().hasKey("parts")) return;
|
||||
NBTTagList parts = accessor.getNBTData().getTagList("parts");
|
||||
for (int i = 0; i < parts.tagCount(); i++){
|
||||
NBTTagCompound subtag = (NBTTagCompound)parts.tagAt(i);
|
||||
String id = subtag.getString("id");
|
||||
|
||||
if (id.equals("pr_sgate") || id.equals("pr_igate") ||
|
||||
id.equals("pr_tgate") || id.equals("pr_bgate") ||
|
||||
id.equals("pr_agate") || id.equals("pr_rgate")){
|
||||
orient = accessor.getNBTInteger(subtag, "orient");
|
||||
subID = accessor.getNBTInteger(subtag, "subID");
|
||||
shape = accessor.getNBTInteger(subtag, "shape");
|
||||
found = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (!found) return;
|
||||
|
||||
//orient = orient - ((orient & 0x10) + (orient & 0x8) + (orient & 0x4));
|
||||
int hOrient = orient & 0x3;
|
||||
ForgeDirection vOrient = ForgeDirection.getOrientation((orient - (orient & 0x3)) >> 2);
|
||||
@@ -63,27 +68,8 @@ public class HUDDecoratorRsGateLogic implements IWailaFMPDecorator {
|
||||
hOrient = 3;
|
||||
|
||||
String[] IOStr = new String[4];
|
||||
if (shape != 0){
|
||||
int altIndex = -1;
|
||||
if (subID == 26 && shape == 1) altIndex = 0;
|
||||
if (subID == 20 && shape == 1) altIndex = 1;
|
||||
if (subID == 19 && shape == 1) altIndex = 2;
|
||||
if (subID == 14 && shape == 1) altIndex = 3;
|
||||
if (subID == 12 && shape == 1) altIndex = 4;
|
||||
if (subID == 12 && shape == 2) altIndex = 5;
|
||||
if (subID == 12 && shape == 3) altIndex = 6;
|
||||
|
||||
if (altIndex == -1)
|
||||
for (int i = 0; i < 4; i++)
|
||||
IOStr[i] = IONAMES[IOARRAY[subID][i]];
|
||||
else
|
||||
for (int i = 0; i < 4; i++)
|
||||
IOStr[i] = IONAMES[IOARRAYALTER[altIndex][i]];
|
||||
} else {
|
||||
for (int i = 0; i < 4; i++)
|
||||
IOStr[i] = IONAMES[IOARRAY[subID][i]];
|
||||
|
||||
}
|
||||
for (int i = 0; i < 4; i++)
|
||||
IOStr[i] = IONAMES[IOARRAY[subID][i]];
|
||||
|
||||
String[] IOStrRot = new String[4];
|
||||
|
||||
@@ -132,6 +118,7 @@ public class HUDDecoratorRsGateLogic implements IWailaFMPDecorator {
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
|
||||
}
|
||||
|
||||
double x = accessor.getRenderingPosition().xCoord;
|
||||
@@ -0,0 +1,105 @@
|
||||
package mcp.mobius.waila.addons.projectred;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.nbt.NBTTagList;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
|
||||
public class HUDHandlerRsGateLogic implements IWailaDataProvider {
|
||||
|
||||
@Override
|
||||
public ItemStack getWailaStack(IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getWailaHead(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getWailaBody(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
if (!config.getConfig("pr.showdata")) return currenttip;
|
||||
|
||||
int orient = 0;
|
||||
int subID = 0;
|
||||
int shape = 0;
|
||||
int pmax = 0;
|
||||
int val = 0;
|
||||
int max = 0;
|
||||
int dec = 0;
|
||||
int inc = 0;
|
||||
|
||||
boolean found = false;
|
||||
|
||||
if (!accessor.getNBTData().hasKey("parts")) return currenttip;
|
||||
NBTTagList parts = accessor.getNBTData().getTagList("parts");
|
||||
for (int i = 0; i < parts.tagCount(); i++){
|
||||
NBTTagCompound subtag = (NBTTagCompound)parts.tagAt(i);
|
||||
String id = subtag.getString("id");
|
||||
|
||||
if (id.equals("pr_sgate") || id.equals("pr_igate") ||
|
||||
id.equals("pr_tgate") || id.equals("pr_bgate") ||
|
||||
id.equals("pr_agate") || id.equals("pr_rgate")){
|
||||
orient = accessor.getNBTInteger(subtag, "orient");
|
||||
subID = accessor.getNBTInteger(subtag, "subID");
|
||||
shape = accessor.getNBTInteger(subtag, "shape");
|
||||
|
||||
if (subID == 17)
|
||||
pmax = accessor.getNBTInteger(subtag, "pmax");
|
||||
|
||||
if (subID == 19){
|
||||
val = accessor.getNBTInteger(subtag, "val");
|
||||
max = accessor.getNBTInteger(subtag, "max");
|
||||
dec = accessor.getNBTInteger(subtag, "dec");
|
||||
inc = accessor.getNBTInteger(subtag, "inc");
|
||||
}
|
||||
|
||||
|
||||
found = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (!found) return currenttip;
|
||||
|
||||
switch(subID){
|
||||
case 10:
|
||||
currenttip.add(String.format("Delay : \u00a7f%d ticks", (int)Math.pow(2, shape)));
|
||||
break;
|
||||
|
||||
case 15:
|
||||
if (shape == 0)
|
||||
currenttip.add("Shape : \u00a7fOpen");
|
||||
if (shape == 1)
|
||||
currenttip.add("Shape : \u00a7fHalf closed");
|
||||
if (shape == 2)
|
||||
currenttip.add("Shape : \u00a7fclosed");
|
||||
break;
|
||||
|
||||
case 17:
|
||||
currenttip.add(String.format("Timer : \u00a7f%d \u00a7rms", (pmax + 2) * 50));
|
||||
break;
|
||||
|
||||
case 19:
|
||||
|
||||
|
||||
currenttip.add(String.format("Value : \u00a7f%d \u00a7r/ \u00a7f%d", val, max));
|
||||
currenttip.add(String.format("Step : \u00a7f-%d \u00a7r/ \u00a7f+%d", dec, inc));
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getWailaTail(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,51 @@
|
||||
package mcp.mobius.waila.addons.projectred;
|
||||
|
||||
import java.io.File;
|
||||
import java.util.logging.Level;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraftforge.common.Configuration;
|
||||
import mcp.mobius.waila.mod_Waila;
|
||||
import mcp.mobius.waila.addons.ExternalModulesHandler;
|
||||
|
||||
public class ProjectRedModule {
|
||||
|
||||
|
||||
public static Class BlockMultipart = null;
|
||||
|
||||
public static void register(){
|
||||
try{
|
||||
Class ModClass = Class.forName("mrtjp.projectred.ProjectRedIntegration");
|
||||
mod_Waila.log.log(Level.INFO, "ProjectRed|Integration mod found.");
|
||||
} catch (ClassNotFoundException e){
|
||||
mod_Waila.log.log(Level.INFO, "[ProjectRed] ProjectRed|Integration mod not found.");
|
||||
return;
|
||||
}
|
||||
|
||||
try{
|
||||
|
||||
//InstancedRsGateLogic = Class.forName("mrtjp.projectred.integration.InstancedRsGateLogic");
|
||||
BlockMultipart = Class.forName("codechicken.multipart.BlockMultipart");
|
||||
|
||||
} catch (ClassNotFoundException e){
|
||||
mod_Waila.log.log(Level.WARNING, "[EnderStorage] Class not found. " + e);
|
||||
return;
|
||||
// } catch (NoSuchMethodException e){
|
||||
// mod_Waila.log.log(Level.WARNING, "[EnderStorage] Method not found." + e);
|
||||
// return;
|
||||
// } catch (NoSuchFieldException e){
|
||||
// mod_Waila.log.log(Level.WARNING, "[EnderStorage] Field not found." + e);
|
||||
// return;
|
||||
} catch (Exception e){
|
||||
mod_Waila.log.log(Level.WARNING, "[EnderStorage] Unhandled exception." + e);
|
||||
return;
|
||||
}
|
||||
|
||||
ExternalModulesHandler.instance().addConfigRemote("Project:Red", "pr.showio");
|
||||
ExternalModulesHandler.instance().addConfigRemote("Project:Red", "pr.showdata");
|
||||
|
||||
ExternalModulesHandler.instance().registerBlockDecorator(new HUDDecoratorRsGateLogic(), BlockMultipart);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerRsGateLogic(), BlockMultipart);
|
||||
}
|
||||
|
||||
}
|
||||
+15
-16
@@ -1,15 +1,14 @@
|
||||
package mcp.mobius.waila.addons.harvestcraft;
|
||||
package mcp.mobius.waila.addons.thaumcraft;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import mcp.mobius.waila.cbcore.LangUtil;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import mcp.mobius.waila.WailaExceptionHandler;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
import mcp.mobius.waila.utils.NBTUtil;
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
||||
public class HUDHandlerPamCrop implements IWailaDataProvider {
|
||||
public class HUDHandlerCapacitor implements IWailaDataProvider {
|
||||
|
||||
@Override
|
||||
public ItemStack getWailaStack(IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
@@ -23,22 +22,22 @@ public class HUDHandlerPamCrop implements IWailaDataProvider {
|
||||
|
||||
@Override
|
||||
public List<String> getWailaBody(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
if (!config.getConfig("general.showcrop")) return currenttip;
|
||||
if (config.getConfig("thaumcraft.storedvis")){
|
||||
try{
|
||||
short storedVis = ThaumcraftModule.TileCrystalCapacitor_StoredVis.getShort(accessor.getTileEntity());
|
||||
short maxVis = ThaumcraftModule.TileCrystalCapacitor_MaxVis.getShort(accessor.getTileEntity());
|
||||
|
||||
int growthStage = NBTUtil.getNBTInteger(accessor.getNBTData(), "growthStage");
|
||||
|
||||
float growthValue = (growthStage / 2.0F) * 100.0F;
|
||||
if (growthValue < 100.0)
|
||||
currenttip.add(String.format("%s : %.0f %%", LangUtil.translateG("hud.msg.growth"), growthValue));
|
||||
else
|
||||
currenttip.add(String.format("%s : %s", LangUtil.translateG("hud.msg.growth"), LangUtil.translateG("hud.msg.mature")));
|
||||
currenttip.add(String.format("%s/%s vis", storedVis, maxVis));
|
||||
}catch (Exception e){
|
||||
currenttip = WailaExceptionHandler.handleErr(e, accessor.getClass().getName(), currenttip);
|
||||
}
|
||||
}
|
||||
return currenttip;
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getWailaTail(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
+5
-16
@@ -1,42 +1,31 @@
|
||||
package mcp.mobius.waila.addons.agriculture;
|
||||
package mcp.mobius.waila.addons.thaumcraft;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import mcp.mobius.waila.cbcore.LangUtil;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
|
||||
public class HUDHandlerCrop implements IWailaDataProvider {
|
||||
public class HUDHandlerLeaves implements IWailaDataProvider {
|
||||
|
||||
@Override
|
||||
public ItemStack getWailaStack(IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
return null;
|
||||
return new ItemStack(accessor.getBlock(), 0, accessor.getMetadata());
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getWailaHead(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
return currenttip;
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getWailaBody(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
if (!config.getConfig("general.showcrop")) return currenttip;
|
||||
|
||||
int growthStage = accessor.getMetadata();
|
||||
|
||||
float growthValue = (growthStage / 6.0F) * 100.0F;
|
||||
if (growthValue < 100.0)
|
||||
currenttip.add(String.format("%s : %.0f %%", LangUtil.translateG("hud.msg.growth"), growthValue));
|
||||
else
|
||||
currenttip.add(String.format("%s : %s", LangUtil.translateG("hud.msg.growth"), LangUtil.translateG("hud.msg.mature")));
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getWailaTail(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,30 @@
|
||||
package mcp.mobius.waila.addons.thaumcraft;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.item.ItemStack;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
|
||||
public class HUDHandlerPlants implements IWailaDataProvider {
|
||||
@Override
|
||||
public ItemStack getWailaStack(IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
return new ItemStack(accessor.getBlock(), 0, accessor.getMetadata());
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getWailaHead(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getWailaBody(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getWailaTail(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
return currenttip;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,57 @@
|
||||
package mcp.mobius.waila.addons.thaumcraft;
|
||||
|
||||
import java.lang.reflect.Field;
|
||||
import java.util.logging.Level;
|
||||
|
||||
import mcp.mobius.waila.mod_Waila;
|
||||
import mcp.mobius.waila.addons.ExternalModulesHandler;
|
||||
|
||||
public class ThaumcraftModule {
|
||||
|
||||
public static Class BlockMagicalLeaves = null;
|
||||
public static Class BlockCustomPlant = null;
|
||||
|
||||
public static Class TileCrystalCapacitor = null;
|
||||
public static Field TileCrystalCapacitor_StoredVis = null;
|
||||
public static Field TileCrystalCapacitor_MaxVis = null;
|
||||
|
||||
public static void register(){
|
||||
|
||||
try{
|
||||
Class ModThaumcraft = Class.forName("thaumcraft.common.Thaumcraft");
|
||||
mod_Waila.log.log(Level.INFO, "Thaumcraft mod found.");
|
||||
} catch (ClassNotFoundException e){
|
||||
mod_Waila.log.log(Level.INFO, "[Thaumcraft] Thaumcraft mod not found.");
|
||||
return;
|
||||
}
|
||||
|
||||
try{
|
||||
BlockMagicalLeaves = Class.forName("thaumcraft.common.world.BlockMagicalLeaves");
|
||||
BlockCustomPlant = Class.forName("thaumcraft.common.world.BlockCustomPlant");
|
||||
|
||||
TileCrystalCapacitor = Class.forName("thaumcraft.common.tiles.TileCrystalCapacitor");
|
||||
TileCrystalCapacitor_StoredVis = TileCrystalCapacitor.getField("storedVis");
|
||||
TileCrystalCapacitor_MaxVis = TileCrystalCapacitor.getField("maxVis");
|
||||
|
||||
|
||||
} catch (ClassNotFoundException e){
|
||||
mod_Waila.log.log(Level.WARNING, "[Thaumcraft] Class not found. " + e);
|
||||
return;
|
||||
// } catch (NoSuchMethodException e){
|
||||
// mod_Waila.log.log(Level.WARNING, "[Thaumcraft] Method not found." + e);
|
||||
// return;
|
||||
} catch (NoSuchFieldException e){
|
||||
mod_Waila.log.log(Level.WARNING, "[Thaumcraft] Field not found." + e);
|
||||
return;
|
||||
// } catch (Exception e){
|
||||
// mod_Waila.log.log(Level.WARNING, "[Thaumcraft] Unhandled exception." + e);
|
||||
// return;
|
||||
}
|
||||
ExternalModulesHandler.instance().addConfig("Thaumcraft", "thaumcraft.storedvis");
|
||||
ExternalModulesHandler.instance().registerStackProvider(new HUDHandlerLeaves(), BlockMagicalLeaves);
|
||||
ExternalModulesHandler.instance().registerStackProvider(new HUDHandlerPlants(), BlockCustomPlant);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerCapacitor(), TileCrystalCapacitor);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
+17
-28
@@ -2,15 +2,13 @@ package mcp.mobius.waila.addons.thermalexpansion;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import mcp.mobius.waila.cbcore.LangUtil;
|
||||
import codechicken.lib.lang.LangUtil;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.nbt.NBTTagList;
|
||||
import net.minecraftforge.fluids.FluidStack;
|
||||
import mcp.mobius.waila.WailaExceptionHandler;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
import mcp.mobius.waila.utils.WailaExceptionHandler;
|
||||
|
||||
public class HUDHandlerConduitFluid implements IWailaDataProvider {
|
||||
|
||||
@@ -26,32 +24,23 @@ public class HUDHandlerConduitFluid implements IWailaDataProvider {
|
||||
|
||||
@Override
|
||||
public List<String> getWailaBody(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
/*
|
||||
if (!config.getConfig("thermalexpansion.fluidtype")) return currenttip;
|
||||
|
||||
boolean found = false;
|
||||
FluidStack fluid = null;
|
||||
|
||||
if (!accessor.getNBTData().hasKey("parts")) return currenttip;
|
||||
NBTTagList parts = accessor.getNBTData().getTagList("parts");
|
||||
for (int i = 0; i < parts.tagCount(); i++){
|
||||
NBTTagCompound subtag = (NBTTagCompound)parts.tagAt(i);
|
||||
String id = subtag.getString("id");
|
||||
|
||||
if (id.contains("ConduitFluid")){
|
||||
found = true;
|
||||
NBTTagCompound fluidTag = subtag.getCompoundTag("ConnFluid");
|
||||
fluid = FluidStack.loadFluidStackFromNBT(fluidTag);
|
||||
}
|
||||
}
|
||||
|
||||
if (!found) return currenttip;
|
||||
if (config.getConfig("thermalexpansion.fluidtype")){
|
||||
|
||||
if (fluid != null)
|
||||
currenttip.add(fluid.getFluid().getLocalizedName());
|
||||
else
|
||||
currenttip.add(LangUtil.translateG("hud.msg.empty"));
|
||||
*/
|
||||
try {
|
||||
FluidStack fluid = (FluidStack)ThermalExpansionModule.TileConduitFluid_getRenderFluid.invoke(accessor.getTileEntity());
|
||||
|
||||
try{
|
||||
currenttip.add(fluid.getFluid().getLocalizedName());
|
||||
} catch (NullPointerException f){
|
||||
currenttip.add(LangUtil.translateG("hud.msg.empty"));
|
||||
}
|
||||
|
||||
} catch (Exception e){
|
||||
currenttip = WailaExceptionHandler.handleErr(e, accessor.getTileEntity().getClass().getName(), currenttip);
|
||||
}
|
||||
|
||||
}
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
+14
-11
@@ -1,14 +1,13 @@
|
||||
package mcp.mobius.waila.addons.magicalcrops;
|
||||
package mcp.mobius.waila.addons.thermalexpansion;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import mcp.mobius.waila.cbcore.LangUtil;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
|
||||
public class HUDHandlerMagicalCrops implements IWailaDataProvider {
|
||||
public class HUDHandlerConduitItem implements IWailaDataProvider {
|
||||
|
||||
@Override
|
||||
public ItemStack getWailaStack(IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
@@ -22,15 +21,19 @@ public class HUDHandlerMagicalCrops implements IWailaDataProvider {
|
||||
|
||||
@Override
|
||||
public List<String> getWailaBody(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
if (!config.getConfig("general.showcrop")) return currenttip;
|
||||
|
||||
int growthStage = accessor.getMetadata();
|
||||
|
||||
float growthValue = (growthStage / 7.0F) * 100.0F;
|
||||
if (growthValue < 100.0)
|
||||
currenttip.add(String.format("%s : %.0f %%", LangUtil.translateG("hud.msg.growth"), growthValue));
|
||||
else
|
||||
currenttip.add(String.format("%s : %s", LangUtil.translateG("hud.msg.growth"), LangUtil.translateG("hud.msg.mature")));
|
||||
if (accessor.getNBTData().hasKey("Mode") && accessor.getNBTInteger(accessor.getNBTData(), "Mode") != 0){
|
||||
int mode = accessor.getNBTInteger(accessor.getNBTData(), "Mode");
|
||||
|
||||
if (mode == 1)
|
||||
currenttip.add("Mode : \u00a7fDense");
|
||||
else if (mode == 2)
|
||||
currenttip.add("Mode : \u00a7fVacuum");
|
||||
else if (mode == 3)
|
||||
currenttip.add("Mode : \u00a7fRound-Robin");
|
||||
else
|
||||
currenttip.add("Mode : <UNKNOWN>");
|
||||
}
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
+2
-2
@@ -2,12 +2,12 @@ package mcp.mobius.waila.addons.thermalexpansion;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import mcp.mobius.waila.cbcore.LangUtil;
|
||||
import codechicken.lib.lang.LangUtil;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import mcp.mobius.waila.WailaExceptionHandler;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
import mcp.mobius.waila.utils.WailaExceptionHandler;
|
||||
|
||||
public class HUDHandlerEnergyCell implements IWailaDataProvider {
|
||||
|
||||
+2
-2
@@ -4,11 +4,11 @@ import java.lang.reflect.InvocationTargetException;
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import mcp.mobius.waila.WailaExceptionHandler;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
import mcp.mobius.waila.utils.WailaExceptionHandler;
|
||||
|
||||
public class HUDHandlerIEnergyHandler implements IWailaDataProvider {
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@ package mcp.mobius.waila.addons.thermalexpansion;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import mcp.mobius.waila.cbcore.LangUtil;
|
||||
import codechicken.lib.lang.LangUtil;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
+2
-2
@@ -3,13 +3,13 @@ package mcp.mobius.waila.addons.thermalexpansion;
|
||||
import java.lang.reflect.InvocationTargetException;
|
||||
import java.util.List;
|
||||
|
||||
import mcp.mobius.waila.cbcore.LangUtil;
|
||||
import codechicken.lib.lang.LangUtil;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraftforge.fluids.FluidStack;
|
||||
import mcp.mobius.waila.WailaExceptionHandler;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
import mcp.mobius.waila.utils.WailaExceptionHandler;
|
||||
|
||||
public class HUDHandlerTank implements IWailaDataProvider {
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@ package mcp.mobius.waila.addons.thermalexpansion;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import mcp.mobius.waila.cbcore.LangUtil;
|
||||
import codechicken.lib.lang.LangUtil;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
@@ -0,0 +1,125 @@
|
||||
package mcp.mobius.waila.addons.thermalexpansion;
|
||||
|
||||
import java.lang.reflect.Field;
|
||||
import java.lang.reflect.Method;
|
||||
import java.util.logging.Level;
|
||||
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import mcp.mobius.waila.mod_Waila;
|
||||
import mcp.mobius.waila.addons.ExternalModulesHandler;
|
||||
|
||||
public class ThermalExpansionModule {
|
||||
|
||||
public static Class IEnergyHandler = null;
|
||||
public static Method IEnergyHandler_getMaxStorage = null;
|
||||
|
||||
public static Class TileEnergyCell = null;
|
||||
|
||||
public static Class TileTank = null;
|
||||
public static Method TileTank_getTankFluid = null;
|
||||
public static Method TileTank_getTankCapacity = null;
|
||||
public static Field TileTank_mode = null;
|
||||
|
||||
public static Class TileConduitFluid = null;
|
||||
public static Method TileConduitFluid_getRenderFluid = null;
|
||||
public static Method TileConduitFluid_getRenderFluidLevel = null;
|
||||
|
||||
public static Class TileConduitItems = null;
|
||||
|
||||
public static Class TileTesseract = null;
|
||||
|
||||
public static Class ISecureTile = null;
|
||||
|
||||
//public static Field TileTesseract_modItem = null;
|
||||
//public static Field TileTesseract_modFluid = null;
|
||||
//public static Field TileTesseract_modEnergy = null;
|
||||
|
||||
|
||||
//public static Class TileConduitBase = null;
|
||||
//public static Field TileConduitBase_isInput = null;
|
||||
//public static Field TileConduitBase_isOutput = null;
|
||||
|
||||
public static void register(){
|
||||
|
||||
try{
|
||||
Class ModThermalExpansion = Class.forName("thermalexpansion.ThermalExpansion");
|
||||
mod_Waila.log.log(Level.INFO, "Thermal Expansion mod found.");
|
||||
} catch (ClassNotFoundException e){
|
||||
mod_Waila.log.log(Level.INFO, "[Thermal Expansion] ThermalExpansion mod not found.");
|
||||
return;
|
||||
}
|
||||
|
||||
try{
|
||||
IEnergyHandler = Class.forName("cofh.api.energy.IEnergyHandler");
|
||||
IEnergyHandler_getMaxStorage = IEnergyHandler.getMethod("getMaxEnergyStored", ForgeDirection.class);
|
||||
TileEnergyCell = Class.forName("thermalexpansion.block.energycell.TileEnergyCell");
|
||||
|
||||
TileTank = Class.forName("thermalexpansion.block.tank.TileTank");
|
||||
TileTank_getTankFluid = TileTank.getMethod("getTankFluid");
|
||||
TileTank_getTankCapacity = TileTank.getMethod("getTankCapacity");
|
||||
TileTank_mode = TileTank.getField("mode");
|
||||
|
||||
TileConduitFluid = Class.forName("thermalexpansion.block.conduit.fluid.TileConduitFluid");
|
||||
TileConduitFluid_getRenderFluid = TileConduitFluid.getMethod("getRenderFluid");
|
||||
TileConduitFluid_getRenderFluidLevel = TileConduitFluid.getMethod("getRenderFluidLevel");
|
||||
|
||||
TileConduitItems = Class.forName("thermalexpansion.block.conduit.item.TileConduitItem");
|
||||
|
||||
TileTesseract = Class.forName("thermalexpansion.block.tesseract.TileTesseract");
|
||||
|
||||
ISecureTile = Class.forName("cofh.api.tileentity.ISecureTile");
|
||||
|
||||
//TileTesseract_modItem = TileTesseract.getField("modItem");
|
||||
//TileTesseract_modFluid = TileTesseract.getField("modFluid");
|
||||
//TileTesseract_modEnergy = TileTesseract.getField("modEnergy");
|
||||
|
||||
//TileConduitBase = Class.forName("thermalexpansion.block.conduit.TileConduitBase");
|
||||
//TileConduitBase_isInput = TileConduitBase.getField("isInput");
|
||||
//TileConduitBase_isOutput = TileConduitBase.getField("isOutput");
|
||||
|
||||
//TileEnergyCell_energyReceive = TileEnergyCell.getField("energyReceive");
|
||||
//TileEnergyCell_energySend = TileEnergyCell.getField("energySend");
|
||||
|
||||
} catch (ClassNotFoundException e){
|
||||
mod_Waila.log.log(Level.WARNING, "[Thermal Expansion] Class not found. " + e);
|
||||
return;
|
||||
} catch (NoSuchMethodException e){
|
||||
mod_Waila.log.log(Level.WARNING, "[Thermal Expansion] Method not found." + e);
|
||||
return;
|
||||
} catch (NoSuchFieldException e){
|
||||
mod_Waila.log.log(Level.WARNING, "[Thermal Expansion] Field not found." + e);
|
||||
return;
|
||||
// } catch (Exception e){
|
||||
// mod_Waila.log.log(Level.WARNING, "[Thermal Expansion] Unhandled exception." + e);
|
||||
// return;
|
||||
}
|
||||
|
||||
ExternalModulesHandler.instance().addConfigRemote("Thermal Expansion", "thermalexpansion.energyhandler");
|
||||
ExternalModulesHandler.instance().addConfigRemote("Thermal Expansion", "thermalexpansion.energycell");
|
||||
ExternalModulesHandler.instance().addConfig("Thermal Expansion", "thermalexpansion.fluidtype");
|
||||
ExternalModulesHandler.instance().addConfigRemote("Thermal Expansion", "thermalexpansion.fluidamount");
|
||||
ExternalModulesHandler.instance().addConfigRemote("Thermal Expansion", "thermalexpansion.conditemmode");
|
||||
ExternalModulesHandler.instance().addConfig("Thermal Expansion", "thermalexpansion.tankmode");
|
||||
ExternalModulesHandler.instance().addConfigRemote("Thermal Expansion", "thermalexpansion.tesssendrecv");
|
||||
ExternalModulesHandler.instance().addConfigRemote("Thermal Expansion", "thermalexpansion.tessfreq");
|
||||
ExternalModulesHandler.instance().addConfigRemote("Thermal Expansion", "thermalexpansion.owner");
|
||||
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerIEnergyHandler(), IEnergyHandler);
|
||||
//ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerIEnergyHandler(), TileEnergyCell);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerEnergyCell(), TileEnergyCell);
|
||||
ExternalModulesHandler.instance().registerHeadProvider(new HUDHandlerTank(), TileTank);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerTank(), TileTank);
|
||||
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerConduitFluid(), TileConduitFluid);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerTesseract(), TileTesseract);
|
||||
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerConduitItem(), TileConduitItems);
|
||||
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerISecureTile(), ISecureTile);
|
||||
|
||||
//ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerConduitBase(), TileConduitBase);
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
File renamed without changes.
+8
-11
@@ -2,8 +2,8 @@ package mcp.mobius.waila.addons.twilightforest;
|
||||
|
||||
import java.util.logging.Level;
|
||||
|
||||
import mcp.mobius.waila.Waila;
|
||||
import mcp.mobius.waila.api.impl.ModuleRegistrar;
|
||||
import mcp.mobius.waila.mod_Waila;
|
||||
import mcp.mobius.waila.addons.ExternalModulesHandler;
|
||||
|
||||
public class TwilightForestModule {
|
||||
|
||||
@@ -15,9 +15,9 @@ public class TwilightForestModule {
|
||||
|
||||
try{
|
||||
Class TwilightForestMod = Class.forName("twilightforest.TwilightForestMod");
|
||||
Waila.log.log(Level.INFO, "TwilightForestMod mod found.");
|
||||
mod_Waila.log.log(Level.INFO, "TwilightForestMod mod found.");
|
||||
} catch (ClassNotFoundException e){
|
||||
Waila.log.log(Level.INFO, "[TwilightForestMod] TwilightForestMod mod not found.");
|
||||
mod_Waila.log.log(Level.INFO, "[TwilightForestMod] TwilightForestMod mod not found.");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -26,16 +26,13 @@ public class TwilightForestModule {
|
||||
BlockTFPlant = Class.forName("twilightforest.block.BlockTFPlant");
|
||||
BlockTFSapling = Class.forName("twilightforest.block.BlockTFSapling");
|
||||
} catch (ClassNotFoundException e) {
|
||||
Waila.log.log(Level.WARNING, "[TwilightForestMod] Class not found. " + e);
|
||||
mod_Waila.log.log(Level.WARNING, "[TwilightForestMod] Class not found. " + e);
|
||||
}
|
||||
|
||||
|
||||
ModuleRegistrar.instance().registerStackProvider(new TwilightForestGenericOverride(), BlockTFRoots);
|
||||
ModuleRegistrar.instance().registerStackProvider(new TwilightForestGenericOverride(), BlockTFPlant);
|
||||
//ExternalModulesHandler.instance().registerStackProvider(new TwilightForestGenericOverride(), BlockTFSapling);
|
||||
|
||||
ModuleRegistrar.instance().registerSyncedNBTKey("*", BlockTFRoots);
|
||||
ModuleRegistrar.instance().registerSyncedNBTKey("*", BlockTFPlant);
|
||||
ExternalModulesHandler.instance().registerStackProvider(new TwilightForestGenericOverride(), BlockTFRoots);
|
||||
ExternalModulesHandler.instance().registerStackProvider(new TwilightForestGenericOverride(), BlockTFPlant);
|
||||
//ExternalModulesHandler.instance().registerStackProvider(new TwilightForestGenericOverride(), BlockTFSapling);
|
||||
}
|
||||
|
||||
}
|
||||
File renamed without changes.
@@ -0,0 +1,177 @@
|
||||
package mcp.mobius.waila.addons.vanillamc;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import codechicken.lib.lang.LangUtil;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemRecord;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.tileentity.TileEntityMobSpawner;
|
||||
import mcp.mobius.waila.addons.ExternalModulesHandler;
|
||||
import mcp.mobius.waila.api.IWailaConfigHandler;
|
||||
import mcp.mobius.waila.api.IWailaDataAccessor;
|
||||
import mcp.mobius.waila.api.IWailaDataProvider;
|
||||
|
||||
public class HUDHandlerVanilla implements IWailaDataProvider {
|
||||
|
||||
static int mobSpawnerID = Block.mobSpawner.blockID;
|
||||
static int cropsID = Block.crops.blockID;
|
||||
static int melonStemID = Block.melonStem.blockID;
|
||||
static int pumpkinStemID = Block.pumpkinStem.blockID;
|
||||
static int carrotID = Block.carrot.blockID;
|
||||
static int potatoID = Block.potato.blockID;
|
||||
static int leverID = Block.lever.blockID;
|
||||
static int repeaterIdle = Block.redstoneRepeaterIdle.blockID;
|
||||
static int repeaterActv = Block.redstoneRepeaterActive.blockID;
|
||||
static int comparatorIdl = Block.redstoneComparatorIdle.blockID;
|
||||
static int comparatorAct = Block.redstoneComparatorActive.blockID;
|
||||
static int redstone = Block.redstoneWire.blockID;
|
||||
static int jukebox = Block.jukebox.blockID;
|
||||
static int cocoa = Block.cocoaPlant.blockID;
|
||||
static int netherwart = Block.netherStalk.blockID;
|
||||
|
||||
|
||||
@Override
|
||||
public ItemStack getWailaStack(IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getWailaHead(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
int blockID = accessor.getBlockID();
|
||||
|
||||
/* Mob spawner handler */
|
||||
if (blockID == mobSpawnerID && accessor.getTileEntity() instanceof TileEntityMobSpawner && config.getConfig("vanilla.spawntype")){
|
||||
String name = currenttip.get(0);
|
||||
String mobname = ((TileEntityMobSpawner)accessor.getTileEntity()).getSpawnerLogic().getEntityNameToSpawn();
|
||||
currenttip.set(0, String.format("%s (%s)", name, mobname));
|
||||
}
|
||||
|
||||
if (blockID == redstone){
|
||||
String name = currenttip.get(0).replaceFirst(String.format(" %s", accessor.getMetadata()), "");
|
||||
currenttip.set(0, name);
|
||||
}
|
||||
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getWailaBody(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
int blockID = accessor.getBlockID();
|
||||
/* Crops */
|
||||
if (config.getConfig("vanilla.growthvalue"))
|
||||
if (blockID == cropsID || blockID == melonStemID || blockID == pumpkinStemID || blockID == carrotID || blockID == potatoID){
|
||||
float growthValue = (accessor.getMetadata() / 7.0F) * 100.0F;
|
||||
if (growthValue < 100.0)
|
||||
currenttip.add(String.format("%s : %.0f %%", LangUtil.translateG("hud.msg.growth"), growthValue));
|
||||
else
|
||||
currenttip.add(String.format("%s : %s", LangUtil.translateG("hud.msg.growth"), LangUtil.translateG("hud.msg.mature")));
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
if (blockID == cocoa){
|
||||
|
||||
float growthValue = ((accessor.getMetadata() >> 2) / 2.0F) * 100.0F;
|
||||
if (growthValue < 100.0)
|
||||
currenttip.add(String.format("%s : %.0f %%", LangUtil.translateG("hud.msg.growth"), growthValue));
|
||||
else
|
||||
currenttip.add(String.format("%s : %s", LangUtil.translateG("hud.msg.growth"), LangUtil.translateG("hud.msg.mature")));
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
if (blockID == netherwart){
|
||||
float growthValue = (accessor.getMetadata() / 3.0F) * 100.0F;
|
||||
if (growthValue < 100.0)
|
||||
currenttip.add(String.format("%s : %.0f %%", LangUtil.translateG("hud.msg.growth"), growthValue));
|
||||
else
|
||||
currenttip.add(String.format("%s : %s", LangUtil.translateG("hud.msg.growth"), LangUtil.translateG("hud.msg.mature")));
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
if (config.getConfig("vanilla.leverstate"))
|
||||
if (blockID == leverID){
|
||||
String redstoneOn = (accessor.getMetadata() & 8) == 0 ? LangUtil.translateG("hud.msg.off") : LangUtil.translateG("hud.msg.on");
|
||||
currenttip.add(String.format("%s : %s", LangUtil.translateG("hud.msg.state"), redstoneOn));
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
if (config.getConfig("vanilla.repeater"))
|
||||
if ((blockID == repeaterIdle) ||(blockID == repeaterActv)){
|
||||
int tick = (accessor.getMetadata() >> 2) + 1 ;
|
||||
if (tick == 1)
|
||||
currenttip.add(String.format("%s : %s tick", LangUtil.translateG("hud.msg.delay"), tick));
|
||||
else
|
||||
currenttip.add(String.format("%s : %s ticks", LangUtil.translateG("hud.msg.delay"), tick));
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
if (config.getConfig("vanilla.comparator"))
|
||||
if ((blockID == comparatorIdl) ||(blockID == comparatorAct)){
|
||||
String mode = ((accessor.getMetadata() >> 2) & 1) == 0 ? LangUtil.translateG("hud.msg.comparator") : LangUtil.translateG("hud.msg.substractor");
|
||||
//int outputSignal = ((TileEntityComparator)entity).func_96100_a();
|
||||
currenttip.add("Mode : " + mode);
|
||||
//currenttip.add(String.format("Out : %s", outputSignal));
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
if (config.getConfig("vanilla.redstone"))
|
||||
if (blockID == redstone){
|
||||
currenttip.add(String.format("%s : %s" , LangUtil.translateG("hud.msg.power"), accessor.getMetadata()));
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
if (config.getConfig("vanilla.jukebox"))
|
||||
if (blockID == jukebox){
|
||||
NBTTagCompound tag = accessor.getNBTData();
|
||||
Item record = null;
|
||||
if (tag.hasKey("Record")){
|
||||
record = Item.itemsList[accessor.getNBTInteger(tag, "Record")];
|
||||
currenttip.add(((ItemRecord)record).getRecordTitle());
|
||||
} else {
|
||||
currenttip.add(LangUtil.translateG("hud.msg.empty"));
|
||||
}
|
||||
}
|
||||
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getWailaTail(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
public static void register(){
|
||||
ExternalModulesHandler.instance().addConfig("VanillaMC", "vanilla.spawntype");
|
||||
ExternalModulesHandler.instance().addConfig("VanillaMC", "vanilla.growthvalue");
|
||||
ExternalModulesHandler.instance().addConfig("VanillaMC", "vanilla.leverstate");
|
||||
ExternalModulesHandler.instance().addConfig("VanillaMC", "vanilla.repeater");
|
||||
ExternalModulesHandler.instance().addConfig("VanillaMC", "vanilla.comparator");
|
||||
ExternalModulesHandler.instance().addConfig("VanillaMC", "vanilla.redstone");
|
||||
ExternalModulesHandler.instance().addConfigRemote("VanillaMC", "vanilla.jukebox");
|
||||
ExternalModulesHandler.instance().registerHeadProvider(new HUDHandlerVanilla(), mobSpawnerID);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerVanilla(), cropsID);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerVanilla(), melonStemID);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerVanilla(), pumpkinStemID);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerVanilla(), carrotID);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerVanilla(), potatoID);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerVanilla(), leverID);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerVanilla(), repeaterIdle);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerVanilla(), repeaterActv);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerVanilla(), comparatorIdl);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerVanilla(), comparatorAct);
|
||||
ExternalModulesHandler.instance().registerHeadProvider(new HUDHandlerVanilla(), redstone);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerVanilla(), redstone);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerVanilla(), jukebox);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerVanilla(), cocoa);
|
||||
ExternalModulesHandler.instance().registerBodyProvider(new HUDHandlerVanilla(), netherwart);
|
||||
|
||||
ExternalModulesHandler.instance().registerDocTextFile("/mcp/mobius/waila/addons/vanillamc/WikiData.csv");
|
||||
|
||||
//ExternalModulesHandler.instance().registerBlockDecorator(new HUDDecoratorVanilla(), repeaterIdle);
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
File renamed without changes.
File renamed without changes.
File renamed without changes.
-1
@@ -4,7 +4,6 @@ import java.util.List;
|
||||
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
||||
@Deprecated
|
||||
public interface IWailaBlock {
|
||||
/*
|
||||
* Use this method to return an item stack in case the default lookup system fails.
|
||||
+2
@@ -1,5 +1,7 @@
|
||||
package mcp.mobius.waila.api;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
||||
public interface IWailaBlockDecorator {
|
||||
+1
-1
@@ -24,5 +24,5 @@ public interface IWailaConfigHandler {
|
||||
/* Returns the current value of an option (true/false) with a default value true if not set*/
|
||||
public boolean getConfig(String key);
|
||||
|
||||
//public void setConfig(String key, boolean value);
|
||||
public void setConfig(String key, boolean value);
|
||||
}
|
||||
-10
@@ -2,21 +2,13 @@ package mcp.mobius.waila.api;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.MovingObjectPosition;
|
||||
import net.minecraft.util.Vec3;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
|
||||
/* The Accessor is used to get some basic data out of the game without having to request
|
||||
* direct access to the game engine.
|
||||
* It will also return things that are unmodified by the overriding systems (like getWailaStack).
|
||||
*/
|
||||
|
||||
public interface IWailaDataAccessor {
|
||||
|
||||
World getWorld();
|
||||
EntityPlayer getPlayer();
|
||||
Block getBlock();
|
||||
@@ -28,6 +20,4 @@ public interface IWailaDataAccessor {
|
||||
NBTTagCompound getNBTData();
|
||||
int getNBTInteger(NBTTagCompound tag, String keyname);
|
||||
double getPartialFrame();
|
||||
ForgeDirection getSide();
|
||||
ItemStack getStack();
|
||||
}
|
||||
@@ -0,0 +1,4 @@
|
||||
package mcp.mobius.waila.api;
|
||||
|
||||
public interface IWailaDataProvider extends IWailaBlock{
|
||||
}
|
||||
@@ -0,0 +1,31 @@
|
||||
package mcp.mobius.waila.api;
|
||||
|
||||
public interface IWailaRegistrar {
|
||||
/* Add a config option in the section modname with displayed text configtext and access key keyname */
|
||||
public void addConfig(String modname, String keyname, String configtext);
|
||||
public void addConfigRemote(String modname, String keyname, String configtext);
|
||||
public void addConfig(String modname, String keyname);
|
||||
public void addConfigRemote(String modname, String keyname);
|
||||
|
||||
/* Register a IWailaDataProvider for the given blockID, either for the Head section or the Body section */
|
||||
public void registerHeadProvider (IWailaDataProvider dataProvider, int blockID);
|
||||
public void registerBodyProvider (IWailaDataProvider dataProvider, int blockID);
|
||||
public void registerTailProvider (IWailaDataProvider dataProvider, int blockID);
|
||||
|
||||
/* Register a stack overrider for the given blockID */
|
||||
public void registerStackProvider(IWailaDataProvider dataProvider, int blockID);
|
||||
public void registerStackProvider(IWailaDataProvider dataProvider, Class block);
|
||||
|
||||
/* Same thing, but works on a class hierarchy instead */
|
||||
public void registerHeadProvider (IWailaDataProvider dataProvider, Class block);
|
||||
public void registerBodyProvider (IWailaDataProvider dataProvider, Class block);
|
||||
public void registerTailProvider (IWailaDataProvider dataProvider, Class block);
|
||||
|
||||
/* The block decorators */
|
||||
public void registerBlockDecorator (IWailaBlockDecorator decorator, int blockID);
|
||||
public void registerBlockDecorator (IWailaBlockDecorator decorator, Class block);
|
||||
|
||||
public void registerDocTextFile (String filename);
|
||||
|
||||
public void registerShortDataProvider (IWailaSummaryProvider dataProvider, Class item);
|
||||
}
|
||||
File renamed without changes.
@@ -0,0 +1,166 @@
|
||||
package mcp.mobius.waila.client;
|
||||
|
||||
import java.util.EnumSet;
|
||||
import java.util.List;
|
||||
|
||||
import mcp.mobius.waila.Constants;
|
||||
import mcp.mobius.waila.addons.ConfigHandler;
|
||||
import mcp.mobius.waila.gui.screens.config.ScreenConfig;
|
||||
import mcp.mobius.waila.gui.screens.info.ScreenEnchants;
|
||||
import mcp.mobius.waila.handlers.nei.HandlerEnchants;
|
||||
import mcp.mobius.waila.overlay.RayTracing;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.gui.GuiScreen;
|
||||
import net.minecraft.client.gui.inventory.GuiInventory;
|
||||
import net.minecraft.client.settings.KeyBinding;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.EnumMovingObjectType;
|
||||
|
||||
import org.lwjgl.input.Keyboard;
|
||||
|
||||
import codechicken.lib.lang.LangUtil;
|
||||
import codechicken.nei.api.API;
|
||||
import codechicken.nei.forge.GuiContainerManager;
|
||||
import codechicken.nei.recipe.GuiCraftingRecipe;
|
||||
import codechicken.nei.recipe.GuiUsageRecipe;
|
||||
import cpw.mods.fml.client.registry.KeyBindingRegistry.KeyHandler;
|
||||
import cpw.mods.fml.common.TickType;
|
||||
import cpw.mods.fml.common.registry.LanguageRegistry;
|
||||
|
||||
public class ConfigKeyHandler extends KeyHandler {
|
||||
|
||||
static boolean firstInventory = true;
|
||||
|
||||
public ConfigKeyHandler()
|
||||
{
|
||||
super(new KeyBinding[]{
|
||||
new KeyBinding(Constants.BIND_WAILA_CFG, Keyboard.KEY_NUMPAD0),
|
||||
new KeyBinding(Constants.BIND_WAILA_SHOW, Keyboard.KEY_NUMPAD1),
|
||||
new KeyBinding(Constants.BIND_WAILA_LIQUID, Keyboard.KEY_NUMPAD2),
|
||||
new KeyBinding(Constants.BIND_WAILA_RECIPE, Keyboard.KEY_NUMPAD3),
|
||||
new KeyBinding(Constants.BIND_WAILA_USAGE, Keyboard.KEY_NUMPAD4),
|
||||
//new KeyBinding(Constants.BIND_WAILA_TESTING, Keyboard.KEY_NUMPAD9),
|
||||
}, new boolean[]{
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
//false
|
||||
});
|
||||
|
||||
/*
|
||||
LanguageRegistry.instance().addStringLocalization(Constants.BIND_WAILA_CFG, LangUtil.translateG("keybind.configscreen"));
|
||||
LanguageRegistry.instance().addStringLocalization(Constants.BIND_WAILA_SHOW, LangUtil.translateG("keybind.showhide"));
|
||||
LanguageRegistry.instance().addStringLocalization(Constants.BIND_WAILA_LIQUID, LangUtil.translateG("keybind.showliquid"));
|
||||
LanguageRegistry.instance().addStringLocalization(Constants.BIND_WAILA_RECIPE, LangUtil.translateG("keybind.showrecipe"));
|
||||
LanguageRegistry.instance().addStringLocalization(Constants.BIND_WAILA_USAGE, LangUtil.translateG("keybind.showusage"));
|
||||
LanguageRegistry.instance().addStringLocalization(Constants.BIND_WAILA_TESTING, LangUtil.translateG("keybind.testing"));
|
||||
*/
|
||||
//LanguageRegistry.instance().addStringLocalization(Constants.BIND_SCREEN_ENCH, "[Waila] Show enchant screen");
|
||||
//LanguageRegistry.instance().addStringLocalization("key.wailatedump", "[Waila] Dump server TE");
|
||||
|
||||
GuiContainerManager.addInputHandler(new HandlerEnchants());
|
||||
API.addKeyBind(Constants.BIND_SCREEN_ENCH, Keyboard.KEY_I);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void keyDown(EnumSet<TickType> types, KeyBinding kb, boolean tickEnd, boolean isRepeat) {
|
||||
if (!tickEnd) return;
|
||||
Minecraft mc = Minecraft.getMinecraft();
|
||||
if (kb.keyDescription == Constants.BIND_WAILA_CFG){
|
||||
if(mc.currentScreen == null)
|
||||
mc.displayGuiScreen(new ScreenConfig(mc.currentScreen));
|
||||
}
|
||||
|
||||
if (kb.keyDescription == Constants.BIND_WAILA_TESTING){
|
||||
if(mc.currentScreen == null)
|
||||
mc.displayGuiScreen(new ScreenEnchants(mc.currentScreen));
|
||||
}
|
||||
|
||||
if (mc.currentScreen != null)
|
||||
return;
|
||||
|
||||
if (kb.keyDescription == Constants.BIND_WAILA_SHOW && ConfigHandler.instance().getConfig(Constants.CFG_WAILA_MODE)){
|
||||
boolean status = ConfigHandler.instance().getConfig(Constants.CFG_WAILA_SHOW);
|
||||
ConfigHandler.instance().setConfig(Constants.CFG_WAILA_SHOW, !status);
|
||||
}
|
||||
|
||||
else if (kb.keyDescription == Constants.BIND_WAILA_SHOW && !ConfigHandler.instance().getConfig(Constants.CFG_WAILA_MODE)){
|
||||
ConfigHandler.instance().setConfig(Constants.CFG_WAILA_SHOW, true);
|
||||
}
|
||||
|
||||
else if (kb.keyDescription == Constants.BIND_WAILA_LIQUID){
|
||||
boolean status = ConfigHandler.instance().getConfig(Constants.CFG_WAILA_LIQUID);
|
||||
ConfigHandler.instance().setConfig(Constants.CFG_WAILA_LIQUID, !status);
|
||||
}
|
||||
|
||||
else if (kb.keyDescription == Constants.BIND_WAILA_RECIPE){
|
||||
this.openRecipeGUI(true);
|
||||
}
|
||||
|
||||
else if (kb.keyDescription == Constants.BIND_WAILA_USAGE){
|
||||
this.openRecipeGUI(false);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
public void openRecipeGUI(boolean recipe){
|
||||
Minecraft mc = Minecraft.getMinecraft();
|
||||
boolean uiResult;
|
||||
String msg;
|
||||
|
||||
if ((RayTracing.raytracedTarget != null) && (RayTracing.raytracedTarget.typeOfHit == EnumMovingObjectType.TILE)){
|
||||
List<ItemStack> stacks = RayTracing.getIdentifierItems();
|
||||
if (stacks.size() > 0){
|
||||
mc.displayGuiScreen(new GuiInventory(mc.thePlayer));
|
||||
if (firstInventory){
|
||||
try {Thread.sleep(1000);} catch (Exception e){};
|
||||
firstInventory = false;
|
||||
}
|
||||
|
||||
if(recipe)
|
||||
if(!GuiCraftingRecipe.openRecipeGui("item", stacks.get(0).copy())){
|
||||
ItemStack target = stacks.get(0).copy();
|
||||
target.setItemDamage(0);
|
||||
if(!GuiCraftingRecipe.openRecipeGui("item", target)){
|
||||
mc.thePlayer.addChatMessage("\u00a7f\u00a7o" + LangUtil.translateG("client.msg.norecipe"));
|
||||
mc.displayGuiScreen((GuiScreen)null);
|
||||
mc.setIngameFocus();
|
||||
}
|
||||
}
|
||||
|
||||
if(!recipe)
|
||||
if(!GuiUsageRecipe.openRecipeGui("item", stacks.get(0).copy())){
|
||||
ItemStack target = stacks.get(0).copy();
|
||||
target.setItemDamage(0);
|
||||
if(!GuiUsageRecipe.openRecipeGui("item", target)){
|
||||
mc.thePlayer.addChatMessage("\u00a7f\u00a7o" + LangUtil.translateG("client.msg.nousage"));
|
||||
mc.displayGuiScreen((GuiScreen)null);
|
||||
mc.setIngameFocus();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void keyUp(EnumSet<TickType> types, KeyBinding kb, boolean tickEnd) {
|
||||
if (!tickEnd) return;
|
||||
if (kb.keyDescription == Constants.BIND_WAILA_SHOW && !ConfigHandler.instance().getConfig(Constants.CFG_WAILA_MODE)){
|
||||
ConfigHandler.instance().setConfig(Constants.CFG_WAILA_SHOW, false);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public EnumSet<TickType> ticks() {
|
||||
return EnumSet.of(TickType.CLIENT);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getLabel() {
|
||||
return "Waila Config Screen Keybind";
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,124 @@
|
||||
package mcp.mobius.waila.client;
|
||||
|
||||
import mcp.mobius.waila.Constants;
|
||||
import mcp.mobius.waila.addons.ExternalModulesHandler;
|
||||
import mcp.mobius.waila.addons.appeng.AppEngModule;
|
||||
import mcp.mobius.waila.addons.buildcraft.BCModule;
|
||||
import mcp.mobius.waila.addons.buildcraft.BCPowerAPIModule;
|
||||
import mcp.mobius.waila.addons.enderio.EnderIOModule;
|
||||
import mcp.mobius.waila.addons.enderstorage.EnderStorageModule;
|
||||
import mcp.mobius.waila.addons.etb.ETBModule;
|
||||
import mcp.mobius.waila.addons.gravestone.GravestoneModule;
|
||||
import mcp.mobius.waila.addons.ic2.IC2Module;
|
||||
import mcp.mobius.waila.addons.projectred.ProjectRedModule;
|
||||
import mcp.mobius.waila.addons.thaumcraft.ThaumcraftModule;
|
||||
import mcp.mobius.waila.addons.thermalexpansion.ThermalExpansionModule;
|
||||
import mcp.mobius.waila.addons.twilightforest.TwilightForestModule;
|
||||
import mcp.mobius.waila.addons.vanillamc.HUDHandlerVanilla;
|
||||
import mcp.mobius.waila.gui.truetyper.FontLoader;
|
||||
import mcp.mobius.waila.gui.truetyper.TrueTypeFont;
|
||||
import mcp.mobius.waila.handlers.SummaryProviderDefault;
|
||||
import mcp.mobius.waila.handlers.hud.HUDHandlerExternal;
|
||||
import mcp.mobius.waila.handlers.hud.HUDHandlerWaila;
|
||||
import mcp.mobius.waila.handlers.tooltip.TooltipHandlerWaila;
|
||||
import mcp.mobius.waila.overlay.WailaTickHandler;
|
||||
import mcp.mobius.waila.server.ProxyServer;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
|
||||
import org.lwjgl.input.Keyboard;
|
||||
|
||||
import codechicken.lib.lang.LangUtil;
|
||||
import codechicken.nei.NEIClientConfig;
|
||||
import codechicken.nei.api.API;
|
||||
import codechicken.nei.api.ItemInfo;
|
||||
import codechicken.nei.forge.GuiContainerManager;
|
||||
import cpw.mods.fml.client.registry.KeyBindingRegistry;
|
||||
import cpw.mods.fml.common.registry.TickRegistry;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
|
||||
public class ProxyClient extends ProxyServer {
|
||||
|
||||
TrueTypeFont minecraftiaFont;
|
||||
|
||||
//public static LangUtil lang = LangUtil.loadLangDir("waila");
|
||||
|
||||
public ProxyClient() {}
|
||||
|
||||
|
||||
@Override
|
||||
public void registerHandlers(){
|
||||
|
||||
LangUtil.instance.loadLangDir("waila");
|
||||
|
||||
minecraftiaFont = FontLoader.createFont(new ResourceLocation("waila", "fonts/Minecraftia.ttf"), 14, true);
|
||||
|
||||
TickRegistry.registerTickHandler(new WailaTickHandler(), Side.CLIENT);
|
||||
|
||||
GuiContainerManager.addTooltipHandler(new TooltipHandlerWaila());
|
||||
API.registerHighlightHandler(new HUDHandlerExternal(), ItemInfo.Layout.HEADER);
|
||||
API.registerHighlightHandler(new HUDHandlerExternal(), ItemInfo.Layout.BODY);
|
||||
API.registerHighlightHandler(new HUDHandlerWaila(), ItemInfo.Layout.FOOTER);
|
||||
API.registerHighlightHandler(new HUDHandlerWaila(), ItemInfo.Layout.HEADER);
|
||||
|
||||
KeyBindingRegistry.registerKeyBinding(new ConfigKeyHandler());
|
||||
|
||||
// We mute the default keybind for displaying the tooltip
|
||||
NEIClientConfig.getSetting(Constants.BIND_NEI_SHOW).setIntValue(Keyboard.KEY_NONE);
|
||||
NEIClientConfig.getSetting(Constants.CFG_NEI_SHOW).setBooleanValue(false);
|
||||
|
||||
//API.addKeyBind(Constants.BIND_WIKI, "Display wiki", Keyboard.KEY_RSHIFT);
|
||||
//API.addKeyBind(Constants.BIND_TECH, "Display techtree", Keyboard.KEY_RSHIFT);
|
||||
|
||||
ExternalModulesHandler.instance().registerShortDataProvider(new SummaryProviderDefault(), Item.class);
|
||||
|
||||
this.registerMods();
|
||||
}
|
||||
|
||||
public void registerMods(){
|
||||
|
||||
HUDHandlerVanilla.register();
|
||||
|
||||
/*BETTER BARRELS*/
|
||||
//BetterBarrelsModule.register();
|
||||
|
||||
/* BUILDCRAFT */
|
||||
BCModule.register();
|
||||
|
||||
/* INDUSTRIALCRAFT2 */
|
||||
IC2Module.register();
|
||||
|
||||
/*Thaumcraft*/
|
||||
ThaumcraftModule.register();
|
||||
|
||||
/*EnderStorage*/
|
||||
EnderStorageModule.register();
|
||||
|
||||
/*Gravestone*/
|
||||
GravestoneModule.register();
|
||||
|
||||
/*Twilight forest*/
|
||||
TwilightForestModule.register();
|
||||
|
||||
/* Applied Energetics */
|
||||
AppEngModule.register();
|
||||
|
||||
/* Thermal Expansion */
|
||||
ThermalExpansionModule.register();
|
||||
|
||||
/* ETB */
|
||||
ETBModule.register();
|
||||
|
||||
/* EnderIO */
|
||||
EnderIOModule.register();
|
||||
|
||||
/* Buildcraft Power API */
|
||||
BCPowerAPIModule.register();
|
||||
|
||||
/* ProjectRed API */
|
||||
ProjectRedModule.register();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Object getFont(){return this.minecraftiaFont;}
|
||||
}
|
||||
@@ -0,0 +1,81 @@
|
||||
package mcp.mobius.waila.client;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import mcp.mobius.waila.WailaExceptionHandler;
|
||||
import mcp.mobius.waila.addons.ConfigHandler;
|
||||
import mcp.mobius.waila.addons.ExternalModulesHandler;
|
||||
import mcp.mobius.waila.api.IWailaBlockDecorator;
|
||||
import mcp.mobius.waila.handlers.DataAccessor;
|
||||
import mcp.mobius.waila.overlay.RayTracing;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.renderer.Tessellator;
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.client.event.RenderWorldLastEvent;
|
||||
import net.minecraftforge.event.ForgeSubscribe;
|
||||
|
||||
public class WailaClientEventHandler {
|
||||
|
||||
@ForgeSubscribe
|
||||
@SideOnly(Side.CLIENT)
|
||||
public void onRenderWorldLast(RenderWorldLastEvent event) {
|
||||
if (RayTracing.raytracedTarget == null || RayTracing.raytracedStack == null) return;
|
||||
|
||||
double partialTicks = event.partialTicks;
|
||||
|
||||
DataAccessor accessor = DataAccessor.instance;
|
||||
World world = Minecraft.getMinecraft().theWorld;
|
||||
EntityPlayer player = Minecraft.getMinecraft().thePlayer;
|
||||
EntityLivingBase viewEntity = Minecraft.getMinecraft().renderViewEntity;
|
||||
|
||||
if (world == null || player == null || viewEntity == null) return;
|
||||
|
||||
accessor.set(world, player, RayTracing.raytracedTarget, viewEntity, partialTicks);
|
||||
|
||||
Block block = accessor.getBlock();
|
||||
int blockID = accessor.getBlockID();
|
||||
|
||||
if (!ExternalModulesHandler.instance().hasBlockDecorator(blockID) && !ExternalModulesHandler.instance().hasBlockDecorator(block)) return;
|
||||
|
||||
GL11.glPushAttrib(GL11.GL_COLOR_BUFFER_BIT | GL11.GL_DEPTH_BUFFER_BIT);
|
||||
GL11.glDisable(GL11.GL_TEXTURE_2D);
|
||||
GL11.glEnable(GL11.GL_BLEND);
|
||||
GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
|
||||
GL11.glDepthMask(false);
|
||||
|
||||
if (ExternalModulesHandler.instance().hasBlockDecorator(blockID)){
|
||||
for (IWailaBlockDecorator decorator : ExternalModulesHandler.instance().getBlockDecorators(blockID))
|
||||
try{
|
||||
GL11.glPushMatrix();
|
||||
decorator.decorateBlock(RayTracing.raytracedStack, accessor, ConfigHandler.instance());
|
||||
GL11.glPopMatrix();
|
||||
} catch (Throwable e){
|
||||
GL11.glPopMatrix();
|
||||
WailaExceptionHandler.handleErr(e, decorator.getClass().toString(), null);
|
||||
}
|
||||
}
|
||||
|
||||
if (ExternalModulesHandler.instance().hasBlockDecorator(block)){
|
||||
for (IWailaBlockDecorator decorator : ExternalModulesHandler.instance().getBlockDecorators(block))
|
||||
try{
|
||||
GL11.glPushMatrix();
|
||||
decorator.decorateBlock(RayTracing.raytracedStack, accessor, ConfigHandler.instance());
|
||||
GL11.glPopMatrix();
|
||||
} catch (Throwable e){
|
||||
GL11.glPopMatrix();
|
||||
WailaExceptionHandler.handleErr(e, decorator.getClass().toString(), null);
|
||||
}
|
||||
}
|
||||
|
||||
GL11.glEnable(GL11.GL_TEXTURE_2D);
|
||||
GL11.glPopAttrib();
|
||||
|
||||
}
|
||||
}
|
||||
File renamed without changes.
File renamed without changes.
File renamed without changes.
+13
-44
@@ -59,45 +59,6 @@ public class UIHelper {
|
||||
GL11.glEnable(GL11.GL_TEXTURE_2D);
|
||||
}
|
||||
|
||||
public static void drawBillboard(Vec3 pos, float offX, float offY, float offZ, double x1, double y1, double x2, double y2, int r, int g, int b, int a, double partialFrame){
|
||||
UIHelper.drawBillboard((float)pos.xCoord, (float)pos.yCoord, (float)pos.zCoord, offX, offY, offZ, x1, y1, x2, y2, r, g, b, a, partialFrame);
|
||||
}
|
||||
|
||||
public static void drawBillboard(float posX, float posY, float posZ, float offX, float offY, float offZ, double x1, double y1, double x2, double y2, int r, int g, int b, int a, double partialFrame){
|
||||
EntityLivingBase player = Minecraft.getMinecraft().renderViewEntity;
|
||||
float playerViewY = player.prevRotationYaw + (player.rotationYaw - player.prevRotationYaw) * (float)partialFrame;
|
||||
float playerViewX = player.prevRotationPitch + (player.rotationPitch - player.prevRotationPitch) * (float)partialFrame;
|
||||
|
||||
UIHelper.drawBillboard(posX, posY, posZ, offX, offY, offZ, playerViewX, playerViewY * -1.0F, 0.0F, x1, y1, x2, y2, r, g, b, a);
|
||||
}
|
||||
|
||||
public static void drawBillboard(float posX, float posY, float posZ, float offX, float offY, float offZ, float rotX, float rotY, float rotZ, double x1, double y1, double x2, double y2, int r, int g, int b, int a){
|
||||
float f = 1.6F;
|
||||
float f1 = 0.016666668F * f;
|
||||
GL11.glPushMatrix();
|
||||
|
||||
GL11.glTranslatef(posX + offX, posY + offY, posZ + offZ);
|
||||
|
||||
GL11.glNormal3f(0.0F, 1.0F, 0.0F);
|
||||
GL11.glRotatef(rotY, 0.0F, 1.0F, 0.0F);
|
||||
GL11.glRotatef(rotX, 1.0F, 0.0F, 0.0F);
|
||||
GL11.glRotatef(rotZ, 0.0F, 0.0F, 1.0F);
|
||||
|
||||
//GL11.glScalef(-f1, -f1, f1);
|
||||
GL11.glDisable(GL11.GL_LIGHTING);
|
||||
GL11.glDepthMask(false);
|
||||
GL11.glDisable(GL11.GL_DEPTH_TEST);
|
||||
GL11.glEnable(GL11.GL_BLEND);
|
||||
GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
|
||||
|
||||
//GL11.glDisable(GL11.GL_TEXTURE_2D);
|
||||
drawRectangle(x1, y1, 0, x2, y2, 0, r, g, b, a);
|
||||
|
||||
GL11.glPopMatrix();
|
||||
}
|
||||
|
||||
|
||||
|
||||
public static void drawBillboardText(String text, Vec3 pos, float offX, float offY, float offZ, double partialFrame){
|
||||
UIHelper.drawBillboardText(text, (float)pos.xCoord, (float)pos.yCoord, (float)pos.zCoord, offX, offY, offZ, partialFrame);
|
||||
}
|
||||
@@ -143,9 +104,17 @@ public class UIHelper {
|
||||
GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
|
||||
byte b0 = 0;
|
||||
|
||||
Tessellator tessellator = Tessellator.instance;
|
||||
GL11.glDisable(GL11.GL_TEXTURE_2D);
|
||||
tessellator.startDrawingQuads();
|
||||
int j = fontrenderer.getStringWidth(text) / 2;
|
||||
drawRectangle((double)(-j - 1), (double)(8 + b0), 0.0, (double)(j + 1), (double)(-1 + b0), 0.0, 0, 0, 0, 64);
|
||||
tessellator.setColorRGBA_F(0.0F, 0.0F, 0.0F, 0.25F);
|
||||
tessellator.addVertex((double)(-j - 1), (double)(-1 + b0), 0.0D);
|
||||
tessellator.addVertex((double)(-j - 1), (double)(8 + b0), 0.0D);
|
||||
tessellator.addVertex((double)(j + 1), (double)(8 + b0), 0.0D);
|
||||
tessellator.addVertex((double)(j + 1), (double)(-1 + b0), 0.0D);
|
||||
tessellator.draw();
|
||||
|
||||
|
||||
GL11.glEnable(GL11.GL_TEXTURE_2D);
|
||||
fontrenderer.drawString(text, -fontrenderer.getStringWidth(text) / 2, b0, 553648127);
|
||||
@@ -163,9 +132,9 @@ public class UIHelper {
|
||||
public static void drawRectangle(double x1, double y1, double z1, double x2, double y2, double z2, int r, int g, int b, int a){
|
||||
Tessellator tessellator = Tessellator.instance;
|
||||
|
||||
tessellator.startDrawingQuads();
|
||||
tessellator.setColorRGBA(r, g, b, a);
|
||||
|
||||
tessellator.startDrawingQuads();
|
||||
|
||||
tessellator.addVertex(x1, y2, z1);
|
||||
tessellator.addVertex(x1, y1, z2);
|
||||
tessellator.addVertex(x2, y1, z2);
|
||||
@@ -178,9 +147,9 @@ public class UIHelper {
|
||||
public static void drawRectangleEW(double x1, double y1, double z1, double x2, double y2, double z2, int r, int g, int b, int a){
|
||||
Tessellator tessellator = Tessellator.instance;
|
||||
|
||||
tessellator.startDrawingQuads();
|
||||
tessellator.setColorRGBA(r, g, b, a);
|
||||
|
||||
tessellator.startDrawingQuads();
|
||||
|
||||
tessellator.addVertex(x1, y1, z1);
|
||||
tessellator.addVertex(x1, y1, z2);
|
||||
tessellator.addVertex(x2, y2, z2);
|
||||
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
+1
-1
@@ -1,5 +1,6 @@
|
||||
package mcp.mobius.waila.gui.screens.config;
|
||||
|
||||
import mcp.mobius.waila.Constants;
|
||||
import mcp.mobius.waila.gui.interfaces.CType;
|
||||
import mcp.mobius.waila.gui.interfaces.WAlign;
|
||||
import mcp.mobius.waila.gui.screens.ScreenBase;
|
||||
@@ -9,7 +10,6 @@ import mcp.mobius.waila.gui.widgets.buttons.ButtonBooleanConfig;
|
||||
import mcp.mobius.waila.gui.widgets.buttons.ButtonContainer;
|
||||
import mcp.mobius.waila.gui.widgets.buttons.ButtonContainerLabel;
|
||||
import mcp.mobius.waila.gui.widgets.buttons.ButtonScreenChange;
|
||||
import mcp.mobius.waila.utils.Constants;
|
||||
import net.minecraft.client.gui.GuiScreen;
|
||||
|
||||
public class ScreenConfig extends ScreenBase {
|
||||
+16
-18
@@ -2,8 +2,9 @@ package mcp.mobius.waila.gui.screens.config;
|
||||
|
||||
import org.lwjgl.util.Point;
|
||||
|
||||
import mcp.mobius.waila.Waila;
|
||||
import mcp.mobius.waila.api.impl.ConfigHandler;
|
||||
import mcp.mobius.waila.Constants;
|
||||
import mcp.mobius.waila.mod_Waila;
|
||||
import mcp.mobius.waila.addons.ConfigHandler;
|
||||
import mcp.mobius.waila.gui.events.MouseEvent;
|
||||
import mcp.mobius.waila.gui.interfaces.CType;
|
||||
import mcp.mobius.waila.gui.interfaces.IWidget;
|
||||
@@ -18,10 +19,7 @@ import mcp.mobius.waila.gui.widgets.WidgetGeometry;
|
||||
import mcp.mobius.waila.gui.widgets.buttons.ButtonLabel;
|
||||
import mcp.mobius.waila.gui.widgets.buttons.ButtonScreenChange;
|
||||
import mcp.mobius.waila.gui.widgets.movable.PictureMovableRC;
|
||||
import mcp.mobius.waila.overlay.OverlayConfig;
|
||||
import mcp.mobius.waila.utils.Constants;
|
||||
import net.minecraft.client.gui.GuiScreen;
|
||||
import net.minecraftforge.common.config.Configuration;
|
||||
|
||||
public class ScreenHUDConfig extends ScreenBase {
|
||||
|
||||
@@ -50,10 +48,10 @@ public class ScreenHUDConfig extends ScreenBase {
|
||||
layoutY.addWidget("ValueDisplayY", new LabelFixedFont(null, "0")).setGeometry(new WidgetGeometry(50.0,50.0,20,20, CType.RELXY, CType.ABSXY, WAlign.CENTER, WAlign.CENTER));
|
||||
*/
|
||||
|
||||
double picX = ConfigHandler.instance().getConfig(Configuration.CATEGORY_GENERAL, Constants.CFG_WAILA_POSX,0) / 100.0;
|
||||
double picY = ConfigHandler.instance().getConfig(Configuration.CATEGORY_GENERAL, Constants.CFG_WAILA_POSY,0) / 100.0;
|
||||
float picAlpha = ConfigHandler.instance().getConfig(Configuration.CATEGORY_GENERAL, Constants.CFG_WAILA_ALPHA,0) / 100.0f;
|
||||
scale = ConfigHandler.instance().getConfig(Configuration.CATEGORY_GENERAL, Constants.CFG_WAILA_SCALE,0) / 100.0f;
|
||||
double picX = ConfigHandler.instance().getConfigInt(Constants.CFG_WAILA_POSX) / 100.0;
|
||||
double picY = ConfigHandler.instance().getConfigInt(Constants.CFG_WAILA_POSY) / 100.0;
|
||||
float picAlpha = ConfigHandler.instance().getConfigInt(Constants.CFG_WAILA_ALPHA) / 100.0f;
|
||||
scale = ConfigHandler.instance().getConfigInt(Constants.CFG_WAILA_SCALE) / 100.0f;
|
||||
|
||||
int picSX = (int)(180 / this.rez.getScaleFactor() * scale), picSY = (int)(62 / this.rez.getScaleFactor() * scale);
|
||||
this.addWidget("Layout", new LayoutMargin(null), RenderPriority.HIGH);
|
||||
@@ -221,17 +219,17 @@ public class ScreenHUDConfig extends ScreenBase {
|
||||
|
||||
}
|
||||
if (srcwidget.equals(this.getWidget("ButtonOk")) && signal == Signal.CLICKED){
|
||||
ConfigHandler.instance().setConfig(Configuration.CATEGORY_GENERAL, Constants.CFG_WAILA_POSX, (int)(this.getWidget("Layout").getWidget("Picture").getGeometry().getRawPos().getX() * 100.0));
|
||||
ConfigHandler.instance().setConfig(Configuration.CATEGORY_GENERAL, Constants.CFG_WAILA_POSY, (int)(this.getWidget("Layout").getWidget("Picture").getGeometry().getRawPos().getY() * 100.0));
|
||||
ConfigHandler.instance().setConfig(Configuration.CATEGORY_GENERAL, Constants.CFG_WAILA_ALPHA, (int)(this.getWidget("Layout").getWidget("Picture").getAlpha() * 100.0));
|
||||
ConfigHandler.instance().setConfig(Configuration.CATEGORY_GENERAL, Constants.CFG_WAILA_SCALE, (int)(scale * 100.0));
|
||||
ConfigHandler.instance().setConfigInt(Constants.CFG_WAILA_POSX, (int)(this.getWidget("Layout").getWidget("Picture").getGeometry().getRawPos().getX() * 100.0));
|
||||
ConfigHandler.instance().setConfigInt(Constants.CFG_WAILA_POSY, (int)(this.getWidget("Layout").getWidget("Picture").getGeometry().getRawPos().getY() * 100.0));
|
||||
ConfigHandler.instance().setConfigInt(Constants.CFG_WAILA_ALPHA, (int)(this.getWidget("Layout").getWidget("Picture").getAlpha() * 100.0));
|
||||
ConfigHandler.instance().setConfigInt(Constants.CFG_WAILA_SCALE, (int)(scale * 100.0));
|
||||
|
||||
OverlayConfig.alpha = ConfigHandler.instance().getConfig(Configuration.CATEGORY_GENERAL, Constants.CFG_WAILA_ALPHA,0);
|
||||
OverlayConfig.posX = ConfigHandler.instance().getConfig(Configuration.CATEGORY_GENERAL, Constants.CFG_WAILA_POSX, 0);
|
||||
OverlayConfig.posY = ConfigHandler.instance().getConfig(Configuration.CATEGORY_GENERAL, Constants.CFG_WAILA_POSY, 0);
|
||||
OverlayConfig.scale = ConfigHandler.instance().getConfig(Configuration.CATEGORY_GENERAL, Constants.CFG_WAILA_SCALE,0) / 100.0f;
|
||||
mod_Waila.alpha = ConfigHandler.instance().getConfigInt(Constants.CFG_WAILA_ALPHA);
|
||||
mod_Waila.posX = ConfigHandler.instance().getConfigInt(Constants.CFG_WAILA_POSX);
|
||||
mod_Waila.posY = ConfigHandler.instance().getConfigInt(Constants.CFG_WAILA_POSY);
|
||||
mod_Waila.scale = ConfigHandler.instance().getConfigInt(Constants.CFG_WAILA_SCALE) / 100.0f;
|
||||
|
||||
OverlayConfig.updateColors();
|
||||
mod_Waila.updateColors();
|
||||
}
|
||||
|
||||
if (srcwidget.equals(this.getWidget("ButtonDefault")) && signal == Signal.CLICKED){
|
||||
+2
-1
@@ -1,6 +1,6 @@
|
||||
package mcp.mobius.waila.gui.screens.config;
|
||||
|
||||
import mcp.mobius.waila.api.impl.ConfigHandler;
|
||||
import mcp.mobius.waila.addons.ConfigHandler;
|
||||
import mcp.mobius.waila.gui.interfaces.CType;
|
||||
import mcp.mobius.waila.gui.interfaces.WAlign;
|
||||
import mcp.mobius.waila.gui.screens.ScreenBase;
|
||||
@@ -8,6 +8,7 @@ import mcp.mobius.waila.gui.widgets.LayoutBase;
|
||||
import mcp.mobius.waila.gui.widgets.WidgetGeometry;
|
||||
import mcp.mobius.waila.gui.widgets.buttons.ButtonContainer;
|
||||
import mcp.mobius.waila.gui.widgets.buttons.ButtonScreenChange;
|
||||
import mcp.mobius.waila.gui_old.widget_old.ButtonChangeScreen;
|
||||
import net.minecraft.client.gui.GuiScreen;
|
||||
|
||||
public class ScreenModuleChoice extends ScreenBase {
|
||||
+5
-4
@@ -1,6 +1,6 @@
|
||||
package mcp.mobius.waila.gui.screens.config;
|
||||
|
||||
import mcp.mobius.waila.api.impl.ConfigHandler;
|
||||
import mcp.mobius.waila.addons.ConfigHandler;
|
||||
import mcp.mobius.waila.gui.interfaces.CType;
|
||||
import mcp.mobius.waila.gui.interfaces.WAlign;
|
||||
import mcp.mobius.waila.gui.screens.ScreenBase;
|
||||
@@ -11,7 +11,8 @@ import mcp.mobius.waila.gui.widgets.buttons.ButtonBooleanConfigRemote;
|
||||
import mcp.mobius.waila.gui.widgets.buttons.ButtonContainer;
|
||||
import mcp.mobius.waila.gui.widgets.buttons.ButtonContainerLabel;
|
||||
import mcp.mobius.waila.gui.widgets.buttons.ButtonScreenChange;
|
||||
import mcp.mobius.waila.utils.Constants;
|
||||
import mcp.mobius.waila.gui_old.widget_old.ButtonConfigOption;
|
||||
import mcp.mobius.waila.gui_old.widget_old.ButtonConfigRemote;
|
||||
import net.minecraft.client.gui.GuiScreen;
|
||||
|
||||
public class ScreenModuleConfig extends ScreenBase {
|
||||
@@ -30,9 +31,9 @@ public class ScreenModuleConfig extends ScreenBase {
|
||||
|
||||
for (String key:ConfigHandler.instance().getConfigKeys(this.modName).keySet()){
|
||||
if (ConfigHandler.instance().isServerRequired(key))
|
||||
buttonContainer.addButton(new ButtonBooleanConfigRemote(this.getRoot(), Constants.CATEGORY_MODULES, key, "screen.button.no", "screen.button.yes"), ConfigHandler.instance().getConfigKeys(this.modName).get(key));
|
||||
buttonContainer.addButton(new ButtonBooleanConfigRemote(this.getRoot(), key, "screen.button.no", "screen.button.yes"), ConfigHandler.instance().getConfigKeys(this.modName).get(key));
|
||||
else
|
||||
buttonContainer.addButton(new ButtonBooleanConfig(this.getRoot(), Constants.CATEGORY_MODULES, key, "screen.button.no", "screen.button.yes"), ConfigHandler.instance().getConfigKeys(this.modName).get(key));
|
||||
buttonContainer.addButton(new ButtonBooleanConfig(this.getRoot(), key, "screen.button.no", "screen.button.yes"), ConfigHandler.instance().getConfigKeys(this.modName).get(key));
|
||||
//buttonContainer.addButton(new ButtonConfigRemote(-1, "No", "Yes", ConfigHandler.instance().getConfigKeys(this.modName).get(key), key ));
|
||||
//else
|
||||
//buttonContainer.addButton(new ButtonConfigOption(-1, "No", "Yes", ConfigHandler.instance().getConfigKeys(this.modName).get(key), key ));
|
||||
+5
-8
@@ -1,7 +1,7 @@
|
||||
package mcp.mobius.waila.gui.screens.config;
|
||||
|
||||
import net.minecraft.client.gui.GuiScreen;
|
||||
import net.minecraftforge.common.config.Configuration;
|
||||
import mcp.mobius.waila.Constants;
|
||||
import mcp.mobius.waila.gui.interfaces.CType;
|
||||
import mcp.mobius.waila.gui.interfaces.WAlign;
|
||||
import mcp.mobius.waila.gui.screens.ScreenBase;
|
||||
@@ -11,7 +11,6 @@ import mcp.mobius.waila.gui.widgets.buttons.ButtonBooleanConfig;
|
||||
import mcp.mobius.waila.gui.widgets.buttons.ButtonContainerLabel;
|
||||
import mcp.mobius.waila.gui.widgets.buttons.ButtonIntegerConfig;
|
||||
import mcp.mobius.waila.gui.widgets.buttons.ButtonScreenChange;
|
||||
import mcp.mobius.waila.utils.Constants;
|
||||
|
||||
public class ScreenWailaConfig extends ScreenBase {
|
||||
public ScreenWailaConfig(GuiScreen parent){
|
||||
@@ -22,12 +21,10 @@ public class ScreenWailaConfig extends ScreenBase {
|
||||
|
||||
ButtonContainerLabel buttonContainer = ((ButtonContainerLabel)this.getRoot().getWidget("ButtonContainer"));
|
||||
|
||||
buttonContainer.addButton( new ButtonBooleanConfig(this.getRoot(), Configuration.CATEGORY_GENERAL, Constants.CFG_WAILA_SHOW, true, true, "screen.button.hidden", "screen.button.visible"), "choice.showhidewaila");
|
||||
buttonContainer.addButton( new ButtonBooleanConfig(this.getRoot(), Configuration.CATEGORY_GENERAL, Constants.CFG_WAILA_MODE, true, true, "screen.button.maintained", "screen.button.toggled"), "choice.toggledmaintained");
|
||||
buttonContainer.addButton( new ButtonBooleanConfig(this.getRoot(), Configuration.CATEGORY_GENERAL, Constants.CFG_WAILA_METADATA, true, false,"screen.button.hidden", "screen.button.visible"), "choice.showhideidmeta");
|
||||
buttonContainer.addButton( new ButtonBooleanConfig(this.getRoot(), Configuration.CATEGORY_GENERAL, Constants.CFG_WAILA_LIQUID, true, false,"screen.button.hidden", "screen.button.visible"), "choice.showliquids");
|
||||
buttonContainer.addButton( new ButtonBooleanConfig(this.getRoot(), Configuration.CATEGORY_GENERAL, Constants.CFG_WAILA_SHIFTBLOCK, true, false,"screen.button.no", "screen.button.yes"), "choice.shifttoggledblock");
|
||||
buttonContainer.addButton( new ButtonBooleanConfig(this.getRoot(), Configuration.CATEGORY_GENERAL, Constants.CFG_WAILA_SHIFTENTS, true, false,"screen.button.no", "screen.button.yes"), "choice.shifttoggledents");
|
||||
buttonContainer.addButton( new ButtonBooleanConfig(this.getRoot(), Constants.CFG_WAILA_SHOW, true, true, "screen.button.hidden", "screen.button.visible"), "choice.showhidewaila");
|
||||
buttonContainer.addButton( new ButtonBooleanConfig(this.getRoot(), Constants.CFG_WAILA_MODE, true, true, "screen.button.maintained", "screen.button.toggled"), "choice.toggledmaintained");
|
||||
buttonContainer.addButton( new ButtonBooleanConfig(this.getRoot(), Constants.CFG_WAILA_METADATA, true, false,"screen.button.hidden", "screen.button.visible"), "choice.showhideidmeta");
|
||||
buttonContainer.addButton( new ButtonBooleanConfig(this.getRoot(), Constants.CFG_WAILA_LIQUID, true, false,"screen.button.hidden", "screen.button.visible"), "choice.showliquids");
|
||||
|
||||
|
||||
this.getRoot().addWidget("LayoutConfigPos", new LayoutBase(this.getRoot()));
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
package mcp.mobius.waila.gui.screens.info;
|
||||
|
||||
import mcp.mobius.waila.cbcore.LangUtil;
|
||||
import codechicken.lib.lang.LangUtil;
|
||||
import net.minecraft.client.gui.GuiScreen;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import mcp.mobius.waila.gui.interfaces.CType;
|
||||
File renamed without changes.
File renamed without changes.
+2
-2
@@ -42,7 +42,7 @@ public class FontHelper {
|
||||
|
||||
public static void drawString(String s, float x, float y, TrueTypeFont font, float scaleX, float scaleY, float rotationZ, float... rgba){
|
||||
Minecraft mc = Minecraft.getMinecraft();
|
||||
ScaledResolution sr = new ScaledResolution(mc, mc.displayWidth, mc.displayHeight);
|
||||
ScaledResolution sr = new ScaledResolution(mc.gameSettings, mc.displayWidth, mc.displayHeight);
|
||||
if(mc.gameSettings.hideGUI){
|
||||
return;
|
||||
}
|
||||
@@ -88,7 +88,7 @@ public class FontHelper {
|
||||
|
||||
private static void set2DMode(FloatBuffer matrixData) {
|
||||
Minecraft mc = Minecraft.getMinecraft();
|
||||
ScaledResolution sr = new ScaledResolution(mc, mc.displayWidth, mc.displayHeight);
|
||||
ScaledResolution sr = new ScaledResolution(mc.gameSettings, mc.displayWidth, mc.displayHeight);
|
||||
mc.entityRenderer.setupOverlayRendering();
|
||||
GL11.glMatrixMode(GL11.GL_PROJECTION);
|
||||
GL11.glPushMatrix();
|
||||
+1
-1
@@ -57,7 +57,7 @@ public class FontLoader{
|
||||
Font font;
|
||||
TrueTypeFont out = null;
|
||||
try {
|
||||
font = Font.createFont(type, Minecraft.getMinecraft().getResourceManager().getResource(res).getInputStream());
|
||||
font = Font.createFont(type, Minecraft.getMinecraft().func_110442_L().func_110536_a(res).func_110527_b());
|
||||
font = font.deriveFont(defSize);
|
||||
out = new TrueTypeFont(font, antialias);
|
||||
} catch (Exception e) {
|
||||
File renamed without changes.
File renamed without changes.
File renamed without changes.
+1
-1
@@ -7,7 +7,7 @@ import net.minecraft.item.ItemStack;
|
||||
import org.lwjgl.opengl.GL11;
|
||||
import org.lwjgl.util.Point;
|
||||
|
||||
import codechicken.nei.guihook.GuiContainerManager;
|
||||
import codechicken.nei.forge.GuiContainerManager;
|
||||
|
||||
public class ItemStackDisplay extends WidgetBase {
|
||||
|
||||
Loaded 100 of 249 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user