How to make Momentary switch in one block Without Script?

● ARCHIVED · READ-ONLY
Started by pangloy 12 posts View original ↗
  1. Hello.
    How to make Momentary switch in one block Without Script?

    Example :
    when step on switch = +1 score (add score)
    when step out switch = -1 score (Remove score)

    I don't want to make 8 of (-1 score) blocks surround one middle (+1 score) block.

    How to make Momentary switch in one block Without Script?
    Thank you so much. :kaocry:
  2. on an event touch page, trigger a change to a second page in parallel process, with it checking a condition for not-in-coordinate.
    in the not-in-coordinate case true, reset the page, in false, pass.

    whatever your coordinate might be, and whatever your process for counting might be.
  3. Sorry. :kaocry:
    How to "checking a condition for not-in-coordinate".
    My english not good. :kaocry:
    Thank you.
  4. I Got It. Make something happen when I face off button
    Face off = Move out button
    :kaohi:
  5. pangloy said:
    I Got It. Make something happen when I face off button
    Face off = Move out button
    :kaohi:

    Did not work :kaocry:
  6. @pangloy the problem here is that you're using unknown nomenclature - there are no "momentary switches" in the RPG-Makers, so we can only guess what you're talking about.

    Can you switch the editor to english and then make a screenshot of the event pages? That would show us what you're trying to do.
  7. @pangloy
    I asked for the screenshot of the event pages to see what the event should do, so that we can see what you want from there.
    your partial screenshots don't explain anything - why would you want to set a variable to 0 or to 1 depending on the position, and what should that variable then do?
  8. "set a variable to 0 or to 1 depending on the position"
    Oh !!! I got it
    Thank you. :)
  9. Hello! I just created this account to ask for help, but since my question is pretty similar to what Pangloy is asking here I thought it would be better to reply to this thread if possible?

    Basically what I want to do is to make it so only when a player is standing on a tile, a switch is turned on. The moment they move to another, it should turn off.

    A way to do it, as Pangloy showed in the screenshots, is making all the tiles adjacent to the ON tile trigger the OFF state, but that's a little inconvenient. Do you think there is any way to make this possible? gstv87 seems to know but I couldn't understand the explanation.
  10. OK! This is "Momentary switch"
    Make 2 Events on map.

    First event is

    ◆Comment:Make this program to keep an eye on on X and Y of Map.
    ◆Control Variables:#0001 switch X = 7
    ◆Control Variables:#0002 switch Y = 5

    ◆Comment:Make this program to keep an eye on on X and Y of Player.
    ◆Control Variables:#0003 player X = Map X of Player
    ◆Control Variables:#0004 player Y = Map Y of Player

    Don't forget to set it "Parallel".

    ------------
    Make Second event (Your BUTTON) and Don't forget to set it "Player Touch".

    ◆Comment:This is "First page".

    ◆If:player X = switch X
    ◆If:player Y = switch Y
    ◆Text:None, Window, Bottom
    :Text:Something turn on.
    ◆Control Self Switch:A = ON

    :End

    :End
    ------------------------

    ◆Comment:This is "Self switch A" page. Don't forget to set it "Parallel"

    ◆If:player X ≠ switch X
    ◆Text:None, Window, Bottom
    :Text:Something turn off.

    ◆Comment:Control Self switch A off = Back to "First page" for use this switch again.
    ◆Control Self Switch:A = OFF

    :End

    ◆If:player Y ≠ switch Y
    ◆Text:None, Window, Bottom
    :Text:Something turn off.

    ◆Comment:Control Self switch A off = Back to "First page" for use this switch again.
    ◆Control Self Switch:A = OFF

    :End
  11. Oh yeah that totally works!!
    Another way I found is to only use one event. I will attach pictures:
    b21c4f001e3e699faaecb80a587cff59.png

    That script call at the beginning can automatically set the Player coordinates:
    $gamePlayer.x == 9 && $gamePlayer.y == 6 && $gamePlayer._direction == 6 && $gameMap._mapId == 2

    (I didn't include the direction since in this case it's irrelevant, but you have the option).

    So that way, only when the Player is standing on that tile, whatever Variable/Switch will turn on. You then proceed to turn it off using a second page (triggered by self switch A), like this,
    fe0de2cb66b393d96bab3d635381776b.png
    Very important that the trigger is parallel, so the moment they move in any direction, it goes down!

    I don't think it's as elegant as yours, but it also works :)
  12. Use "Pressing button" to set Event. :LZSsmile:
    -----------
    Look like what I am trying
    pangloy said:
    I Got It. Make something happen when I face off button
    Face off = Move out button
    :kaohi:

    pangloy said:
    Did not work :kaocry: