shopkeeper: type: assignment debug: false interact scripts: - 202 shopkeeper1 shopkeeper1: type: interact steps: 'starting*': click trigger: script: - chat "What can I get for you?" - wait 1s - inventory open d:in@ChristyShop ChristyShop: type: inventory debug: false title: "Christy's Shop - click to purchase" size: 27 slots: - "[i@myrabbit] [] [] [] [] [] [] [] []" - "[] [] [] [] [] [] [] [] []" - "[] [] [] [] [] [] [] [] []" myrabbit: type: item material: COOKED_RABBIT display name: "Yummy Rabbit" lore: - "Delicious" - "$8" shopkeeperChat: type: format debug: false format: "<&6> Christy: <&f> " ShopkeeperInventory: type: world debug: false events: on player clicks in ChristyShop: - determine cancelled on player drags in ChristyShop: - determined cancelled on player clicks myrabbit in ChristyShop: - narrate "You clicked on rabbit." - if > 8 { - inventory close - money take quantity:8 - narrate "<&a>$<&e>8 <&a>has been taken from your balance" - give myrabbit } else { - inventory close - narrate "<&c>You do not have enough money!" }