aboutsummaryrefslogtreecommitdiff
path: root/src/main/kotlin/moe/nea/firmament/rei
diff options
context:
space:
mode:
authornea <nea@nea.moe>2023-06-03 14:24:48 +0200
committernea <nea@nea.moe>2023-06-03 14:24:48 +0200
commit9477a32ad577fc242fd83059826706fcea8c6f31 (patch)
tree900481bf5c9bc390b4101f946f6221b9995eccba /src/main/kotlin/moe/nea/firmament/rei
parent06a8ace53c3c1fcce02e9a9d085b82acb8cecb71 (diff)
downloadFirmament-9477a32ad577fc242fd83059826706fcea8c6f31.tar.gz
Firmament-9477a32ad577fc242fd83059826706fcea8c6f31.tar.bz2
Firmament-9477a32ad577fc242fd83059826706fcea8c6f31.zip
Bad pets menu
Diffstat (limited to 'src/main/kotlin/moe/nea/firmament/rei')
-rw-r--r--src/main/kotlin/moe/nea/firmament/rei/SBItemEntryDefinition.kt8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/main/kotlin/moe/nea/firmament/rei/SBItemEntryDefinition.kt b/src/main/kotlin/moe/nea/firmament/rei/SBItemEntryDefinition.kt
index ee6b673..c38f350 100644
--- a/src/main/kotlin/moe/nea/firmament/rei/SBItemEntryDefinition.kt
+++ b/src/main/kotlin/moe/nea/firmament/rei/SBItemEntryDefinition.kt
@@ -45,7 +45,13 @@ data class SBItemStack(
val neuItem: NEUItem?,
val stackSize: Int,
) {
- fun asItemStack(): ItemStack? {
+ constructor(skyblockId: SkyblockId, stackSize: Int = 1) : this(
+ skyblockId,
+ RepoManager.getNEUItem(skyblockId),
+ stackSize
+ )
+
+ fun asItemStack(): ItemStack {
if (skyblockId == SkyblockId.COINS)
return ItemCache.coinItem(stackSize)
return neuItem.asItemStack(idHint = skyblockId).copyWithCount(stackSize)