It seems a lot of people have questions about using or requiring specific items in order to cast a spell. This will descibe the general process. It requires 1 master common event and 1 additional common event for each skill you want to have this item requirement. Additionally, we will be using at least 2 switches, which we will call "Initialize Reagent Skills" and "<skill name> learned by <hero name>". You will also need a dummy skill for each skill you intend to give an item requirement, and you can do that in this way: merely copy the skill in question and past it into another slot in the skills tab of the Database (DB). Now, all that you have to do is make it so that this skill can never be used, which means using the pull-down menu under Occasion and selecting Never in the dummy skill. If you like you can edit the description to say "you do not have enough <generic item> to cast this spell.
Now, let's set up the master events:
(1) This is pretty simple. First thing we want to do is keep track of when your character obtains the skill in question (let's say it is Fireball, and Arshes is learning it, and it requires a gold mushroom to cast.). Since there is not a set point in the game that this skill is learned, we need to make a common event which is running all the time and testing to see if the character has the skill. All we want this event to do is notify the event system as to when this skill is first obtained. Let's call this event "Testing". Now, set it to paralell process, called by the switch "Initialize Reagent Skills". So our design for this part should look like this:
Conditional Branch: Switch [Fireball learned by Arshes] is OFF
Conditional Branch: [Arshes] is [001: Fireball (original)] learned
Control Switch: [Fireball learned by Arshes] is ON
Branch END
Branch END
Pretty simple eh?
(2) Now, what we want this to also do is replace the real skill Fireball with the dummy skill we made, because this is equivalent to disabling the skill. Once the skill is disabled in this way though, we need something which will re-enable it once we have the item, so this event should also perform that function. Now, let's make our event: We can call it "Skill Disabler", and it will be paralell process and called by the switch "Initialize Reagent Skills". It ought to look like this:
Conditional Branch: Switch [Fireball learned by Arshes] is ON
Conditional Branch: Item [Gold Mushroom] is in inventory
Change Skills [Arshes], + [001: Fireball (original)]
Change Skills [Arshes] - [002: Fireball (dummy)]
Else
Change Skills [Arshes], + [002: Fireball (dummy)]
Change Skills [Arshes] - [001: Fireball (original)]
Branch END
Branch END
Notice, how this begins with the same condition the first event we wrote does. We can combine the two functions into one common event merely by writing it like this:
Conditional Branch: Switch [Fireball learned by Arshes] is ON
Conditional Branch: Item [Gold Mushroom] is in inventory
Change Skills [Arshes], + [001: Fireball (original)]
Change Skills [Arshes] - [002: Fireball (dummy)]
Else
Change Skills [Arshes], + [002: Fireball (dummy)]
Change Skills [Arshes] - [001: Fireball (original)]
Branch END
Else
Conditional Branch: [Arshes] is [001: Fireball (original)] learned
Control Switch: [Fireball learned by Arshes] is ON
Branch END
Branch END
(3) That's enough if all you want to do is make it so that the skill can only be used if you have the item. If you want the item to be consumed upon using the skill you will need one more common event. We will call this one "Fireball Skill" and you will leave it's Trigger as None. Now, go to your skills database and set the original fireball skill to call this common event. Now, we need this event to do one thing: reduce the number of gold mushrooms we have. That's pretty simple, but keep in mind that paralell processes do not run during battle, so you will need to reproduce a simplified version of the first event within this one. If we run out, we will need to disable the skill, but we will not need to make allowances for re-enabling the skill since you will not bee able to replenish your gold mushroom stock until you are out of battle, and then our second event will do it's job. SO, let's make it:
It ought to look like this:
To set this event-based system into motion, all you need to do is turn on the switch "Initialize Reagent Skills". You can do that at the very beginning of the game. There, that gives us a perfectly good event system for reagent-based skills. Now, you might think: what if I want to make more skills like this? Will each one take two common events? The answer, of course, is no. It will only take one more common event, since for the skill disabler eveny, all you need to do is put an additional conditional branch underneath. To show you, I will add another skill to our event. Let's say this one is for Basil, and it is the skill Heal, which takes a Green Herb.
"Skill Disabler" should look like this:
Conditional Branch: Switch [Fireball learned by Arshes] is ON
Conditional Branch: Item [Gold Mushroom] is in inventory
Change Skills [Arshes], + [001: Fireball (original)]
Change Skills [Arshes] - [002: Fireball (dummy)]
Else
Change Skills [Arshes], + [002: Fireball (dummy)]
Change Skills [Arshes] - [001: Fireball (original)]
Branch END
Else
Conditional Branch: [Arshes] is [001: Fireball (original)] learned
Control Switch: [Fireball learned by Arshes] is ON
Branch END
Branch END
Conditional Branch: Switch [Heal learned by Basil] is ON
Conditional Branch: Item [Green Herb] is in inventory
Change Skills [Basil], + [003: Heal (original)]
Change Skills [Basil], - [004: Heal (dummy)]
Else
Change Skills [Basil], + [004: Heal (dummy)]
Change Skills [Basil], - [003: Heal (original)]
Branch END
Else
Conditional Branch: [Basil] is [001: Heal (original)] learned
Control Switch: [Heal learned by Basil] is ON
Branch END
Branch END
Now, the event Fireball remains the same. All you have to do is make an event which is analagous to Fireball, but which applies to Heal instead.
Hopefully that all makes sense. Be sure to post if you don't understand.