Reading an Events Comments

nathanlink169

Game Dev by Career, no idea what I'm doing
Veteran
Joined
Aug 15, 2013
Messages
59
Reaction score
22
First Language
English
Primarily Uses
RMMV
Hi all,

This is a feature I've seen in previous RPG Makers, and am not certain if it's possible with MV.

Long story short: I have an event. That event has comments in it that I'm trying to read. These comments will be used to determine certain behaviour of my script.

Long story not-quite-as-short-but-still-short: I'm working on a Vision Cone script. Certain NPC's will need to have Vision Cones, and certain NPC's will not need them. I would ideally like to use comments to set these values up. The reason I would like to use comments (rather than the Note section) is in case the current Active Event Page changes, I would also like the settings to change.

Is it possible to read comments from the current events page in Javascript code?
 

pasunna

Veteran
Veteran
Joined
Feb 3, 2019
Messages
491
Reaction score
190
First Language
thai
Primarily Uses
RMMV
try digin on this
sorry that I can only provide sample
I myself still learn the basic
and don't touch the comment reading yet...
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
39,141
Reaction score
12,416
First Language
English
Primarily Uses
RMMV
Take a look at what I did here:


You just have to find someone who has a plugin that uses event comments, and see how they handled it. I think it's a good approach to search for them at the time the event page changes, rather than at the time you want to check, because that's the only time the info is going to change, and doing it with each check could lead to performance issues, especially if it's a long event.
 

nathanlink169

Game Dev by Career, no idea what I'm doing
Veteran
Joined
Aug 15, 2013
Messages
59
Reaction score
22
First Language
English
Primarily Uses
RMMV
Take a look at what I did here:


You just have to find someone who has a plugin that uses event comments, and see how they handled it. I think it's a good approach to search for them at the time the event page changes, rather than at the time you want to check, because that's the only time the info is going to change, and doing it with each check could lead to performance issues, especially if it's a long event.
Thanks Shaz, that was exactly what I was looking for. I did have a bit of a peek around for script that use event comments, but they don't tend to be advertised by the fact that they use comments, moreso their behaviour, so they were difficult to find. I appreciate you pointing me in the right direction!
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

So, uh, has anyone tried buying any resources from KokoroReflections? Because I've been looking for a 'buy' button on the site for like 10 minutes now and can't find one.
Any also thought it's too cringy to put the word "and you" in your credit as a special thanks?
Cause that's what I thought...
Everyone in the US right now: Please stay safe.
Symphony Celestia: Prophecy of the Falling Stars RPG Maker music pack WIP. Symphony Celestia is a new series that focuses on symphonic and orchestrated music to tell a story. Each story will include compositions that make up that story from beginning to end. Themes include: Battles, adventures, character themes, etc. Below is a video preview to the first story.

Jumping and gravitation 0.1 build - RPG Maker MV

Forum statistics

Threads
97,978
Messages
948,266
Members
129,228
Latest member
T-Rylo
Top