Skip to content

Commit b7d3f8e

Browse files
committed
1 parent 3d9716e commit b7d3f8e

File tree

4 files changed

+25
-16
lines changed

4 files changed

+25
-16
lines changed

src/main/java/com/robertx22/age_of_exile/maps/MapItemData.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -152,8 +152,8 @@ public List<Component> getTooltip() {
152152
": +" + this.getBonusLootAmountInPercent() + "%"));
153153
}
154154
comp.append(ChatFormatting.GRAY + ", ")
155-
.append(Words.Tier.locName().withStyle(ChatFormatting.GOLD)
156-
.append(": " + this.tier));
155+
.append(Words.Tooltips_Tier.locName().withStyle(ChatFormatting.GOLD)
156+
.append(this.tier));
157157

158158
tooltip.add(comp);
159159

src/main/java/com/robertx22/age_of_exile/saveclasses/item_classes/GearItemData.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -287,7 +287,7 @@ private List<MutableComponent> getFullAffixedName() {
287287
.locName());
288288
}
289289
if (this.uniqueStats == null) {
290-
text.append(Words.Space.locName()).append(GetBaseGearType().locName());
290+
text.append(Words.Prefix_Space.locName()).append(GetBaseGearType().locName());
291291
} else {
292292
text.append(uniqueStats.getUnique(this)
293293
.locName()
@@ -296,7 +296,7 @@ private List<MutableComponent> getFullAffixedName() {
296296

297297
if (affixes.hasSuffix()) {
298298
AffixData suffix = affixes.suf.get(0);
299-
text.append(Words.Space.locName())
299+
text.append(Words.Suffix_Space.locName())
300300
.append(suffix.BaseAffix()
301301
.locName());
302302
}
@@ -344,9 +344,9 @@ private List<MutableComponent> getTooManyAffixesName() {
344344

345345
txt.append("").append(prefix.locName());
346346

347-
txt.append(Words.Space.locName()).append(suffix.locName()).withStyle(format);
347+
txt.append(Words.TM_Prefix_Space.locName()).append(suffix.locName()).withStyle(format);
348348

349-
txt.append(Words.Space.locName()).append(GetBaseGearType().locName());
349+
txt.append(Words.TM_Suffix_Space.locName()).append(GetBaseGearType().locName());
350350

351351
txt.withStyle(format);
352352

src/main/java/com/robertx22/age_of_exile/uncommon/localization/Words.java

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -204,8 +204,17 @@ public enum Words implements IAutoLocName {
204204
Unsalvagable("Unsalvageable"),
205205

206206
UsableOn("Usable On"),
207+
Prefix_Space(" "),
208+
Suffix_Space(" "),
209+
TM_Prefix_Space(" "),
210+
TM_Suffix_Space(" "),
211+
Tooltips_Rarity("Rarity: "),
212+
Tooltips_Item_Type("Item Type: ").
213+
Tooltips_Tier("Tier: "),
214+
Tooltips_Item_Tier("Item Tier: "),
215+
Tooltips_Level("Level: "),
216+
Use_Tip("[Drag onto gear to use]");
207217

208-
Space(" ");
209218

210219
private String localization = "";
211220

src/main/java/com/robertx22/age_of_exile/uncommon/utilityclasses/TooltipUtils.java

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -57,8 +57,8 @@ public static List<String> compsToStrings(List<Component> list) {
5757
}
5858

5959
public static MutableComponent level(int lvl) {
60-
return Component.literal(ChatFormatting.YELLOW + "").append(Words.Level.locName())
61-
.append((": " + lvl))
60+
return Component.literal(ChatFormatting.YELLOW + "").append(Words.Tooltips_Level.locName())
61+
.append(lvl)
6262
.withStyle(ChatFormatting.YELLOW);
6363

6464
}
@@ -194,7 +194,7 @@ private static List<Component> removeDoubleBlankLines(List<Component> list, int
194194
}
195195

196196
public static MutableComponent rarity(Rarity rarity) {
197-
return Component.literal("Rarity: ").withStyle(ChatFormatting.WHITE)
197+
return Component.literal(Words.Tooltips_Rarity.locName()).withStyle(ChatFormatting.WHITE)
198198
.append(rarity.locName()
199199
.withStyle(rarity.textFormatting()));
200200
}
@@ -204,23 +204,23 @@ public static MutableComponent rarityShort(Rarity rarity) {
204204
}
205205

206206
public static MutableComponent tier(int tier) {
207-
return Words.Tier.locName().append(": " + tier);
207+
return Words.Tooltips_Tier.locName().append(tier);
208208

209209
}
210210

211211
public static MutableComponent gearSlot(GearSlot slot) {
212-
return Component.literal("Item Type: ").withStyle(ChatFormatting.WHITE)
212+
return Component.literal(Words.Tooltips_Item_Type.locName()).withStyle(ChatFormatting.WHITE)
213213
.append(slot.locName()
214214
.withStyle(ChatFormatting.AQUA));
215215
}
216216

217217
public static MutableComponent gearTier(int tier) {
218-
return Component.literal("Item Tier: ").withStyle(ChatFormatting.WHITE)
218+
return Component.literal(Words.Tooltips_Item_Tier.locName()).withStyle(ChatFormatting.WHITE)
219219
.append(Component.literal(tier + "").withStyle(ChatFormatting.AQUA));
220220
}
221221

222222
public static MutableComponent gearRarity(GearRarity rarity) {
223-
return Component.literal("Rarity: ").withStyle(ChatFormatting.WHITE)
223+
return Component.literal(Words.Tooltips_Rarity.locName()).withStyle(ChatFormatting.WHITE)
224224
.append(rarity.locName()
225225
.withStyle(rarity.textFormatting()));
226226
}
@@ -231,14 +231,14 @@ public static MutableComponent gearLevel(int lvl, int playerlvl) {
231231
if (lvl > playerlvl) {
232232
color = ChatFormatting.RED;
233233
}
234-
return Component.literal("Level: ")
234+
return Component.literal(Words.Tooltips_Level.locName())
235235
.withStyle(color)
236236
.append(Component.literal(lvl + "")
237237
.withStyle(color));
238238
}
239239

240240

241241
public static MutableComponent dragOntoGearToUse() {
242-
return Component.literal("[Drag onto gear to use]").withStyle(ChatFormatting.AQUA, ChatFormatting.BOLD);
242+
return Component.literal(Words.Use_Tip.locName()).withStyle(ChatFormatting.AQUA, ChatFormatting.BOLD);
243243
}
244244
}

0 commit comments

Comments
 (0)