add lantern object and implement light management in player and environment

This commit is contained in:
2025-12-13 13:44:52 +01:00
parent 7ee7614c6c
commit 2105a0e8af
9 changed files with 86 additions and 27 deletions

View File

@@ -194,7 +194,11 @@ public class UI {
for(int i = 0; i < entity.inventory.size(); i++) {
// EQUIP CURSOR
if(entity.inventory.get(i) == entity.currentWeapon || entity.inventory.get(i) == entity.currentShield) {
if(
entity.inventory.get(i) == entity.currentWeapon ||
entity.inventory.get(i) == entity.currentShield ||
entity.inventory.get(i) == entity.currentLight
) {
graphics2d.setColor(new Color(240, 190,90));
graphics2d.fillRoundRect(slotX, slotY, panel.tileSize, panel.tileSize, 10, 10);
}