summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--npc/items/shovel.txt9
1 files changed, 8 insertions, 1 deletions
diff --git a/npc/items/shovel.txt b/npc/items/shovel.txt
index f58565975..eb1d88cbe 100644
--- a/npc/items/shovel.txt
+++ b/npc/items/shovel.txt
@@ -158,7 +158,11 @@ function script shovel_scatter {
.@id = requestitem();
- if (.@id < 1 || countitem(.@id) < 1 || .@id == IronShovel || checkbound(.@id) || !getiteminfo(.@id, ITEMINFO_MAXCHANCE)) {
+ // If ID is invalid, there's not enough items, it is an Iron Shovel, it is bound = Cannot bury
+ // GMs bypass rarity check. (A trade restriction check would be better)
+ if (.@id < 1 || countitem(.@id) < 1 || .@id == IronShovel || checkbound(.@id) ||
+ (!is_gm() && !getiteminfo(.@id, ITEMINFO_MAXCHANCE))
+ ) {
@ShovelLastUsed = 0;
if (.@id == IronShovel || checkbound(.@id))
mesc l("You cannot bury this item!");
@@ -253,6 +257,9 @@ OnInit:
AddDigRect("011-1", 20, 20, 180, 180);
AddDigRect("015-1", 20, 20, 180, 180);
+ // Aeros can be used too (for events)
+ AddDigRect("001-1", 20, 20, 342, 158);
+
OnHour00:
// Clear random treasure
deletearray $@WBT_Random_id;