Trading items for another item.

Looking for an effective way to event a conversion system that allows me to trade x amount of items for another item. Rather not use a plug-in, but if plugins are easier than sure.
I.E.

"5 Fire Essence for 1 Fire Soul."

It would be done using an event the player can interact with and do the conversion. I see that there are conditional branches if the player has the particular item, but don't see anything concerning the quantity. Thanks in advance!
Eventcommand Control Variable, Set Variable to Amount of Item in Inventory.
Than use Eventcommand Conditional Branch to check if the Variable is equal to 5 or more.
Awesome, thanks a lot!

Original thread: https://forums.rpgmakerweb.com/threads/trading-items-for-another-item.110253/