Fixed enchant descriptions

This commit is contained in:
Auxilor
2023-05-15 11:07:37 +01:00
parent 3a10399e00
commit fecf5eb83e

View File

@@ -2,7 +2,7 @@ package com.willfp.ecoenchants.display
import com.github.benmanes.caffeine.cache.Cache
import com.github.benmanes.caffeine.cache.Caffeine
import com.willfp.eco.core.config.updating.ConfigUpdater
import com.willfp.eco.core.placeholder.context.placeholderContext
import com.willfp.eco.util.NumberUtils
import com.willfp.eco.util.StringUtils
import com.willfp.eco.util.formatEco
@@ -85,6 +85,8 @@ fun EcoEnchantLike.getFormattedDescription(level: Int): List<String> {
description = description.replace(tag, tag + descriptionFormat)
}
StringUtils.lineWrap(description.formatEco(), wrap)
StringUtils.lineWrap(description.formatEco(placeholderContext(
injectable = this.config
)), wrap)
}
}