Fix for Item based currency. This changes the languages files!
This commit is contained in:
parent
de7d5f0555
commit
38a613c4ac
|
@ -1,6 +1,7 @@
|
|||
package com.songoda.epicheads.head;
|
||||
|
||||
import com.songoda.core.compatibility.CompatibleMaterial;
|
||||
import com.songoda.core.hooks.EconomyManager;
|
||||
import com.songoda.core.utils.ItemUtils;
|
||||
import com.songoda.epicheads.EpicHeads;
|
||||
import com.songoda.epicheads.settings.Settings;
|
||||
|
@ -100,9 +101,13 @@ public class Head {
|
|||
lore.add(plugin.getLocale().getMessage("general.head.staffpicked").getMessage());
|
||||
lore.add(plugin.getLocale().getMessage("general.head.id")
|
||||
.processPlaceholder("id", this.id).getMessage());
|
||||
if (!free)
|
||||
if (!free) {
|
||||
String fcost = Settings.ECONOMY_PLUGIN.getString().equalsIgnoreCase("item")
|
||||
? cost + " " + Settings.ITEM_TOKEN_TYPE.getString()
|
||||
: EconomyManager.formatEconomy(cost);
|
||||
lore.add(plugin.getLocale().getMessage("general.head.cost")
|
||||
.processPlaceholder("cost", cost).getMessage());
|
||||
.processPlaceholder("cost", fcost).getMessage());
|
||||
}
|
||||
return lore;
|
||||
}
|
||||
|
||||
|
|
|
@ -20,7 +20,7 @@ general:
|
|||
head:
|
||||
staffpicked: '&8Staff Favorite'
|
||||
id: '&8ID: &7%id%'
|
||||
cost: '&8Cost: &7$%cost%'
|
||||
cost: '&8Cost: &7%cost%'
|
||||
gui:
|
||||
heads:
|
||||
refine: '&9Refine Search'
|
||||
|
|
Loading…
Reference in New Issue