The makeup of the Wizards is appealing to Paul Pierce, who believes the young ballclub is capable of making even more noise in the NBA playoffs in 2015. (Tom LeGro/The Washington Post)

In the wee hours Sunday morning, Paul Pierce was spotted outside the nightclub Hyde at the Bellagio hotel with a hat tilted to the side, an unlit cigar in his mouth and huge grin on his face. Pierce was in a noticeably good mood after making a startling decision that immediately changed the perception of an organization not typically known for attracting future Hall of Fame talents.

With one short message on Twitter — “Obama, [John] Wall here I come” — Paul declared that he felt the Washington Wizards were the team that gave him the best opportunity to continue his pursuit of another championship. The Wizards officially became a destination in luring Pierce with a two-year deal contract worth the full mid-level exception of $10.8 million — and it wouldn’t have happened without a defection.

Neither Pierce nor the Wizards knew they would really come together until Trevor Ariza informed the team Saturday afternoon he was leaving to join the Houston Rockets.

Washington was disappointed but hardly shaken when Ariza chose to accept the same four-year, $32 million contract offer in Houston, where the 29-year-old could pocket more money because the state doesn’t tax income. The phrase voiced by several people within the organization: “We’ll be fine.”

Within six hours, the Wizards made a quick recovery and avoided public scorn for losing a player they supposedly prioritized in free agency by acquiring a 10-time all-star and former NBA Finals MVP.

The Wizards could sit back and act as if they had Pierce lined up as a replacement all along. But according to people with knowledge of the situation, the bold addition required a perfect storm of a team that refused to settle for just the next-best serviceable option and a decorated, veteran player who was running out of attractive options.

Needing to cover themselves in case Ariza left, the Wizards had been in frequent contact with the representatives for some of the top available swingmen. They had reached out to Luol Deng, Marvin Williams, Caron Butler and others in the first few days of the free agent negotiating period and met with Thabo Sefolosha at Verizon Center.

The Wizards didn’t reach out to Pierce’s agent, Jeff Schwartz, until last week to express their interest and gauge if the feeling was mutual. Eventually, Wizards President Ernie Grunfeld and Coach Randy Wittman spoke to Pierce and sold him on what the franchise was building with a rising back court in all-star John Wall and Bradley Beal and a formidable front line with Nene and Marcin Gortat. A few players also reached out via text messages.

Pierce had been impressed with the Wizards last season, when they beat out his Brooklyn Nets for the fifth seed in the Eastern Conference and won a playoff series for the first time in nine years. After the Wizards swept the season series with the Nets last March, Pierce praised the team for how far it had come from being a perennial lottery-bound loser.

“They’re good,” Pierce said at the time. “They’re coming into their own. They’re growing up right before our eyes. You’ve seen their struggles over the years, and John Wall has matured as a player, obviously, becoming an all-star this year and taking on more responsibilities and becoming a leader for this ballclub. That’s what the Washington Wizards have been waiting on, and you’re seeing it.”

But even with that, the Wizards still needed something or someone to close the deal. And that’s where assistant coach Sam Cassell entered the picture.

Immediately after coaching the Wizards to a 90-74 summer league victory, Cassell got on the phone with his former teammate in Boston and convinced Pierce of the talent on Washington’s roster, according to a person with knowledge of the situation. Pierce’s friendship with Cassell contributed to his trust that the Wizards could make some moves in a wide-open East that was leveled with LeBron James’s reverse decision to leave Miami and go back home to the Cleveland Cavaliers.

Pierce had longed for a return to his home town of Los Angeles, where he could reunite with Clippers Coach Doc Rivers, with whom he won a title for the Boston Celtics in 2008. But the Clippers had used the mid-level exception on Spencer Hawes and couldn’t sign him to the kind of deal that he wanted. Pierce and the Brooklyn Nets were both looking to part ways after one season together failed to produce a title.

After speaking with Cassell, Pierce didn’t immediately commit. He ran into a few members of the Wizards organization at the Canelo Alvarez and Erislandy Lara fight at MGM Grand and still hadn’t made up his mind. After the fight, Pierce called the Wizards to let them know that he was coming.

If the Wizards hadn’t defeated the Chicago Bulls in the first round and come within two games of the conference finals, they wouldn’t have been able to attract a player of Pierce’s caliber. They aren’t looking for the 36-year-old Pierce to carry the same offensive load that he had grown accustomed to in 15 years in Boston, where he scored 24,021 points, the most by any player to don a Celtics uniform outside of John Havlicek.

Washington is hoping that Pierce can mentor Wall and Beal and take some pressure off 2013 third overall pick Otto Porter Jr. as he possibly moves into a new role as a rotation player.

Note: The Wizards completed a three-team trade with Houston and New Orleans. As part of the deal, the Wizards signed Ariza and sent him to the Rockets. In return, they received an $8.5 million trade exception and the non-guaranteed contract of forward Melvin Ely, according to people with knowledge of the situation.