Making an Item activate an Event (?)

(I'm new to this forum so forgive me if my ignorance gets the better of me!) So I need help figuring out how to make a key item activate an event...or more-so, how to even use that item on said event.


Specifically, I'm making a practice-run for myself, since I've never created or even used this stuff before, and I'm trying to figure out how to make my key item, which in this case is a shovel, available for use on my event, which is a grave. I want the player to use the shovel on the grave to dig it up and get a key. I can make the player pick up the shovel and it gets added to the key items, but when I go to the grave, and the inventory pops up, my shovel is there, I just can't select it to dig up the grave.


If anyone could give me specific coding instructions, that would help a lot. 🙂
1. choose a variable you want to use to store the item id of your key item (lets take 10 in this example and name it Item ID)


2. lets take 101 as item id for your shovel


3. create an even on your map, that represents the grave


3a. in the grave event:


Select Key Item: [0010:Item ID]


Conditional Branch: Variable [0010: Item ID] == 101


  Text: You dig up the grave...


Else


  Text: you need a proper tool...


Branch End
1. choose a variable you want to use to store the item id of your key item (lets take 10 in this example and name it Item ID)


2. lets take 101 as item id for your shovel


3. create an even on your map, that represents the grave


3a. in the grave event:


Select Key Item: [0010:Item ID]


Conditional Branch: Variable [0010: Item ID] == 101


  Text: You dig up the grave...


Else


  Text: you need a proper tool...


Branch End

Thanks so much for this! I finally got it figured out! I didn't understand how to use IDs and Variables, but I got it now. Thanks 😀

Original thread: https://forums.rpgmakerweb.com/threads/making-an-item-activate-an-event.56082/