"equipped" indicator on item grid

This commit is contained in:
minjaesong
2017-10-25 05:53:39 +09:00
parent 977df44316
commit 4e69f21c8b
4 changed files with 16 additions and 4 deletions

View File

@@ -95,9 +95,11 @@ class UIItemInventoryElem(
batch.color = item!!.nameColour mul if (mouseUp) mouseOverTextCol else inactiveTextCol
// draw name of the item
Terrarum.fontGame.draw(batch,
//"$item" + (if (amount > 0 && item!!.stackable) "$fwsp($amount)" else if (amount != 1) "$fwsp!!$amount!!" else "") +
// print name and amount in parens
item!!.name + (if (amount > 0 && item!!.stackable) "$fwsp($amount)" else if (amount != 1) "$fwsp!!$amount!!" else "") +
// TEMPORARY print eqipped slot info as well
(if (equippedSlot != null) " ${0xE081.toChar()}\$$equippedSlot" else ""),
posX + textOffsetX,
posY + textOffsetY
)