avoid another magic number
Some of the hardcoded +1 scattered about are likely invlet_gold or invlet_overflow, but I didn't hunt those down.
This commit is contained in:
@@ -151,7 +151,8 @@ money2u(struct monst* mon, long amount)
|
||||
mongold = splitobj(mongold, amount);
|
||||
obj_extract_self(mongold);
|
||||
|
||||
if (!merge_choice(gi.invent, mongold) && inv_cnt(FALSE) >= 52) {
|
||||
if (!merge_choice(gi.invent, mongold)
|
||||
&& inv_cnt(FALSE) >= invlet_basic) {
|
||||
You("have no room for the gold!");
|
||||
dropy(mongold);
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user