Skip to content

Commit 3d6f5c3

Browse files
committed
Check if the wanted coordinate is actually valid for dropping gold
1 parent 0436f14 commit 3d6f5c3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/toniarts/openkeeper/game/controller/room/storage/RoomGoldControl.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ public RoomGoldControl(KwdFile kwdFile, IRoomController parent, IObjectsControll
4848

4949
@Override
5050
public Integer addItem(Integer sum, Point p) {
51-
if (p != null) {
51+
if (p != null && parent.isTileAccessible(null, p)) {
5252
sum = putGold(sum, p);
5353
}
5454

0 commit comments

Comments
 (0)