Select different key items? (Hard to describe shortly, check post please)

Hello, first post etc. etc.

So let's say a character in a game wants you to get items of a certain type. For examples, items that are red.

The player has a red sock and a red shirt.

What I want is for the player to be able to give EITHER of these items, and for a different item to have a different response.

Basically, the player can give any item (or just a variety of them), and for each item to have a unique response.

Is there a script for this, or even just a way to do it without one?
You just set them up as key items, and use the Select Key Item command. Then you do a series of conditional branches checking the value in the variable for each item id that could have been chosen.
You just set them up as key items, and use the Select Key Item command. Then you do a series of conditional branches checking the value in the variable for each item id that could have been chosen.
Oh wow. I knew you could do that, just not that you could do it with multiple items.

Thanks for the help! 😀
The select key item command simply places the number of the item selected into the variable.


After that you can check the stored number in any way you want - there'll be a lot of possible numbers that won't fit, but you only need to check for positives as long as you disable the else-branch.

Original thread: https://forums.rpgmakerweb.com/threads/select-different-key-items-hard-to-describe-shortly-check-post-please.52307/