Can I add parameters based on a parameter?

FatalErrorDriveB

Villager
Member
Joined
Dec 12, 2019
Messages
16
Reaction score
1
First Language
English
Primarily Uses
RMMV
So I'm not sure if this can even be done. What I wish to do is add parameters to my plugins parameter list depending on a parameter the user entered. I know that's confusing so I'll try to give an example.

param NUM_TO_HAVE [user give a number here]

Param NUM_1 [Value] (These only show if the user has given a number that is >= to it)
param NUM_2 [Value]

Up to the user-defined number. All of this should be in the plugin manager itself.

I really hope that's clear enough, if not I'll try again to explain it.
Thank you very much for any help!

Edit to make things more clear:

Link to pic because I can't get it to show.

I'd like to add those 3 parameters for every card the player adds under "Total number of cards"
 
Last edited:

TWings

The Dragon Whisperer
Veteran
Joined
Jul 26, 2017
Messages
527
Reaction score
860
First Language
French
Primarily Uses
RMMV
Why not just use a list parameter ? I can't think of any reason to force the user to define a number first.
 

caethyril

^_^
Veteran
Joined
Feb 21, 2018
Messages
2,069
Reaction score
1,488
First Language
EN
Primarily Uses
RMMZ
Not currently supported as far as I'm aware. You may be able to restructure the plugin in order to avoid the need for such, and/or make use of array/struct parameters: v1.5.0+, details here.

I've encountered this in a plugin I'm (intermittently) working on. The user can define an object "type", but different types have different properties. The solution I've settled on is to allow the user to input a list/array of entries for each object type, where each type is assigned its own struct. The objects themselves are then assigned via other parameters. :kaoswt2:

Conditional plugin parameters (and numerical bounds depending on other parameters etc?) might be an interesting feature to request in that thread over on the RPG Maker MV board! Maybe someone's already suggested it, though, I haven't been following too closely. :kaoslp:
https://forums.rpgmakerweb.com/inde...ng-in-rpg-maker-would-you-like-to-see.114599/

Otherwise you could simply make it clear in the documentation how the parameters are used/ignored in given situations. :p
 

FatalErrorDriveB

Villager
Member
Joined
Dec 12, 2019
Messages
16
Reaction score
1
First Language
English
Primarily Uses
RMMV
I'm not really sure what a list parameter is, I've very new. I'm trying to upload a picture to show what I'm talking about but imgur is giving me issues. I do appreciate your reply and will look into list parameters and see if that may work for me.

Not currently supported as far as I'm aware. You may be able to restructure the plugin in order to avoid the need for such, and/or make use of array/struct parameters: v1.5.0+, details here.

I've encountered this in a plugin I'm (intermittently) working on. The user can define an object "type", but different types have different properties. The solution I've settled on is to allow the user to input a list/array of entries for each object type, where each type is assigned its own struct. The objects themselves are then assigned via other parameters. :kaoswt2:

Conditional plugin parameters (and numerical bounds depending on other parameters etc?) might be an interesting feature to request in that thread over on the RPG Maker MV board! Maybe someone's already suggested it, though, I haven't been following too closely. :kaoslp:
https://forums.rpgmakerweb.com/inde...ng-in-rpg-maker-would-you-like-to-see.114599/

Otherwise you could simply make it clear in the documentation how the parameters are used/ignored in given situations. :p
Thanks, I'll check out that link you posted and I may request that as well in the request boards.
 

FatalErrorDriveB

Villager
Member
Joined
Dec 12, 2019
Messages
16
Reaction score
1
First Language
English
Primarily Uses
RMMV
Sorry for double post, I meant to edit the above one.
 

TWings

The Dragon Whisperer
Veteran
Joined
Jul 26, 2017
Messages
527
Reaction score
860
First Language
French
Primarily Uses
RMMV
As I was suggesting, don't use a "total number of cards" parameter, define a "card" list parameter structure where the user can input as many cards as he wants. Your number of cards will simply be the length of this list.
You can find the details you'll need in the first link provided by Caethyril.
 

FatalErrorDriveB

Villager
Member
Joined
Dec 12, 2019
Messages
16
Reaction score
1
First Language
English
Primarily Uses
RMMV
As I was suggesting, don't use a "total number of cards" parameter, define a "card" list parameter structure where the user can input as many cards as he wants. Your number of cards will simply be the length of this list.
You can find the details you'll need in the first link provided by Caethyril.
Yeah, I think I'll do that. Thank you!

Edit: That worked, thank you so much for the guidance!
 
Last edited:

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

Latest Threads

Latest Posts

Latest Profile Posts

Haired slime? Trying some different styles of art. Maybe I can make some resources with this new kind of painting.......
i love my game very much
Uh, I'm probably overthinking this, but I think that some of my music sounds kinda...bad?
The melodies are just sort of awkward, and don't flow.
I'm really not sure what to do. Why am I even worrying about this? I don't even have a battle system yet!
And the Lord said, let there be lighting effects! And there were lighting effects! And it was good...ish? Might tweak this some more.
Today was a day of good things! Thank you fate! I pray to the darkness that those that read this will enjoy a good day as well! Power to the gam mak.

Forum statistics

Threads
105,724
Messages
1,015,913
Members
137,402
Latest member
Lopilon
Top