Item consumable on only one tile coordinate?

Hey hows it goin?

My game is coming along well! I want to add a scroll that when it's read (consumed) the player moves involuntarily through a certain path. However, my problem is that I only want this scroll usable on a certain tile coordinate. Anywhere else, I want it to display "Hmm.. nothing seems to be happening."

Is this possible? How?

Thanks

Dymdez

P.S. I've already setup the common event and made the item, that part works.
Yeah, have the item do nothing but run a common event. Then verify the map # Player x and player y in three variables and check each of them in nested conditional branches where if any of them fail it shows "hmm...nothing seems to be happening." and add +1 of that item back to your inventory (because if it is consumable it will always remove it on use, or alternatively you could set it to not be consumed but have at the end of the event where you are in the correct path remove it from inventory.)

You can check the map id and player x + y by calling: Control Variables/Game Data/Other and Control Variables/Game Data/Character
At the expense of your patience, Alex, could you explain that just a little simpler for us newbies 🙂

How does one.. verify the map at 3 variables?
Certainly... When you open up the event commands on row 1 there is one called "Control Variables" when you open this it will give you a lot of options for what you want to do with these variables. Select "game data" and "other" the first option will be "map Id". with that set every time you use your item it will make that variable = the id of the map the player is currently on. So you open "Control Variables" again as well as "game data" only this time you select "Character" rather than "other" and two of the options will be "Player's X" and "Player's Y" This corresponds to the tile location of the map that the player is currently standing on (which can be viewed in the editor on the lower right-hand side whenever you select a tile on a map) With that done you just set up your event to check these variables to verify that the player is on the correct map and in the correct location, it should look similar to this.



If you have any other questions feel free to ask, and you might want to check out some of the more open-ended tutorials over in the tutorials section of the forum, they might not be teaching specific systems but they'll give you the competence you need to invent your own a lot of times.
yea that was amazing, wow thanks

works perfectly!

Original thread: https://forums.rpgmakerweb.com/threads/item-consumable-on-only-one-tile-coordinate.23676/