How many switches are too many switches?

Nephilium

Veteran
Veteran
Joined
Jul 14, 2015
Messages
32
Reaction score
7
Primarily Uses
Hey all,

So, just as I'm plugging away at my game I had this thought. Am I making too many or to little switches? I don't know if I'm overthinking this. I feel like there is some merit to my thoughts on it, but I'd like others opinions too.

It seems like you can have have A LOT of switches in your game. The highest it looks like 9999, which is obviously just ridiculous. As I work along I like to have all of my things flow consistently along with the story. Maps are in order I plan the player to visit, switches are in order, tilesets you'll visit are in order, etc. I just like to keep organized.

That being said, I like to try and keep the switches usage to a minimum, mostly because I know they're powerful and can really mess something up. I think my concern comes from "Well if I have 100 switches, I'll forget what does what, and if something is left on or off it'll cause so many issues down the road, etc., etc...". With that being said, my switches are not in order anymore because so many times I've come up with new ideas or got inspired by something I saw and realized the player would encounter it much sooner in the order where it falls in the switches list. With that in mind, I've tried to limit my uses of switches because:

A. Have less to remember for what switch does what
B. Keep the switches more organized and flow with the story
C. Have less chance of the switches causing unforeseen issues by being left on/off or not turned on/off
D. This one is total speculation, but I don't know how much switches would bog down the game if too many are active, or what, if any ramifications would happen by having too many switches active, or not.

So, I've tried to use other methods in the meantime. Self-Switches, Variables, etc. but I want to know if I can stop worrying about having more switches. I do have them, I just worry that I'm making it harder on myself but not utilizing them as much as I can. The worst thing is I forget what does what.

Some steps I think I might do in the future is to have a spreadsheet in the separate excel database I keep of the game as I work that lists the switches and a comment on what it does. Or, have each switch group of 20 assigned to a map, with others being grouped into Misc, like maybe doors, or whatnot.

This turned out to be longer than I thought. Lol.

TL;DR - Do you like to have a lot, or little switches in your game? Does having a lot of switches cause any unforeseen issues you've encountered?
 

Hudell

Dog Lord
Veteran
Joined
Oct 2, 2014
Messages
3,544
Reaction score
3,714
First Language
Java's Crypt
Primarily Uses
RMMZ
As long as you don't forget what each one does and start using the wrong ones, there's no harm in having 9999 switches.
 

Kes

Veteran
Veteran
Joined
Aug 3, 2012
Messages
22,294
Reaction score
11,710
First Language
English
Primarily Uses
RMVXA
The only honest answer to "how many switches?" is - as many as your game needs and no more.

If you name each switch with something descriptive, that can help a lot with remembering what they do. For example, here are a few of mine.
1600100936620.png

Having many switches does not, in itself, cause lag.
 

ShadowDragon

Veteran
Veteran
Joined
Oct 8, 2018
Messages
2,803
Reaction score
983
First Language
Dutch
Primarily Uses
RMMV
you can categorize with switches ith 5 open space in between if you every need to add 1

---- Main Town -----
switches used here

---dungeon1---- (or chapter 1)
switches used here

--- dungeon 2----
switches here

and continue like those as you make switches when you need them.
you can find those switches also faster back in case there is a switch error in a specific dungeon.
so you can fix that faster without searching for the switch.

but there are also different ways of organizing, like comments on the event page BEFORE using
a specific switch, like comment: switch to activate platform 1, 3 and 5, else 2, 4 and 6
depending on the mechanic you used and puzzle (if included) or doors etc.
 

Oddball

Veteran
Veteran
Joined
Sep 4, 2014
Messages
1,923
Reaction score
531
First Language
English
Primarily Uses
N/A
you can categorize with switches ith 5 open space in between if you every need to add 1
I do this too and with variables. But sense i don't like waste, I use the category switch/variable as well. For example, in my variables i have a category variable ~Battle~ and I use that when i need a random variable in a common event attached to a skill
 

Uzuki

Kawaii on the streets, Senpai in the sheets
Veteran
Joined
Aug 18, 2012
Messages
1,933
Reaction score
1,325
First Language
English
Primarily Uses
RMMV
I don't know what engine you're using but find a script or plugin that that allows you toggle self switches with a command. It helps a lot when you just need to change to one page for one event, but don't want to add a switch name to your ever growing list. Now I can just use regular switches for story related stuff or having to change multiple events at once. Only time it gets confusing is when you have to do a puzzle area with a lot of events and have to remember the event names and how it should all work.
 

rpg_el

Veteran
Veteran
Joined
Sep 3, 2020
Messages
83
Reaction score
35
First Language
English
Primarily Uses
RMMZ
I'm honestly slightly worried I could hit the 9999 limit one day. But in general, I think the main problem with many switches is just that the editor doesn't easily assist with moving switch slots (as suggested by me here) so that it becomes unwieldy and borderline impractical to keep it in nice, separate ranges by area or category in the long run. Otherwise, there is no real reason to limit yourself on switches.
 

ShadowDragon

Veteran
Veteran
Joined
Oct 8, 2018
Messages
2,803
Reaction score
983
First Language
Dutch
Primarily Uses
RMMV
you can bypass 9999 switches, better yet, a full game can be made with only 20-40 switches
in total if you do it right, name "Selfswitches" by yanfly SelfSwVar which has it's own switch,
in the event, the downside maybe of this, you cant use a scriptcall to turn swithc 4 ON
on a specific event, not sure if selfswitch counts, but also ment for more advance users :)

anyone has their own way for caterize switches and variables, some are more comfortable in
using it wisely and get the same result in less switches than most could do (which require JS).

but there are ways to use some switches to use over and over, as an example,
use switch 1 -20 for re-useable and a scriptcall to turn all of them OFF :)
 

rpg_el

Veteran
Veteran
Joined
Sep 3, 2020
Messages
83
Reaction score
35
First Language
English
Primarily Uses
RMMZ
@ShadowDragon that seems pretty hacky especially given not all things taking switches might recognize this, so I'd rather not. Nice that options exist out there though.

I think if I ever hit the 999 limit I'll ask support nicely about it, and who knows, maybe it'll be raised. My guess is that it's mostly arbitrary anyway, the corescript doesn't seem to have a fundamental limit (other than 32bit signed integer max maybe, which would be millions) and the switch selector dialog seems to be fundamentally able to basically display an arbitrary amount if need be, so I assume it'd be not that challenging to raise it if there is actual user demand. I assume that it wasn't ever raised mostly just means nobody really ever asked for it, which is fair.
 

Kes

Veteran
Veteran
Joined
Aug 3, 2012
Messages
22,294
Reaction score
11,710
First Language
English
Primarily Uses
RMVXA
Following up the suggestion of @Uzuki you don't in fact need a script or a plugin to toggle self switches with a command, it's a very simple script call. Using that will indeed save you a lot of global switches. I use that script call very regularly.

I'm also a great fan of having a few switches and variables named TEMP 1, TEMP 2, etc which I use for when I need something specific, but perhaps only need it for a limited time. For example, if you want something to happen when your boss reaches x% of HP, you have to set a variable to that HP and then call it at the beginning of each turn. You're never going to need that data again, so using a temp switch deals with it nicely.
 

Nephilium

Veteran
Veteran
Joined
Jul 14, 2015
Messages
32
Reaction score
7
Primarily Uses
I'm using MV by the way, for whoever asked!

So many good suggestions here! I mean, honestly, I barely have any switches in my game yet simply because I'm still working on the game. Less than 25 right now. I'm just thinking big picture. I know I have many switches to come, I just wanted some opinions on what others did to help navigate the growing list.

I do try and name them to what their purpose is, and try and stay consistent in the name process. For example I like to show the image of the boss on screen before the battle, or certain things happen when the bosses are defeated so the switches are called "Boss Name Reveal" and "Boss Name Defeated".

I wish that I could freely rearrange my switches without breaking anything. I think that alone would solve my biggest concern with them.
 

rpg_el

Veteran
Veteran
Joined
Sep 3, 2020
Messages
83
Reaction score
35
First Language
English
Primarily Uses
RMMZ
@Nephilium yes, rearranging is what I also miss the most. I did suggest that feature for MZ as linked above, simply because I'm not sure MV will still be updated officially beyond patches. But obviously it'd be useful for any of the makers, not only the latest one.
 

Kes

Veteran
Veteran
Joined
Aug 3, 2012
Messages
22,294
Reaction score
11,710
First Language
English
Primarily Uses
RMVXA
To avoid rearranging switches, there are a few things that you can do, though it is too late for your current project.

I always leave the first 20 switches for what I think of as 'standard needs'. So things like turning a weather system ON or OFF or something in a lighting system. Because in my current project Escape is a skill, not a battle command, I have a switch which disables that skill for boss battles. These will be highly game specific, as no two games need the same set. Switches 21-25 can be the TEMP switches I mentioned in an earlier post. If you don't need all of them, nothing lost. A blank slot does not affect the game.

The same with variables that I think I will need repeatedly.

When I move on to a new location, I like to leave a couple of blanks in case I need to go back and add something. e.g. I decide that I could do something or have a dialogue choice if I knew whether the player had done X ot not. I can go back and put in a switch at X and then use a conditional to see if that switch is ON or OFF. Very useful if the X is optional in any way.
 

Nephilium

Veteran
Veteran
Joined
Jul 14, 2015
Messages
32
Reaction score
7
Primarily Uses
@Kes Yeah, I think using the first 20 for standard things is a good idea. I think for my next project I'll do that, but then assign the switch groupings to maps. I think having 19(the first one being the title of the map for identification) switches per map is a good start anyway.
 

AeroPergold

Veteran
Veteran
Joined
Feb 3, 2014
Messages
47
Reaction score
51
First Language
English
Primarily Uses
RMMZ
I organize my switches in banks. So one page is dedicated to sidequest switches/ plot related event switches/ Level switches and so on.

Something like this:
bandicam 2020-09-15 21-52-24-218.jpg

Its okay to have more switches than the Earth's human population, just make sure everything is neatly organized.

Also organize your switches early in development! Should save some headache later on.
 

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

Latest Threads

Latest Posts

Latest Profile Posts

People1.png & SF_People1.png added!!!!

Adventurer:
"Why your body looks like a bird?"

Stranger:
"Because I'm harpy"

Adventurer:
"Clap along if you feel like a room without a roof"

*Both dancing to Pharrell Williams song*
Stream will be live shortly with a make-up session of the Interactive Text Adventure! Feel free to drop by!
Pootscooter wrote on Pharonix's profile.
Hey @Pharonix, just wondering what you're up to lately and if you've had an opportunity to check out the LTBS thread in the past few days...(a couple of us could really use your expertise). Hope you are well and Happy Thanksgiving!

Forum statistics

Threads
105,506
Messages
1,014,262
Members
137,173
Latest member
zoetsoi
Top