added font to repo and simplified inv desc
This commit is contained in:
BIN
assets/font/x12y16pxMaruMonica.ttf
Normal file
BIN
assets/font/x12y16pxMaruMonica.ttf
Normal file
Binary file not shown.
@@ -195,22 +195,22 @@ public class UI {
|
||||
|
||||
// DESCRIPTION FRAME
|
||||
int itemIndex = getItemIndex();
|
||||
if(panel.player.inventory.size()-1 < itemIndex || panel.player.inventory.get(itemIndex).description == null) return;
|
||||
int dFrameX = frameX;
|
||||
int dFrameY = frameY + frameHeight+2;
|
||||
int dFrameWidth = frameWidth;
|
||||
int dFrameHeight = panel.tileSize*3;
|
||||
drawSubWindow(dFrameX, dFrameY, dFrameWidth, dFrameHeight);
|
||||
|
||||
// DRAW DESCRIPTION
|
||||
int textX = dFrameX + 20;
|
||||
int textY = dFrameY + panel.tileSize;
|
||||
graphics2d.setFont(graphics2d.getFont().deriveFont(28F));
|
||||
if(itemIndex < panel.player.inventory.size())
|
||||
if(itemIndex < panel.player.inventory.size()) {
|
||||
drawSubWindow(dFrameX, dFrameY, dFrameWidth, dFrameHeight);
|
||||
for(String line : panel.player.inventory.get(itemIndex).description.split("\n")) {
|
||||
graphics2d.drawString(line, textX, textY);
|
||||
textY += 32;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// GAME STATES
|
||||
|
||||
@@ -245,12 +245,6 @@ public class Player extends Entity {
|
||||
// INVENTORY
|
||||
inventory.add(currentWeapon);
|
||||
inventory.add(currentShield);
|
||||
inventory.add(new KeyObj(panel));
|
||||
inventory.add(new KeyObj(panel));
|
||||
inventory.add(new KeyObj(panel));
|
||||
inventory.add(new KeyObj(panel));
|
||||
inventory.add(new KeyObj(panel));
|
||||
inventory.add(new KeyObj(panel));
|
||||
}
|
||||
public int getAttack() {
|
||||
return attack = strength * currentWeapon.attackValue;
|
||||
|
||||
Reference in New Issue
Block a user