Creating a Character Specific Map Ability: Sorcerer Ring

So I was thinking that a good way to allow some creative puzzle solving would be to give each character a unique skill they use if you press a button on the map that activates a common event when they are in front(there are lots of plugins that allow this).

For example, I have been working out a way to replicate something similar to Nose for Treasure/Smell from Dragon Quest or the Item Finder from Pokemon which pretty easy if not a little boring to program (basically every map would have a variable that checks how many chests you have opened, and once it reaches the max number it tells you there is no more treasure on that map - I believe there are actually more concise simple methods to do this but I'm still a beginner).

But with my green nature I am afraid one I really wanna get down still eludes me.
In "Tales of..." games there is a recurring item called the "Sorcerer Ring" which lets you fire a small fire ball that can be used to activate distant switches.
I have a few ideas of how this might work in "theory", but in practice I have no idea how you can make a character summon another event in front of them and have it move forward a certain amount of spaces before vanishing either after moving forward to far or because it touched a compatible object.

Keep in mind this have to be a common event.

One theory I had involved a separate map that stored the event when it's not being used (which would solve at least a small part of the bigger picture), but I honestly don't know if that would actually work.

Anyway rambling over. Anyone have any clue how I can make this work.

The short and sweet of it: How do I do a common event where character shoots out magic blast and it activates compatible events when it hits them?

Edit: I meant to mention this is for MV and MZ, in fact I may have put this in the wrong area.
HI, I'm not sure if you are talking about pure eventing, scripting, or if your open to plugins.

So, I'll just suggest just using Galv Projectiles plugin. I have only experimented with it, but it does exactly what you are describing, and some more.

Just add his plugin command to a common event, call it and then it can call another common event or switch to run your on-hit code.

MV version: https://galvs-scripts.com/2016/09/13/mv-map-projectiles/
MZ versioin: https://galvs-scripts.com/2020/10/16/mz-map-projectiles/
HI, I'm not sure if you are talking about pure eventing, scripting, or if your open to plugins.

So, I'll just suggest just using Galv Projectiles plugin. I have only experimented with it, but it does exactly what you are describing, and some more.

Just add his plugin command to a common event, call it and then it can call another common event or switch to run your on-hit code.

MV version: https://galvs-scripts.com/2016/09/13/mv-map-projectiles/
MZ versioin: https://galvs-scripts.com/2020/10/16/mz-map-projectiles/
Yes, it is technically what I'm looking for. I do admit I would prefer learning to do it myself through eventing, but I can't deny this is the more effective method. Thank you, I'll see if I can make this work.
if you want to do it with events, you need to use control variables and get location info to calculate all positions the blast might hit, and trigger if it finds an event that fits your conditions.

control variables is for the coordinates
get location info will give you the ID of an event at the given coordinates (zero if there is no event).

you'll have to check the event ID against a list or use it with the meta-function of MV to determine what the event is or to trigger something special
I think @autodidact choose the best Galv Projectiles plugin It's better.
Moved to RPG Maker MV as Game Mechanics Design is for game design discussions rather than implementation.
I have decided upon the use of Galv's plugin for now - now I just need to experiment with it. There are a few things I'd like to be able to do with it that require a little more finesse, such as having it flip a switch on and off or through multiple pages.

It has a self-switch and switch triggering function, but those function in a one hit kinda way so I can't do something like "cycle through various color orbs" or turn the switch on and off.

I wonder if there is a way to craft a common event that reads what the projectile hits and cycles through with each hit.
I suppose what I need is a common event that activates the event it hits somehow, then we could leave the programming to the internal workings of the event itself.
I wonder if there is a way to craft a common event that reads what the projectile hits and cycles through with each hit.
I suppose what I need is a common event that activates the event it hits somehow, then we could leave the programming to the internal workings of the event itself.

Hm, if I understand right, you can do that with a small tweak to Galv's code.

In the Galv.PROJ.executeAction function declaration, under case 'c', just set a variable to the value of target.eventId(), which is the hit event in Galv's code.

Then, when you call your common event, you can read all the data from that target via the variable.
Hm, if I understand right, you can do that with a small tweak to Galv's code.

In the Galv.PROJ.executeAction function declaration, under case 'c', just set a variable to the value of target.eventId(), which is the hit event in Galv's code.

Then, when you call your common event, you can read all the data from that target via the variable.
I'm a little nervous about picking into scripts when I'm still so green, but I'll give it a try later.

Original thread: https://forums.rpgmakerweb.com/threads/creating-a-character-specific-map-ability-sorcerer-ring.139323/