RPG Maker VX Ace

RPG Maker VX Ace

查看统计:
Self-switches inside choices
Is it possible to have more than one self-switch call (or whatever it's called) within a singular choice branch?

As an example
Choice A: turns on self-switch A
Choice B: turns on self-switch B

For some reason, this doesn't work and I am unable to access either related page going forwards. If I were to remove one self-switch inside the choice branch(es) it then does work. Is there a better way of doing or attempting this?
< >
正在显示第 1 - 6 条,共 6 条留言
Tested. Works fine.
Mokang Sonate 3 月 29 日 上午 5:00 
Tested. Works fine.
Could you take an image of the way you did it? My code for some reason doesn't work. Here it is below.

@>Show Choices: Toss 1 coin., Fish for change.
: When [Toss 1 coin]
@>Text: *You throw a coin in!*
@>Play SE
@>Text: *Lose 1 coin*
@>Change Gold:, -1
@>Control self Switch:A =ON

: When [Fish for change.]
@> Text: *You fish for change and find 10 coins!*
@> Text: You gain 10 coins!
@> Play SE
@> Change Gold: +10
@> Control Self Switch: B =ON
Branch End

Then I have two more pages where Page 2 requires Switch A to be on, Page 3 requires Switch B to be on.
Page 1

@>Text: -, -, Normal, Bottom
:
: A Or B
@>Show Choices: A, B
: When [A]
@>Control Self Switch: A =ON
@>Control Self Switch: B = OFF
@>Control Self Switch: C =OFF
@>
: When [ B ]
@>Control Self Switch: A =OFF
@>Control Self Switch: B =ON
@>Control Self Switch: C =OFF
@>
: When Cancel
@>Control Self Switch: A =OFF
@>Control Self Switch: B = OFF
@>Control Self Switch: C =ON
@>
: Branch End

Page 2

@>Control Self Switch: A =OFF

Page 3

@>Control Self Switch: B =OFF

Page 4

@>Control Self Switch: C =OFF
最后由 kittylitterproduction 编辑于; 3 月 29 日 上午 11:15
Mokang Sonate 3 月 29 日 下午 5:03 
Page 1

@>Text: -, -, Normal, Bottom
:
: A Or B
@>Show Choices: A, B
: When [A]
@>Control Self Switch: A =ON
@>Control Self Switch: B = OFF
@>Control Self Switch: C =OFF
@>
: When [ B ]
@>Control Self Switch: A =OFF
@>Control Self Switch: B =ON
@>Control Self Switch: C =OFF
@>
: When Cancel
@>Control Self Switch: A =OFF
@>Control Self Switch: B = OFF
@>Control Self Switch: C =ON
@>
: Branch End

Page 2

@>Control Self Switch: A =OFF

Page 3

@>Control Self Switch: B =OFF

Page 4

@>Control Self Switch: C =OFF
How come the other switches have to be off on the other pages? (and within the branch as well) I was trying to make an event where you gain/lose gold after an event and what you end up with is just a text description being repeated after interacting with said event.
最后由 Mokang Sonate 编辑于; 3 月 29 日 下午 5:04
引用自 Mokang Sonate
Page 1

@>Text: -, -, Normal, Bottom
:
: A Or B
@>Show Choices: A, B
: When [A]
@>Control Self Switch: A =ON
@>Control Self Switch: B = OFF
@>Control Self Switch: C =OFF
@>
: When [ B ]
@>Control Self Switch: A =OFF
@>Control Self Switch: B =ON
@>Control Self Switch: C =OFF
@>
: When Cancel
@>Control Self Switch: A =OFF
@>Control Self Switch: B = OFF
@>Control Self Switch: C =ON
@>
: Branch End

Page 2

@>Control Self Switch: A =OFF

Page 3

@>Control Self Switch: B =OFF

Page 4

@>Control Self Switch: C =OFF
How come the other switches have to be off on the other pages? (and within the branch as well) I was trying to make an event where you gain/lose gold after an event and what you end up with is just a text description being repeated after interacting with said event.
On page 1 the other switches are being turned off to ensure that with each choice only the specific self switch intended is on. Probably not strictly necessary as the program should already keep track of it but it's a programming habit to prevent unintended states.

For pages 2 to 4, each page has as condition the corresponding switch being on and on interaction it is being turned off so you go back to page 1 and can choose again.

Each event page has its distinct own graphic so you can always see which event page is the currently active one. It's a test event after all, to see it handling multiple self switch triggering, not a working vent for an active game.
Mokang Sonate 3 月 30 日 下午 12:23 
引用自 Mokang Sonate
How come the other switches have to be off on the other pages? (and within the branch as well) I was trying to make an event where you gain/lose gold after an event and what you end up with is just a text description being repeated after interacting with said event.
On page 1 the other switches are being turned off to ensure that with each choice only the specific self switch intended is on. Probably not strictly necessary as the program should already keep track of it but it's a programming habit to prevent unintended states.

For pages 2 to 4, each page has as condition the corresponding switch being on and on interaction it is being turned off so you go back to page 1 and can choose again.

Each event page has its distinct own graphic so you can always see which event page is the currently active one. It's a test event after all, to see it handling multiple self switch triggering, not a working vent for an active game.
Gotcha, thank you. I'll be experimenting from here!
< >
正在显示第 1 - 6 条,共 6 条留言
每页显示数: 1530 50