Setting The game takes place in the Kalos region, which was first introduced in the 2013 video games
Pokémon X and Y. The plot takes place five years after those games' events, during an
urban redevelopment project in Lumiose City, which is based on
Paris, being undertaken by a company called Quasartico, Inc. The game takes place entirely within Lumiose City, where Pokémon coexist with humans in locations known as Wild Zones. During nighttime hours, Battle Zones appear for the Z-A Royale, where trainers wander and can challenge and be challenged by the player to Pokémon battles. The player character's goal is to advance from Rank Z to Rank A via
promotion battles with certain trainers to have a wish granted. There is also a new, mysterious phenomenon within Lumiose City where wild Pokémon spontaneously Mega Evolve and go berserk. One of the player character's goals is to subdue these Rogue Mega Evolved Pokémon in the form of real-time boss battles similar to the Noble Pokémon battles within the prior title,
Pokémon Legends: Arceus.
Story Lumiose City is in the midst of an urban redevelopment project led by Quasartico Inc. to restore the city's condition after an incident involving Team Flare five years prior, creating "wild zones" where Pokémon live in the city. The player character arrives as a tourist to Lumiose City, and befriends either Taunie or Urbain (if the player selected a male or female character, respectively), who gives the player their starter Pokémon and brings them to Hotel Z, which is owned by the 3,000-year-old AZ and his Floette. The player then joins the citywide Z-A Royale tournament, where participants compete to rise from the lowest Rank Z to the highest Rank A, with those reaching Rank A being granted a wish by Quasartico. At Taunie/Urbain's request, the player also joins Team MZ, a small group of trainers based out of Hotel Z. As the player easily defeats trainers in the lower ranks, they attract the attention of Quasartico and its CEO Jett, who recruits the player to handle "Rogue Mega Evolution", a recent phenomenon in Lumiose City that causes wild Pokémon to Mega Evolve on their own. The player's rank is raised to Rank F, and they defeat multiple Rogue Mega Evolved Pokémon with Team MZ's help as they continue to progress in the Z-A Royale. In doing so, the player attracts the attention of Zygarde, a Legendary Pokémon, as well as a man known as "L" – later revealed to be former Team Flare leader Lysandre, who had survived the destruction of the ultimate weapon due to Zygarde's intervention, but was cursed with the same immortality afflicting AZ. The player must make additional effort before battling certain opponents in the Z-A Royale, such as competing in a trivia competition in order to battle
video game livestreamer Canari, helping the trainer Ivor find his sister who was hiding in the sewers, helping people throughout Lumiose City as payment after Taunie/Urbain goes into debt with the Rust Syndicate gang, and being forced to participate in a Pokémon battling tournament by the socialite Jacinthe. Prior to reaching Rank A, the player investigates Team Flare, and learns from AZ and Lysandre that a device called "Ange" within the Prism Tower building has been emitting Mega Energy, causing the Rogue Mega Evolutions. The player also learns that AZ was responsible for the construction of Ange, which was activated by Team Flare's actions in
Pokémon X and
Y. Ange is activated one night, leading Team MZ to the tower. AZ's Floette and Taunie/Urbain attempt to shut off the device, but it malfunctions and transforms the tower into a gigantic monster threatening to destroy the city. With help from the trainers the player met in the Z-A Royale, the player reaches Zygarde in the debris, and they defeat the monster by Mega Evolving Zygarde and destroying the device. AZ watches from Hotel Z as Ange is destroyed, before dying shortly after. After Ange's destruction and AZ's burial, Taunie/Urbain and the player agree to use their wishes from the Z-A Royale to restart the competition as the Infinite Z-A Royale.
Mega Dimension With the Prism Tower crisis averted, a young girl named Ansha visits Hotel Z with her companion, the Mythical Pokémon
Hoopa. Team MZ helps Ansha bake a donut that strengthens Hoopa, and she tells them that she wishes to capture a certain Legendary Pokémon for her mother. Ansha then has Hoopa open a portal to an alternate dimension called Hyperspace Lumiose, and Team MZ follows her inside. Upon their return, a distortion has appeared above Prism Tower, and Corbeau, leader of the Rust Syndicate, asks Team MZ to investigate Hyperspace Lumiose. Later, Ansha and AZ's friend Korrina join Team MZ. Team MZ completes research within Hyperspace Lumiose, and they eventually learn that Hyperspace Lumiose was created by
Darkrai, a Mythical Pokémon within the distortion above Prism Tower who had suffered from excess Mega Power exposure. With aid from other trainers in the Z-A Royale, the player, Korrina, and Taunie/Urbain enter the distortion. After encountering a dream-like manifestation of AZ and saying their goodbyes, they battle Darkrai, which undergoes Rogue Mega Evolution. The player captures Darkrai, stabilizing Hyperspace Lumiose. The next day, Corbeau identifies the Legendary Pokémon Ansha has been pursuing as
Rayquaza, and tasks Team MZ with capturing the
Hoennian Legendary Pokémon
Groudon and
Kyogre. After the player does so, Team MZ learns that Hyperspace Lumiose will make Rayquaza’s dimension appear if Ansha makes a strong wish. Ansha hears about Groudon and Kyogre, and she remembers the stories her mother told her about Rayquaza. Her wish resonates with Hyperspace Lumiose, allowing Team MZ to confront Rayquaza. Rayquaza undergoes Rogue Mega Evolution during the battle, but the player captures it. The player presents Rayquaza to Ansha, who declines taking it from them and decides to tell her mother about her adventures as well as staying in Lumiose with Team MZ. ==Development and release==