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: 6

Eliaquim

Hakuen Studio
Veteran
Joined
May 22, 2018
Messages
1,882
Reaction score
1,360
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,346
Reaction score
8,078
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,448
Reaction score
694
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

Veteran
Veteran
Joined
Oct 8, 2018
Messages
3,605
Reaction score
1,356
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

Yay. I turned 39 today. Another year older, another year closer to the grave.
I'm sure the latest post/thread in the sidebar used to have 5 posts. Was it always been like this?

Made it to the 10th video doing this! :kaocry:

renderTimingPixel.png
Made the "My Beating Mystery" board today:
3ENFLSC.png

in Grim Trigger episodes 3 & 4, the main characters play a Clue rip-off board game called "My Beating Mystery" (haha), so of course I had to draw the board for it. Can't decide if I wanna add blood or not
Jeez...
I finally decide, after several ppl asking me to, to create a gamethread about project M... And my internet craps out on me halfway through the process :(

Forum statistics

Threads
110,403
Messages
1,053,034
Members
143,464
Latest member
coolgadget123
Top