Event Name (Or Colour) in Conditional Branch

HexMozart88

The Master of Random Garbage
Veteran
Joined
May 15, 2016
Messages
1,746
Reaction score
3,143
First Language
English
Primarily Uses
RMVXA
I haven't made a thread in here for so long, but I can't seem to find this. I'm trying to find a way to make it so that if two events are the same colour and touching each other, it triggers another event. But, I really don't know how to make a conditional branch for the colour of an event. I don't even know if there's a script call out there for that (believe me, I've looked), so what I figured was I could instead use the event's name, because I actually found a couple of sites for that. But, when I tried to insert the script call into the conditional branch, it said "undefined method 'character_name = '". 


Here was the script call I used: $ game_map.events[ID].character_name


So, yeah, I'm currently looking for a new script call that either checks colour or name.  


Thanks in advance. 
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
38,280
Reaction score
11,868
First Language
English
Primarily Uses
RMMV
Events don't have colours.  You will need to give more of an explanation about how they're set up.  Events also don't trigger when touching other events.


Did you use = or ==?  = is assignment, == is comparison.  But that will not check their 'colour' - it just says whether they're using the same character sprite or not.  And if your character sprites are the 8-in-1 type, the name could be the same even though they are different sprites.


That is also not the event name, but the spritesheet/charactersheet name, which is different.


What does "touching each other" mean?  Are they just side by side?  Or does one of them need to try and move onto the tile that the other one occupies?  The latter is what causes an Event Touch or Player Touch trigger.
 

HexMozart88

The Master of Random Garbage
Veteran
Joined
May 15, 2016
Messages
1,746
Reaction score
3,143
First Language
English
Primarily Uses
RMVXA
Events don't have colours.  You will need to give more of an explanation about how they're set up.
I mean the sprite graphics for the events. And it's set with a conditional branch checking the name of the event (for now, all it does is just spit out random text, since this is for a test game).

Events also don't trigger when touching other events.
Ah, yes. I forgot to mention that I'm using Hime's Event Trigger Script. Sorry about that. 

Did you use = or ==?  = is assignment, == is comparison.
Oh... that makes sense. Yeah, I used = . 

What does "touching each other" mean?  Are they just side by side?
Yes. Just beside each other.

But that will not check their 'colour'
I know that, but what I was hoping to do was use the actual event name and name it, like "green" or "blue" or something. 


Thanks for getting me to clarify though. I realize exactly how vague my opening posts can be when I'm desperate.  
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
38,280
Reaction score
11,868
First Language
English
Primarily Uses
RMMV
You can give your event a name, and do $game_map.events[id].event.name == $game_map.events[id].event.name to see if two events have the same name.  This could be 'green' and 'blue' and have nothing to do with the character sprite.


As for triggering when they're just beside each other - I don't know - it depends on what the script can do.
 
Last edited by a moderator:

HexMozart88

The Master of Random Garbage
Veteran
Joined
May 15, 2016
Messages
1,746
Reaction score
3,143
First Language
English
Primarily Uses
RMVXA
I have to test the script a bit more, but thank you. I will test this when I get the chance. Which'll probably be tomorrow. 


EDIT: Doesn't work. It says "undefined method 'event'" now.  
 
Last edited by a moderator:

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

Latest Threads

Latest Posts

Latest Profile Posts

A wave of cold air has hit Canada... I know it's "always cold", but this one is especially cold... I'm freezing to death lol.
Have fun with English: a "fire grenade" is not portable napalm but a fire extinguisher tool.
2 days ago someone tried to convert me to Islam. Today youtube tried to convert me to Catholicism. The only thing left would be to meet sone Jehova's witnesses.
I just successfully tested changing music by region, and changing it between continents on the world map after getting on/off the airship. I had to override the default audio transitions with eventing to make it change smoothly but it worked.
Stream will be going live shortly with some more Witcher 3, then we will switch to another game! Feel free to drop by~

Forum statistics

Threads
93,419
Messages
912,206
Members
122,926
Latest member
JoetSmith
Top