Corrected plant pot ids for trees

This commit is contained in:
Avi Weinstock 2022-07-30 15:41:47 +00:00 committed by Ryan
parent 3145af75a6
commit 6dd470cc66
3 changed files with 16 additions and 12 deletions

View file

@ -51254,7 +51254,7 @@
{
"shop_price": "1",
"ge_buy_limit": "100",
"examine": "A plant pot filled with soil.",
"examine": "An empty plant pot.",
"grand_exchange_price": "20",
"durability": null,
"name": "Plant pot",
@ -139702,4 +139702,4 @@
"weight": "0.01",
"id": "298"
}
]
]

View file

@ -645,7 +645,7 @@
"general_store": "false",
"id": "73",
"title": "Vanessa's Farming Shop",
"stock": "{5376,10,100}-{6032,300,100}-{5418,10,100}-{6036,10,100}-{5354,100,100}-{5341,10,100}-{5329,10,100}-{5343,10,100}-{952,10,100}-{5325,10,100}-{1925,100,100}-{5331,30,100}-{12622,10,100}-{5996,0,100}-{6006,0,100}-{1965,0,100}-{5994,0,100}-{5931,0,100}-{6000,0,100}-{1957,0,100}-{5504,0,100}-{5986,0,100}-{1982,0,100}-{5982,0,100}-{6002,0,100}-{5998,0,100}"
"stock": "{5376,10,100}-{6032,300,100}-{5418,10,100}-{6036,10,100}-{5350,100,100}-{5341,10,100}-{5329,10,100}-{5343,10,100}-{952,10,100}-{5325,10,100}-{1925,100,100}-{5331,30,100}-{12622,10,100}-{5996,0,100}-{6006,0,100}-{1965,0,100}-{5994,0,100}-{5931,0,100}-{6000,0,100}-{1957,0,100}-{5504,0,100}-{5986,0,100}-{1982,0,100}-{5982,0,100}-{6002,0,100}-{5998,0,100}"
},
{
"npcs": "2307",
@ -654,7 +654,7 @@
"general_store": "false",
"id": "74",
"title": "Alice's Farming Shop",
"stock": "{5376,10,100}-{6032,300,100}-{5418,10,100}-{6036,10,100}-{5354,100,100}-{5341,10,100}-{5329,10,100}-{5343,10,100}-{952,10,100}-{5325,10,100}-{1925,100,100}-{5331,30,100}-{12622,10,100}-{5996,0,100}-{6006,0,100}-{1965,0,100}-{5994,0,100}-{5931,0,100}-{6000,0,100}-{1957,0,100}-{5504,0,100}-{5986,0,100}-{1982,0,100}-{5982,0,100}-{6002,0,100}-{5998,0,100}"
"stock": "{5376,10,100}-{6032,300,100}-{5418,10,100}-{6036,10,100}-{5350,100,100}-{5341,10,100}-{5329,10,100}-{5343,10,100}-{952,10,100}-{5325,10,100}-{1925,100,100}-{5331,30,100}-{12622,10,100}-{5996,0,100}-{6006,0,100}-{1965,0,100}-{5994,0,100}-{5931,0,100}-{6000,0,100}-{1957,0,100}-{5504,0,100}-{5986,0,100}-{1982,0,100}-{5982,0,100}-{6002,0,100}-{5998,0,100}"
},
{
"npcs": "2304",
@ -663,7 +663,7 @@
"general_store": "false",
"id": "75",
"title": "Sarah's Farming Shop",
"stock": "{5376,10,100}-{6032,300,100}-{5418,10,100}-{6036,10,100}-{5354,100,100}-{5341,10,100}-{5329,10,100}-{5343,10,100}-{952,10,100}-{5325,10,100}-{1925,100,100}-{5331,30,100}-{12622,10,100}-{5996,0,100}-{6006,0,100}-{1965,0,100}-{5994,0,100}-{5931,0,100}-{6000,0,100}-{1957,0,100}-{5504,0,100}-{5986,0,100}-{1982,0,100}-{5982,0,100}-{6002,0,100}-{5998,0,100}"
"stock": "{5376,10,100}-{6032,300,100}-{5418,10,100}-{6036,10,100}-{5350,100,100}-{5341,10,100}-{5329,10,100}-{5343,10,100}-{952,10,100}-{5325,10,100}-{1925,100,100}-{5331,30,100}-{12622,10,100}-{5996,0,100}-{6006,0,100}-{1965,0,100}-{5994,0,100}-{5931,0,100}-{6000,0,100}-{1957,0,100}-{5504,0,100}-{5986,0,100}-{1982,0,100}-{5982,0,100}-{6002,0,100}-{5998,0,100}"
},
{
"npcs": "2306",
@ -672,7 +672,7 @@
"general_store": "false",
"id": "76",
"title": "Richard's Farming Shop",
"stock": "{5376,10,100}-{6032,300,100}-{5418,10,100}-{6036,10,100}-{5354,100,100}-{5341,10,100}-{5329,10,100}-{5343,10,100}-{952,10,100}-{5325,10,100}-{1925,100,100}-{5331,30,100}-{12622,10,100}-{5996,0,100}-{6006,0,100}-{1965,0,100}-{5994,0,100}-{5931,0,100}-{6000,0,100}-{1957,0,100}-{5504,0,100}-{5986,0,100}-{1982,0,100}-{5982,0,100}-{6002,0,100}-{5998,0,100}"
"stock": "{5376,10,100}-{6032,300,100}-{5418,10,100}-{6036,10,100}-{5350,100,100}-{5341,10,100}-{5329,10,100}-{5343,10,100}-{952,10,100}-{5325,10,100}-{1925,100,100}-{5331,30,100}-{12622,10,100}-{5996,0,100}-{6006,0,100}-{1965,0,100}-{5994,0,100}-{5931,0,100}-{6000,0,100}-{1957,0,100}-{5504,0,100}-{5986,0,100}-{1982,0,100}-{5982,0,100}-{6002,0,100}-{5998,0,100}"
},
{
"npcs": "557",
@ -2168,4 +2168,4 @@
"title": "Fremennik Fur Trader",
"stock": "{948,10,100}-{958,10,100}-{10117,0,100}-{10121,0,100}-{10119,0,100}-{10123,0,100}-{10093,0,100}-{10095,0,100}-{10097,0,100}-{10099,0,100}-{10101,0,100}-{10103,0,100}"
}
]
]

View file

@ -33,7 +33,7 @@ object UseWithPatchHandler{
for(p in Plantable.values()){
allowedNodes.add(p.itemID)
}
allowedNodes.addAll(arrayListOf(RAKE,SEED_DIBBER,SPADE,SECATEURS,TROWEL,Items.SUPERCOMPOST_6034,Items.COMPOST_6032,Items.PLANT_CURE_6036,Items.WATERING_CAN1_5333,Items.WATERING_CAN2_5334,Items.WATERING_CAN3_5335,Items.WATERING_CAN4_5336,Items.WATERING_CAN5_5337,Items.WATERING_CAN6_5338,Items.WATERING_CAN7_5339,Items.WATERING_CAN8_5340))
allowedNodes.addAll(arrayListOf(RAKE,SEED_DIBBER,SPADE,SECATEURS,TROWEL,Items.SUPERCOMPOST_6034,Items.COMPOST_6032,Items.PLANT_CURE_6036,Items.WATERING_CAN1_5333,Items.WATERING_CAN2_5334,Items.WATERING_CAN3_5335,Items.WATERING_CAN4_5336,Items.WATERING_CAN5_5337,Items.WATERING_CAN6_5338,Items.WATERING_CAN7_5339,Items.WATERING_CAN8_5340, Items.PLANT_POT_5350))
}
@JvmStatic
@ -66,7 +66,11 @@ object UseWithPatchHandler{
}
}
}
TROWEL -> {
TROWEL, Items.PLANT_POT_5350 -> {
if(!player.inventory.containsAtLeastOneItem(TROWEL)) {
player.sendMessage("You need a trowel to fill plant pots with dirt.")
return true
}
val p = patch.getPatchFor(player)
if(!p.isWeedy()){
player.sendMessage("This patch has something growing in it.")
@ -76,7 +80,7 @@ object UseWithPatchHandler{
return true
}
val potAmount = player.inventory.getAmount(Items.PLANT_POT_5356)
val potAmount = player.inventory.getAmount(Items.PLANT_POT_5350)
if(potAmount == 0){
player.sendMessage("You have no plant pots to fill.")
@ -87,7 +91,7 @@ object UseWithPatchHandler{
player.pulseManager.run(object : Pulse(anim.duration){
override fun pulse(): Boolean {
if(player.inventory.remove(Item(Items.PLANT_POT_5356))){
if(player.inventory.remove(Item(Items.PLANT_POT_5350))){
player.animator.animate(anim)
player.inventory.add(Item(Items.PLANT_POT_5354))
} else return true
@ -221,7 +225,7 @@ object UseWithPatchHandler{
player.skills.addExperience(Skills.FARMING, plantable.plantingXP)
p.setNewHarvestAmount()
if(p.patch.type == PatchType.TREE || p.patch.type == PatchType.FRUIT_TREE){
player.inventory.add(Item(Items.PLANT_POT_5356))
player.inventory.add(Item(Items.PLANT_POT_5350))
}
player.unlock()
return true