How to make "Zoom" and "Holy Protection" skills/items? (Descriptions within)

I feel bad for making so many threads... But I don't see a general questions thread, so...

As I've mentioned in other threads, I'm working on a game that is inspired by early Dragon Quest games. As such, there are certain skills and item effects that I would like to emulate here, which are staples of DQ games (and many other RPGs, for that matter).

I feel like these can probably done through events somehow, though I am not sure how exactly to do them. Though if they would require scripting, I'd appreciate if someone could point me in the right direction with that as well.

So I'll explain what they do, and hopefully someone can help me out 😀

Zoom (Spell)/Chimaera Wing (Item) - Teleports the user to a town which they have visited before. I would need to be able to mark areas to be teleported to, and the player would only be able to teleport to an area once they have visited it for the first time. Would also need some kind of flag to prevent the player from using this spell/item in certain situations (for example, you can't use them within a dungeon).

Holy Protection (Spell)/Holy Water (Item) - Aka Repel from Pokemon. Prevents weak random encounters for a certain number of steps. I know there's already a state condition that prevents enemy encounters, however it seems to just prevent ALL encounters without being able to specify that the enemies be a lower level than the player in order to be avoided. I know that there's no levels for enemies, but I figure there must be some way to determine if the enemies encountered in a given area/region ID are "weak" compared to the player level.

Can anyone help me out with these? I'd really appreciate it!
Teleports the user to a town which they have visited before. I would need to be able to mark areas to be teleported to, and the player would only be able to teleport to an area once they have visited it for the first time.
If it's a single town/area, you can use a common event and a transfer player based on variables. But if you want the player able to choose the location, that is going to be complicated. It can be done, but it might as well as request a script for the convenience.

Would also need some kind of flag to prevent the player from using this spell/item in certain situations (for example, you can't use them within a dungeon).
Use a switch as a flag should be enough. You flip the switch ON when you want to disable this. And then create a conditional branch if the switch is ON, prevent them to teleport.

Holy Protection (Spell)/Holy Water (Item) - Aka Repel from Pokemon. Prevents weak random encounters for a certain number of steps. I know there's already a state condition that prevents enemy encounters, however it seems to just prevent ALL encounters without being able to specify that the enemies be a lower level than the player in order to be avoided. I know that there's no levels for enemies, but I figure there must be some way to determine if the enemies encountered in a given area/region ID are "weak" compared to the player level.
If I'm going to nitpick this, I don't get the "protection" feeling out of the skill. Say hypothetically, we have a pool of enemies like this, and we're able to determine the weak encounter.
- Weak encounter A = 20% chance
- Weak encounter B = 30% chance
- Weak encounter C = 40% chance
- Strong encounter = 10% chance


And if you're going to toggle this ON, you're basically doing this
- Weak encounter A = 20% chance
- Weak encounter B = 30% chance
- Weak encounter C = 40% chance

- Strong encounter = 10% 100% chance

Is it really protection? For me, it is like you're just eliminating the weak encounter and increase the chance of the stronger encounter. Is this really what you want? Additionally, do you know how random encounter works, like how the next encounter is determined?
You'll need an item to call a common event, and in that common event ask the player by show choices where to teleport to. This could be done without scripts if you place a lot of conditional branches, but the better way would be to use tsukihime's script about choice options to enable and disable choices based on switches, and then activate switches for the targets if you have visited the maps.

for the second option, you can either have your own encounters designed by common event (completely disabling the default random encounter) or you'll need a script to enable a dynamic random encounter table. Both cases are a lot of work because you'll have to handle the random tables manually.
@TheoAllen

Yeah, you're right about it not being much of a "Protection" lol. I mean, I didn't name it that, Dragon Quest did. It's mainly meant to ward away weak enemies when you're traversing old areas. Though I suppose it would be nice if I made it where it totally disables random encounters. I mean, it doesn't have to be exactly like DQ, yeah?

@Andar

Oh that script by Tsukihime sounds perfect!

Though... I don't understand much about scripting myself... Can you maybe explain to me how I can achieve my desired results with that script?

I'd like for the unvisited locations to display as a string of ????? and also be greyed out, until I flip a switch On upon reaching that location for the first time. What is the exact script string I need to achieve that?
there are examples in the script description. just ask here if you need help, I haven't used it in a long time either.
It works! 🙂



Thanks so much!

Original thread: https://forums.rpgmakerweb.com/threads/how-to-make-zoom-and-holy-protection-skills-items-descriptions-within.119870/