Pahno

Villager
Member
Joined
Sep 7, 2021
Messages
26
Reaction score
1
First Language
Russian
Primarily Uses
N/A
I wanted to number my choice, and for this I need the variables to decrease in the message. As intended it should be like this:

\V[10-1] Show Text
\V[10-2] Show Text
\V[10-3] Show Text
etc.
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
38,495
Reaction score
10,916
First Language
German
Primarily Uses
RMMV
or simply use a double index: \V[\V[20]]

you can then calculate a number in variable 20 and that result will be used to find the number for the outer variable sequence
 

Pahno

Villager
Member
Joined
Sep 7, 2021
Messages
26
Reaction score
1
First Language
Russian
Primarily Uses
N/A
or simply use a double index: \V[\V[20]]

you can then calculate a number in variable 20 and that result will be used to find the number for the outer variable sequence
Can you give an example? I'm trying to \V[\V[20-1]], \V[\V[20]-1] and it doesn't work
 

Mac15001900

Veteran
Veteran
Joined
Aug 7, 2022
Messages
163
Reaction score
155
First Language
English
Primarily Uses
RMMV
Messages do not support mathematical operations in them. \V[\V[20]] will allow you to access different variables, depending on the value of the 20th variable.

If that's not what you want, it might be helpful if you specify why do you want to do \V[10-1], \V[10-2] and \V[10-3] instead of \v[9], \v[8] and \v[7].
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
38,495
Reaction score
10,916
First Language
German
Primarily Uses
RMMV
@Pahno as said above you cannot have a mathematical operation inside a show text, you need to do it before.

control variable v20 = 10-2
show text "\V[\V[20]]"

will show the content of variable 8, that is 10-2
 

Pahno

Villager
Member
Joined
Sep 7, 2021
Messages
26
Reaction score
1
First Language
Russian
Primarily Uses
N/A
Messages do not support mathematical operations in them. \V[\V[20]] will allow you to access different variables, depending on the value of the 20th variable.

If that's not what you want, it might be helpful if you specify why do you want to do \V[10-1], \V[10-2] and \V[10-3] instead of \v[9], \v[8] and \v[7].
I plan to number the rows of choice.

1> Show text
2> Show text
3> Show text
etc

I use plugins that allow you to hide some answers. So I wanted to use variables.
For example, V[20]=0

V[[20]+1]> Show Text
V[[20]+2]> Show Text
V[[20]+3]> Show Text
etc
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
38,495
Reaction score
10,916
First Language
German
Primarily Uses
RMMV
your answers do not make any sense.

please start at the beginning of what you want to do and what the player should see.
what - not how, that is important.

because the how you're trying to do something is completely wrong.
 

Pahno

Villager
Member
Joined
Sep 7, 2021
Messages
26
Reaction score
1
First Language
Russian
Primarily Uses
N/A
your answers do not make any sense.

please start at the beginning of what you want to do and what the player should see.
what - not how, that is important.

because the how you're trying to do something is completely wrong.
I want my rows in choise to be automatically numbered. Like this
 

Attachments

  • Скриншот 21-03-2023 121353.png
    Скриншот 21-03-2023 121353.png
    16.7 KB · Views: 10

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
38,495
Reaction score
10,916
First Language
German
Primarily Uses
RMMV
That is not what I asked for - I wanted a full explanation putting in context all the tiny side-facts you listed scattered through the previous answers.
The only thing you just have proven is that your problem has nothig to do with variables and cannot be solved by variables at all. Just because you want numbers and variables store numb ers does not mean that one thing has anything to do with the other.

So please give a full description of what you want, using at least a dozen sentences for every part.
Then we can perhaps point you to a way to do things.
 

Bex

Veteran
Veteran
Joined
Aug 2, 2013
Messages
1,953
Reaction score
756
First Language
German
Primarily Uses
RMMZ
I don't understand the details of this Question, so i don't know what or how to solve.
One guess:
Use 4 Variables instead of 1.

Control Variables:
V[1] set to 1
Control Variables:
V[2] set to 2
Control Variables:
V[3] set to 3
Control Variables:
V[4] set to 4
Show Text
V[1] = 1> Text
V[2] = 2> Text
V[3] = 3> Text
V[4] = 4> Text
end
Control Variables, Batch 1 to 4 do +4
Show Text
V[1] = 5> Text
V[2] = 6> Text
V[3] = 7> Text
V[4] = 8> Text
end
Control Variables, Batch 1 to 4 do +4
Show Text
V[1] = 9> Text
V[2] = 10> Text
V[3] = 11> Text
V[4] = 12> Text

And than you can continue this...
But it uses 4 instead of 1 Variable.
Is this what you wanted to do?
 
Last edited:

Pahno

Villager
Member
Joined
Sep 7, 2021
Messages
26
Reaction score
1
First Language
Russian
Primarily Uses
N/A
I wanted to make the number display in choice. The rows of choice were disappearing and appearing, so I wanted to make numbers through variables.

However, you wrote above that you cannot use a calculator in messages. So my idea failed.
 

Bex

Veteran
Veteran
Joined
Aug 2, 2013
Messages
1,953
Reaction score
756
First Language
German
Primarily Uses
RMMZ
1.
Which Plugin do you use?
2.
Can you show an example on how it looks if all questions are on and how if one is missing?
I dont fully understand this. 1 time you got 1, 2,3 and 4. And another Time 1,2 and 4 ?
Can you build and show how it should look like with example Pictures?
That could help us better understand.
 

Pahno

Villager
Member
Joined
Sep 7, 2021
Messages
26
Reaction score
1
First Language
Russian
Primarily Uses
N/A
1.
Which Plugin do you use?
2.
Can you show an example on how it looks if all questions are on and how if one is missing?
I dont fully understand this. 1 time you got 1, 2,3 and 4. And another Time 1,2 and 4 ?
3.
Can you build and show how it should look like with example Pictures?
1.
I'm using a plugin that allows you to output selection variables and switches
2. Since the calculator in messages does not work, I have no idea how to do it
3. For Example choice window:

1. A
2. B
3. C
4. D

IIf I choose B, it will disappear, but the numbering should still be there.

1. A
2. C
3. D
 
  • Like
Reactions: Bex

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
6,156
Reaction score
6,321
First Language
English
Primarily Uses
RMMZ
1.
I'm using a plugin that allows you to output selection variables and switches
2. Since the calculator in messages does not work, I have no idea how to do it
3. For Example choice window:

1. A
2. B
3. C
4. D

IIf I choose B, it will disappear, but the numbering should still be there.

1. A
2. C
3. D

If you want conditional choices to still be numbered according to which ones are there, you would need to build this into the plugin. There's no other way to interrupt the code that creates the choices in order to inject the correct numbers.

Well...that's technically not true, but the method for doing it would be a bit convoluted. You'd need a variable for the choice position of each possible choice, and then use conditional branches to work out which ones are going to be shown, then set the respective variables to whatever value reflects where that choice is going to be in the list.
 

Latest Threads

Latest Profile Posts

Heading to Orlando in six days! It'll be my first time going to Disney's Typhoon Lagoon. And then my dad will pick what we do for Father's Day!
With this, I'm gonna have a good night sleep
Damn. We’ve gotten so close to 0 reports, 0 approvals a few times over the past couple weeks. Does it matter? No. Is it realistic. No? Do I rely on your reports and want everyone to keep posting. Yes. Do I 100% games? …sigh… Yes.

Ah yes, all three of my moods all at once.

Forum statistics

Threads
131,757
Messages
1,223,021
Members
173,520
Latest member
Trancesan
Top