Event note tag check next to player

Prellmarc

Squire
Member
Joined
Sep 23, 2014
Messages
13
Reaction score
1
First Language
German
Primarily Uses
RMVXA
What would it look like if I wanted to check an events note tag on the event next to actor? So if a <tree> is on tile next to actor, and I use an water item or skill to let the tree react to it?

I made a common event to check if ANY event is next to player and it worked so far, file is attached.(credit goes to Andar, he helped a lot). Now as said I want to check for certain events through meta data
 

Attachments

  • 4.png
    4.png
    85.6 KB · Views: 7

Eliaquim

Hakuen Studio
Veteran
Joined
May 22, 2018
Messages
1,939
Reaction score
1,397
First Language
Portuguese - Br
Primarily Uses
RMMZ
Hi!
You can use a script call to check if the event has the note:
$gameMap.event(eventId).event().note.includes('<tree>')
It will return true if the event has this note.
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
32,545
Reaction score
8,155
First Language
German
Primarily Uses
RMMV
if you want that specific notetag, you would have to write a plugin with a regex for checking the notes, because the notes themselves do nothing.

If the exact notetag doesn't matter however, you could use MV's build-in meta function.
please go to the MV help documentation, plugin specification and read about the metadata format.

using that specification to something like <name:tree> you could then check object.meta.name==='tree';
you'll have to replace object with the script code for the event (including its ID) however, and I don't know that code.

EDIT: Ninja'd
 

estriole

Veteran
Veteran
Joined
Jun 27, 2012
Messages
1,483
Reaction score
721
First Language
indonesian
Hi!
You can use a script call to check if the event has the note:
$gameMap.event(eventId).event().note.includes('<tree>')
It will return true if the event has this note.
just for clarification to @Prellmarc ... the note here is the "Note" box that put beside the "Name" box in the event editor...


and NOT the one added at the event page using comment event command...

this means the whole event only can have one type of notetags... not different note each event page (which can be done if using comment tag)... this means if you want tree event that in first page (seed phase) use watering can... then second page (grown tree phase) use axe... you cannot do that because you need to use comment tag for it to be unique each page...
 

ShadowDragon

Realist
Veteran
Joined
Oct 8, 2018
Messages
3,886
Reaction score
1,479
First Language
Dutch
Primarily Uses
RMMV
As filling up to @Eliaquim and @estriole if you want to use the notebox to check,
you can also best use "selfswitches" to it:

if SS x = OFF
water tree
SS x = ON
else
SS y = ON
end
if SS y = ON
want to chop do tree?
yes/no choices
(SS y = OFF)
else
this tree is already chooped
end

maybe 2nd page to reset it after x time.
but you can have more control over this as well.

there might be other methodes as well, but this can be the included
if it's a tree, or plant or rock etc =)
 

Latest Threads

Latest Posts

Latest Profile Posts

After gathering, sorting out & reconsidering hundreds of enemy battlers over the last two das, finally my favorite part begins: Inventing names and lore for them all :D
I'm running a sale for Learn RPG Maker MV on Itch.io, can I compete with NSFW games earning goals?
Another Friday and another Zoom call that could have been an email. Working from home is awesome.
Finished with the semester; finally have some time to play around with MV :kaopride:
Started work on the fishing Mini-Game

Forum statistics

Threads
111,366
Messages
1,060,520
Members
144,694
Latest member
Azel2
Top