Jump to content


Photo

Remote Control Over Events?

switch global switch self switch event question

  • This topic is locked This topic is locked
7 replies to this topic

#1 gloot

gloot

    Newbie

  • Members
  • 5 posts
  • LocationBrazil
  • Primarily UsesRMVX Ace
  • First LanguagePortuguese

Posted 16 June 2012 - 01:55 AM

Hello everyone. I just started toying around with VX Ace and have being reading some guides and tutorials and also making some experiences on my own. And I have a quick question.

One of the things that I ended up doing was being able to close/open a window. I was on the right track since I got the window to close, but the internal picture of window is made of two tiles and I was unable to close the top half of the window.

Eventually I ended up using a global switch to make the room goes dark when the the window was closed and used that global switch in a way that I could close the top half of the window.

But the question remained on my head... if I didn't mess with the light/dark room and used the close/open window only as a novelty to the game I would still require a global switch to each window on the game? There isn't any way to make a event trigger another event? Maybe link two events as one or make one event occupy two tiles on the map? Other possible approach would be to draw the window on the map and use a event to change the tiles of the map. Is that possible?

Thanks

#2 Andynator

Andynator

    Advanced Member

  • Members
  • 59 posts
  • Primarily UsesRMVX Ace
  • First LanguageGerman

Posted 16 June 2012 - 02:23 AM

You can copy the Window Tile, and build a Charset with it.

Then you can close the window by using the "Set move Route"-Command. Or you can search for a script, wich can call Map-Events. Then you can call the upper Window-half-Event to close itself.

Edited by Andynator, 16 June 2012 - 02:23 AM.


#3 Celianna

Celianna

    VX/Ace tileset artist

  • Global Moderators
  • 4,574 posts
  • Primarily UsesRMVX
  • First LanguageDutch

Posted 17 June 2012 - 01:49 AM

I think there might actually be a script out there that let's you control an event's self switches, you should look for it in our script section.

That aside, you could use a global switch instead, one for each window, and have a second event page for the top part of the window set to that switch as a condition, it'll automatically switch to it when the switch is turned on.

Or you could create a spriteset out of the entire window - open and closed - and use it as one event, so you don't even have to deal with the hassle.

#4 Bird Eater

Bird Eater

    Boredom is just another thing you want to avoid

  • Members
  • 146 posts
  • Primarily UsesRMVX Ace
  • First LanguageDutch

Posted 17 June 2012 - 05:17 AM

Use
$game_self_switches[[map_id, event_id, 'switch_id']] = value
in a script call to control any self switch of any event on any map.
$game_self_switches[[@map_id, 5, 'C']] = true
would flip self switch C of the event with id 5 on the map you're currently on, on.
@map_id can be replaced with a number to indicate another map.
Don't forget the ' ' when indicating which self switch to flip.

If you want this to be more global, such as flipping the self switch of the event next to the one running it on, no matter the id of the targeted event, just ask me.
There's also a method to activate another event via another event, I made that in a bigger script, so I can extract that too if you want me to.

#5 gloot

gloot

    Newbie

  • Members
  • 5 posts
  • LocationBrazil
  • Primarily UsesRMVX Ace
  • First LanguagePortuguese

Posted 18 June 2012 - 10:35 PM

Woa! Thanks Bird Eater. This tip gonna be really useful!

I never thought of a event triggering another by proximity. You could use this to make a big chain-reaction-style event? Even though I didn't had this idea, now that you mention it, it made me curious. I sure wouldn't mind having that kind of knowledge if you are willing to share it! =D

Edited by gloot, 18 June 2012 - 10:36 PM.


#6 Bird Eater

Bird Eater

    Boredom is just another thing you want to avoid

  • Members
  • 146 posts
  • Primarily UsesRMVX Ace
  • First LanguageDutch

Posted 19 June 2012 - 04:42 PM

Uhm yeah, sure thing.

I submitted the script to the rgss3 subforum thingy, but it has to be approved of first...

So here it is:

Spoiler

Edited by Bird Eater, 19 June 2012 - 04:50 PM.


#7 gloot

gloot

    Newbie

  • Members
  • 5 posts
  • LocationBrazil
  • Primarily UsesRMVX Ace
  • First LanguagePortuguese

Posted 20 June 2012 - 01:23 AM

Hey! That's great! The fact that you can use a switch instead of activating make it really easy to make the event inaccessible to the action button of the user. Thanks, Bird Eater!

#8 Celianna

Celianna

    VX/Ace tileset artist

  • Global Moderators
  • 4,574 posts
  • Primarily UsesRMVX
  • First LanguageDutch

Posted 20 June 2012 - 06:19 AM

Thank you for your help, Bird Eater.

This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.





Also tagged with one or more of these keywords: switch, global switch, self switch, event, question

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users