Turning off an Item

frokas

Villager
Member
Joined
Jun 8, 2020
Messages
13
Reaction score
0
First Language
Greek
Primarily Uses
N/A
Hello there, I am new to the RPG Making community, I am trying to make an item that is a lantern and I am doing this through a common event at the moment (I dont know how else I can do this )

My problem is after turning it on once, after using the item again it doesnt remove the state, any ideas?
 

ShadowDragon

Veteran
Veteran
Joined
Oct 8, 2018
Messages
2,832
Reaction score
998
First Language
Dutch
Primarily Uses
RMMV
do you use YEP_ButtonCommonEvents plugin as well? if so, can you screen
your event? if not, than still a screenshot of the event.
 

Hyouryuu-Na

Sapphire Sodium
Veteran
Joined
Jun 15, 2017
Messages
935
Reaction score
2,186
First Language
Not English
Primarily Uses
RMMV
Turn on a switch after the lantern is on. Check if that switch is on. If it is, then turn the switch off as well as the lantern's graphic or light or whatever.
@frokas
Like this:
1597861524559.png
 
Last edited:

frokas

Villager
Member
Joined
Jun 8, 2020
Messages
13
Reaction score
0
First Language
Greek
Primarily Uses
N/A
Hello @ShadowDragon thanks for the reply, please see attached my event (it's through Khas the plugin that enables the lantern)


Turn on a switch after the lantern is on. Check if that switch is on. If it is, then turn the switch off as well as the lantern's graphic or light or whatever.
@frokas
Like this:
View attachment 155819

But using the item again will turn it off afterwards like this?
 

Hyouryuu-Na

Sapphire Sodium
Veteran
Joined
Jun 15, 2017
Messages
935
Reaction score
2,186
First Language
Not English
Primarily Uses
RMMV
Yes. Any time you use the item, if it's ON, it'll turn OFF. If it's OFF, it'll turn ON.
 

frokas

Villager
Member
Joined
Jun 8, 2020
Messages
13
Reaction score
0
First Language
Greek
Primarily Uses
N/A
Yes. Any time you use the item, if it's ON, it'll turn OFF. If it's OFF, it'll turn ON.

Thanks it works, I don't really understand how but it worked. :)
 

Hyouryuu-Na

Sapphire Sodium
Veteran
Joined
Jun 15, 2017
Messages
935
Reaction score
2,186
First Language
Not English
Primarily Uses
RMMV
Glad it's what you wanted ^^
Basically, you're turning on a switch to let the game know that the lantern is ON. So next time, when the item is used, the game will first check if it's already ON or not. If it is, it will turn the lantern OFF. Similarly, if it's OFF, it will turn the lantern ON.
This method not only works for lanterns, it can also work for pictures/maps or even events or anything like that. Like, suppose you want to press a button to show a picture. Then when you press the button again, the picture will be gone.
 
Last edited:

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

Latest Threads

Latest Profile Posts


My only regret is the portal mirror effect is too subtle to show up in these GIFs. It probably just needs more sparkles. :LZSwink:
Microsoft: Hey, let's waste money advertising the Xbox Series X when nobody has any in stock, we don't seem to be making more, we aren't taking preorders and you can't get on a waiting list. BEST. IDEA. EVER.
So I'm practicing ITC with a spirit box, and decide to try to contact my deceased soulmate. It actually gave me multiple identifiers. Me, still a bit skeptical, asked aloud "Fine but does he still love me?" and the box spoke and printed the word "Forever" at the same time. Been a mess of tears since. :kaocry:
Been scratching away at my game and making progress, but just had a revelation. I'm working in full screen and adjusting all my pictures accordingly, but will they resize if someone's screen is smaller?? I hope this doesn't turn out to be a problem later.

Forum statistics

Threads
105,633
Messages
1,015,133
Members
137,292
Latest member
inkdrips
Top