Support leaving empty slots when switching multiple mons in This happens in Doubles or Triples if, in a single turn, more pokemon faint than can switch in. This commit introduces two changes. Namely: - If more pokemon faint in a single turn than can switch in, those with the higher positions now can have switch flags on. - Passing a switch is now a valid decision that gets added to battle queue with maximum priority and disables the pokemon's switch flag.
Support leaving empty slots when switching multiple mons in
This happens in Doubles or Triples if, in a single turn, more pokemon faint than can switch in.
This commit introduces two changes. Namely:
- If more pokemon faint in a single turn than can switch in, those with the higher positions now can have switch flags on.
- Passing a switch is now a valid decision that gets added to battle queue with maximum priority and disables the pokemon's switch flag.

As a side effect, this also allows running the battle engine in JS strict mode.

kotarou3/Krister-Pokemon-Showdown,AnaRitaTorres/Pokemon-Showdown,ScottehMax/Pokemon-Showdown,JellalTheMage/PS-,lFernanl/Pokemon-Showdown,hayleysworld/asdfasdf,Enigami/Pokemon-Showdown,TheManwithskills/New-boiler-test,Zipzapadam/Server,svivian/Pokemon-Showdown,johtooo/PS,SilverTactic/Showdown-Boilerplate,Git-Worm/City-PS,psnsVGC/Wish-Server,TheFenderStory/Showdown-Boilerplate,comedianchameleon/test,svivian/Pokemon-Showdown,TheDiabolicGift/Showdown-Boilerplate,MayukhKundu/Pokemon-Domain,SkyeTheFemaleSylveon/Pokemon-Showdown,KewlStatics/Showdown-Template,PrimalGallade45/Lumen-Pokemon-Showdown,FakeSloth/Infinite,hayleysworld/asdfasdf,AustinXII/Pokemon-Showdown,QuiteQuiet/Pokemon-Showdown,TheFenderStory/Pokemon-Showdown,Irraquated/Pokemon-Showdown,Tesarand/Pokemon-Showdown,xCrystal/Pokemon-Showdown,EmmaKitty/Pokemon-Showdown,kuroscafe/Paradox,panpawn/Pokemon-Showdown,lAlejandro22/lolipoop,xCrystal/Pokemon-Showdown,SilverTactic/Pokemon-Showdown,Irraquated/Pokemon-Showdown,DesoGit/TsunamiPS,Flareninja/Lumen-Pokemon-Showdown,SerperiorBae/BaeShowdown,TheManwithskills/COC,Ridukuo/Test2,Stroke123/POKEMON,Kokonoe-san/Glacia-PS,lAlejandro22/lolipoop,Pikachuun/Touhoumon-Showdown,sama2/Universe-Pokemon-Showdown,jd4564/Pokemon-Showdown,ZestOfLife/PSserver,MasterFloat/Pokemon-Showdown,BlazingAura/Showdown-Boilerplate,Evil-kun/Pokemon-Showdown,hayleysworld/serenityc9,KewlStatics/Shit,sama2/Lumen-Pokemon-Showdown,Zarel/Pokemon-Showdown,JennyPRO/Jenny,svivian/Pokemon-Showdown,MayukhKundu/Technogear,BlazingAura/Showdown-Boilerplate,PauLucario/LQP-Server-Showdown,Pikachuun/Joimmon-Showdown,kuroscafe/Showdown-Boilerplate,Mystifi/Exiled,ehk12/coregit,Atwar/http-server-femalehq.rhcloud.com-80.psim.us-,Legit99/Lightning-Storm-Server,comedianchameleon/servertest1,MeliodasBH/boarhat,Mystifi/Exiled,Alpha-Devs/OmegaRuby-Server,SubZeroo99/Pokemon-Showdown,SerperiorBae/Pokemon-Showdown-1,xCrystal/Pokemon-Showdown,Legendaryhades/Oblivion,Firestatics/omega,Atwar/server-epilogueleague.rhcloud.com,Flareninja/Hispano-Pokemon-Showdown,Alpha-Devs/Alpha-Server,catanatron/pokemon-rebalance,Kill-The-Noise/BlakJack-Boilerplate,SerperiorBae/Pokemon-Showdown-1,AbsolitoSweep/Absol-server,hayleysworld/Showdown-Boilerplate,Kill-The-Noise/BlakJack-Boilerplate,urkerab/Pokemon-Showdown,kubetz/Pokemon-Showdown,TheManwithskills/Server---Thermal,forbiddennightmare/Pokemon-Showdown-1,jumbowhales/Pokemon-Showdown,SSJGVegito007/Vegito-s-Server,SolarisFox/Pokemon-Showdown,Neosweiss/Pokemon-Showdown,Volcos/SpacialGaze,EmmaKitty/Pokemon-Showdown,DB898/theregalias,SubZeroo99/Pokemon-Showdown,MasterFloat/Pokemon-Showdown,Celecitia/Plux-Pokemon-Showdown,lFernanl/Zero-Pokemon-Showdown,abrulochp/Dropp-Pokemon-Showdown,EienSeiryuu/Pokemon-Showdown,Adithya4Uberz/KTN,Zarel/Pokemon-Showdown,SerperiorBae/BaeShowdown,comedianchameleon/test,Pikachuun/Pokemon-Showdown,SkyeTheFemaleSylveon/Mudkip-Server,UniversalMan12/Universe-Server,gustavo515/batata,ZestOfLife/FestiveLife,SerperiorBae/Bae-Showdown,AbsolitoSweep/Absol-server,TheManwithskills/Creature-phil-boiler,abrulochp/Lumen-Pokemon-Showdown,Firestatics/Firestatics46,Darkshadow6/git-remote-add-scalingo-git-scalingo.com-pokemoonforums,SkyeTheFemaleSylveon/Mudkip-Server,lFernanl/Mudkip-Server,NoahVSGamingYT/Pokemon-Showdown,Gold-Solox/Pokemon-Showdown,AWailOfATail/awoat,arkanox/MistShowdown,TogeSR/Lumen-Pokemon-Showdown,JellalTheMage/PS-,Atwar/server-epilogueleague.rhcloud.com,Tesarand/Pokemon-Showdown,ZeroParadox/ugh,Atwar/ServerClassroom,KewlStatics/Pokeindia-Codes,sama2/Dropp-Pokemon-Showdown,Neosweiss/Pokemon-Showdown,Irraquated/Showdown-Boilerplate,Darkshadow6/PokeMoon-Creation,QuiteQuiet/Pokemon-Showdown,PS-Spectral/Spectral,comedianchameleon/test,Kokonoe-san/Glacia-PS,xfix/Pokemon-Showdown,Irraquated/EOS-Master,RustServer/Pokemon-Showdown,superman8900/Pokemon-Showdown,zek7rom/SpacialGaze,Sora-League/Sora,TheManwithskills/Dusk--Showdown,forbiddennightmare/Pokemon-Showdown-1,Tesarand/Pokemon-Showdown,Vacate/Pokemon-Showdown,TheManwithskills/COC,AustinXII/Pokemon-Showdown,Irraquated/Pokemon-Showdown,Guernouille/Pokemon-Showdown,Flareninja/Showdown-Boilerplate,Pablo000/aaa,HoeenCoder/SpacialGaze,abulechu/Dropp-Pokemon-Showdown,Nineage/Origin,abulechu/Lumen-Pokemon-Showdown,sirDonovan/Pokemon-Showdown,kuroscafe/Paradox,ankailou/Pokemon-Showdown,ScottehMax/Pokemon-Showdown,SilverTactic/Dragotica-Pokemon-Showdown,aakashrajput/Pokemon-Showdown,Zipzapadam/Server,Pikachuun/Pokemon-Showdown-SMCMDM,Yggdrasil-League/Yggdrasil,Checkinator/Pokemon-Showdown,PrimalGallade45/Lumen-Pokemon-Showdown,lFernanl/Lumen-Pokemon-Showdown,xfix/Pokemon-Showdown,bai2/Dropp,SerperiorBae/PokemonShowdown2,TheManwithskills/DS,panpawn/Gold-Server,PS-Spectral/Spectral,ZeroParadox/ugh,ZeroParadox/BlastBurners,sama2/Universe-Pokemon-Showdown,lFernanl/Lumen-Pokemon-Showdown,Atwar/ServerClassroom,Extradeath/psserver,yashagl/pokemon,DarkSuicune/Pokemon-Showdown,LightningStormServer/Lightning-Storm,kubetz/Pokemon-Showdown,Pablo000/aaa,Breakfastqueen/advanced,SilverTactic/Showdown-Boilerplate,SerperiorBae/BaeShowdown,abrulochp/Lumen-Pokemon-Showdown,SkyeTheFemaleSylveon/Pokemon-Showdown,Flareninja/Lumen-Pokemon-Showdown,SerperiorBae/Bae-Showdown,asdfghjklohhnhn/Pokemon-Showdown,Luobata/Pokemon-Showdown,CreaturePhil/Showdown-Boilerplate,kupochu/Pokemon-Showdown,theodelhay/test,TogeSR/Lumen-Pokemon-Showdown,Parukia/Pokemon-Showdown,Flareninja/Sora,psnsVGC/Wish-Server,Bryan-0/Pokemon-Showdown,Thiediev/Pokemon-Showdown,Ridukuo/Test,MayukhKundu/Technogear,TheManwithskills/Creature-phil-boiler,SerperiorBae/Pokemon-Showdown-1,Ransei1/Alt,Raina4uberz/Light-server,Flareninja/Sora,Elveman/RPCShowdownServer,Volcos/SpacialGaze,ShowdownHelper/Saffron,Enigami/Pokemon-Showdown,CharizardtheFireMage/Showdown-Boilerplate,Breakfastqueen/advanced,ehk12/coregit,Pikachuun/Joimmon-Showdown,UniversalMan12/Universe-Server,DesoGit/Tsunami_PS,KewlStatics/Alliance,TheManwithskills/Server,TheDiabolicGift/Lumen-Pokemon-Showdown,Darkshadow6/git-remote-add-scalingo-git-scalingo.com-pokemoonforums,Hidden-Mia/Roleplay-PS,Kenny-/Pokemon-Showdown,ZestOfLife/FestiveLife,JennyPRO/Jenny,Johto-Serverr/Werfin-Boilerplate,SolarisFox/Pokemon-Showdown,ZeroParadox/BlastBurners,AvinashSwaminathan/lotus-v2,megaslowbro1/Showdown-Server-again,SerperiorBae/Bae-Showdown-2,Extradeath/psserver,Vacate/Pokemon-Showdown,yashagl/pokecommunity,Kill-The-Noise/BlakJack-Boilerplate,Pokemon-Devs/Pokemon-Showdown,Flareninja/Showdown-Boilerplate,sirDonovan/Pokemon-Showdown,FakeSloth/wulu,DarkSuicune/Kakuja-2.0,zczd/enculer,ehk12/bigbangtempclone,hayleysworld/serenityserver,SerperiorBae/Bae-Showdown-2,yashagl/pokemon-showdown,KewlStatics/Shit,Kevinxzllz/PS-Openshift-Server,Yggdrasil-League/Yggdrasil,EienSeiryuu/Pokemon-Showdown,Bryan-0/Pokemon-Showdown,MayukhKundu/Mudkip-Server,gustavo515/test,Celecitia/Plux-Pokemon-Showdown,Oiawesome/DPPtServ2,TheManwithskills/Server---Thermal,Mystifi/Exiled,Parukia/Pokemon-Showdown,Nineage/Showdown-Boilerplate,jumbowhales/Pokemon-Showdown,scotchkorean27/Pokemon-Showdown,Oiawesome/DPPtServ2,Checkinator/Pokemon-Showdown,hayleysworld/harmonia,brettjbush/Pokemon-Showdown,AWailOfATail/Pokemon-Showdown,DarkSuicune/Kakuja-2.0,LustyAsh/EOS-Master,gustavo515/gashoro,Ecuacion/Pokemon-Showdown,k3naan/Pokemon-Showdown,Guernouille/Pokemon-Showdown,hayleysworld/Pokemon-Showdown,Sora-Server/Sora,Psyientist/Showdown-Boilerplate,DesoGit/TsunamiPS,Sora-Server/Sora,panpawn/Gold-Server,TheDiabolicGift/Lumen-Pokemon-Showdown,CreaturePhil/Showdown-Boilerplate,gustavo515/test,TheFenderStory/Pokemon-Showdown,kotarou3/Krister-Pokemon-Showdown,HoeenKid/Pokemon-Showdown-Johto,DalleTest/Pokemon-Showdown,aakashrajput/Pokemon-Showdown,azum4roll/Pokemon-Showdown,MeliodasBH/Articuno-Land,BuzzyOG/Pokemon-Showdown,xfix/Pokemon-Showdown,CreaturePhil/Pokemon-Showdown,svivian/Pokemon-Showdown,DarkSuicune/Pokemon-Showdown,svivian/Pokemon-Showdown,Raina4uberz/Light-server,Sora-League/Sora,RustServer/Pokemon-Showdown,Darkshadow6/PokeMoon-Creation,Kevinxzllz/PS-Openshift-Server,megaslowbro1/Pokemon-Showdown-Server-for-megaslowbro1,LegendBorned/PS-Boilerplate,DesoGit/Tsunami_PS,Git-Worm/City-PS,abulechu/Lumen-Pokemon-Showdown,InvalidDN/Pokemon-Showdown,AWailOfATail/Pokemon-Showdown,Flareninja/Hispano-Pokemon-Showdown,MeliodasBH/boarhat,VoltStorm/Server-pokemon-showdown,TheManwithskills/serenity,QuiteQuiet/Pokemon-Showdown,PrimalGallade45/Dropp-Pokemon-Showdown,Alpha-Devs/Alpha-Server,zczd/enculer,Ransei1/Alt,hayleysworld/serenityserver,hayleysworld/Pokemon-Showdown,hayleysworld/serenity,jd4564/Pokemon-Showdown,MayukhKundu/Technogear-Final,Flareninja/Pokemon-Showdown-1,superman8900/Pokemon-Showdown,SilverTactic/Dragotica-Pokemon-Showdown,Zarel/Pokemon-Showdown,TheManwithskills/New-boiler-test,SilverTactic/Pokemon-Showdown,Firestatics/Omega-Alpha,bai2/Dropp,Flareninja/Pokemon-Showdown,Firestatics/Omega-Alpha,BuzzyOG/Pokemon-Showdown,sama2/Viridian-Pokemon-Showdown,megaslowbro1/Pokemon-Showdown,Lauc1an/Perulink-Showdown,TbirdClanWish/Pokemon-Showdown,KaitoV4X/Showdown,Ecuacion/Lumen-Pokemon-Showdown,SerperiorBae/Pokemon-Showdown,urkerab/Pokemon-Showdown,SerperiorBae/PokemonShowdown2,KewlStatics/Pokeindia-Codes,Articuno-I/Pokemon-Showdown,miahjennatills/Pokemon-Showdown,Sora-Server/Sora,theodelhay/test,hayleysworld/harmonia,UniversalMan12/Universe-Server,megaslowbro1/Pokemon-Showdown-Server-for-megaslowbro1,JellalTheMage/Jellals-Server,urkerab/Pokemon-Showdown,danpantry/Pokemon-Showdown,SerperiorBae/Bae-Showdown,danpantry/Pokemon-Showdown,Nineage/Origin,Darkshadow6/PokeMoon-Creation,Werfin96/Ultimate,KewlStatics/Alliance,panpawn/Pokemon-Showdown,abulechu/Dropp-Pokemon-Showdown,MayukhKundu/Flame-Savior,CreaturePhil/Pokemon-Showdown,azum4roll/Pokemon-Showdown,TheManwithskills/serenity,Ridukuo/Test2,Darkshadow6/git-remote-add-scalingo-git-scalingo.com-pokemoonforums,Flareninja/Pokemon-Showdown,Parukia/Pokemon-Showdown,MasterFloat/LQP-Server-Showdown,ShowdownHelper/Saffron,sama2/Viridian-Pokemon-Showdown,Flareninja/Pokemon-Showdown-1,ShowdownHelper/Saffron,Stroke123/POKEMON,yashagl/pokemon-showdown,AnaRitaTorres/Pokemon-Showdown,Irraquated/Showdown-Boilerplate,LustyAsh/EOS-Master,lFernanl/Pokemon-Showdown,Alpha-Devs/OmegaRuby-Server,panpawn/Gold-Server,Flareninja/Sora,gustavo515/final,yashagl/pokemon,Wando94/Spite,yashagl/yash-showdown,jumbowhales/Pokemon-Showdown,InvalidDN/Pokemon-Showdown,Sora-League/Sora,anubhabsen/Pokemon-Showdown,ankailou/Pokemon-Showdown,lFernanl/Zero-Pokemon-Showdown,SerperiorBae/Bae-Showdown-2,comedianchameleon/servertest1,Lord-Haji/SpacialGaze,megaslowbro1/Pokemon-Showdown,BuzzyOG/Pokemon-Showdown,TheManwithskills/Dusk--Showdown,Enigami/Pokemon-Showdown,CharizardtheFireMage/Showdown-Boilerplate,Disaster-Area/Pokemon-Showdown,ehk12/bigbangtempclone,brettjbush/Pokemon-Showdown,DB898/theregalias,HoeenCoder/SpacialGaze,zek7rom/SpacialGaze,anubhabsen/Pokemon-Showdown,SerperiorBae/Pokemon-Showdown,AWailOfATail/Pokemon-Showdown,Enigami/Pokemon-Showdown,Extradeath/advanced,Wando94/Spite,k3naan/Pokemon-Showdown,hayleysworld/Showdown-Boilerplate,Evil-kun/Pokemon-Showdown,MasterFloat/LQP-Server-Showdown,KaitoV4X/Showdown,ehk12/clone,kupochu/Pokemon-Showdown,catanatron/pokemon-rebalance,johtooo/PS,LegendBorned/PS-Boilerplate,megaslowbro1/Showdown-Server-again,Ecuacion/Pokemon-Showdown,ZestOfLife/PSserver,Extradeath/advanced,javi501/Lumen-Pokemon-Showdown,TheManwithskills/DS,SSJGVegito007/Vegito-s-Server,Wando94/Pokemon-Showdown,LightningStormServer/Lightning-Storm,Legit99/Lightning-Storm-Server,Breakfastqueen/advanced,TheManwithskills/Server,Syurra/Pokemon-Showdown,Disaster-Area/Pokemon-Showdown,DesoGit/Tsunami_PS,Elveman/RPCShowdownServer,SerperiorBae/Pokemon-Showdown,yashagl/yash-showdown,Psyientist/Showdown-Boilerplate,MayukhKundu/Technogear-Final,NoahVSGamingYT/Pokemon-Showdown,MayukhKundu/Mudkip-Server,TheDiabolicGift/Showdown-Boilerplate,Ecuacion/Lumen-Pokemon-Showdown,Lauc1an/Perulink-Showdown,gustavo515/batata,TheFenderStory/Showdown-Boilerplate,Gold-Solox/Pokemon-Showdown,aakashrajput/Pokemon-Showdown,kuroscafe/Showdown-Boilerplate,yashagl/pokecommunity,Syurra/Pokemon-Showdown,asdfghjklohhnhn/Pokemon-Showdown,hayleysworld/serenityc9,BasedGod7/PH,Firestatics/Firestatics46,cadaeic/Pokemon-Showdown,Articuno-I/Pokemon-Showdown,Lord-Haji/SpacialGaze,sama2/Lumen-Pokemon-Showdown,Ridukuo/Test,piiiikachuuu/Pokemon-Showdown,MayukhKundu/Pokemon-Domain,gustavo515/gashoro,MeliodasBH/Articuno-Land,CreaturePhil/Showdown-Boilerplate,PrimalGallade45/Dropp-Pokemon-Showdown,ehk12/clone,LightningStormServer/Lightning-Storm,Lord-Haji/SpacialGaze,piiiikachuuu/Pokemon-Showdown,PS-Spectral/Spectral,PauLucario/LQP-Server-Showdown,miahjennatills/Pokemon-Showdown,Atwar/http-server-femalehq.rhcloud.com-80.psim.us-,Chespin14/Custom-Platform-Pokemon-Showdown,FakeSloth/Infinite,AustinXII/Pokemon-Showdown,xfix/Pokemon-Showdown,abrulochp/Dropp-Pokemon-Showdown,Pokemon-Devs/Pokemon-Showdown,scotchkorean27/Pokemon-Showdown,AvinashSwaminathan/lotus,AWailOfATail/awoat,KewlStatics/Showdown-Template,TbirdClanWish/Pokemon-Showdown,Pikachuun/Pokemon-Showdown-SMCMDM,gustavo515/final,DalleTest/Pokemon-Showdown,Hidden-Mia/Roleplay-PS,Firestatics/omega,sama2/Dropp-Pokemon-Showdown,HoeenCoder/SpacialGaze,xfix/Pokemon-Showdown,Pikachuun/Pokemon-Showdown,JellalTheMage/Jellals-Server,AvinashSwaminathan/lotus-v3,cadaeic/Pokemon-Showdown,sirDonovan/Pokemon-Showdown,AvinashSwaminathan/Pokelegends,Irraquated/EOS-Master,MayukhKundu/Flame-Savior,hayleysworld/serenity,HoeenCoder/SpacialGaze,arkanox/MistShowdown,Wando94/Pokemon-Showdown,javi501/Lumen-Pokemon-Showdown,lFernanl/Mudkip-Server