The Sacramento Kings are officially making a playoff push.

Wednesday night, as the Dallas Mavericks game against the Charlotte Hornets moved into the fourth quarter, The Athletic's Shams Charania broke news that the Kings were finalizing the acquisition of forward Harrison Barnes, and ESPN's Adrian Wojnarowski quickly followed with details of the return package, which includes Justin Jackson and Zach Randolph.

The team later announced the deal as official.

Barnes, who started in Wednesday's 99-93 victory over the Charlotte Hornets, scored 10 points in 25 minutes before being pulled with 3:11 remaining in the third quarter for Dirk Nowitzki. Per ESPN's Tim MacMahon's, Barnes stayed out on the bench supporting his teammates the rest of the way.

Nowitzki started realizing something was up when Barnes didn't replace him early in the fourth quarter as usual with the 40-year-old playing a limited role in his record 21st season with the same franchise.

Since Nowitzki credited Barnes for being a positive influence in his two-plus seasons with the Mavericks, he wasn't surprised that Barnes stuck around after word of the trade got out.

Harrison Barnes was dealt the the Kings mid-game on Wednesday night.

"He's a better man than me," said Nowitzki, who scored eight points. "Everybody else would have bounced out. He's just a genuinely good dude and he's obviously got bonds with some of these players here for life. That's the kind of guy he is."

ESPN's Paul Pierce reported on air postgame that Barnes' agent informed him being traded was a possibility, but Barnes requested to be in the gameday mix. Barnes and his agent, Jeff Schwartz, were apprised before last night's game that Barnes was being pursued by the Kings and Hornets, reports Marc Stein of The New York Times. The Kings' offer won out as Barnes opted to play against the Hornets.

.@paulpierce34 says Harrison Barnes knew a trade to the Kings was in the works prior to the game, and still wanted to play for the Mavericks Wednesday. pic.twitter.com/06wuxZERBC — NBA on ESPN (@ESPNNBA) February 7, 2019

Harrison Barnes and agent Jeff Schwartz were apprised before Wednesday's game that Barnes was being pursued by Sacramento and Charlotte, league sources say. The Kings' offer won out and Barnes, as explained by Paul Pierce late last night on ESPN, opted to play rather than sit — Marc Stein (@TheSteinLine) February 7, 2019

The Kings, just a game out of the eighth spot after a 12-season playoff drought, reportedly made the deal with long-term intent. Barnes currently holds a max-contract player option for 2019-20.

The seventh-year forward, originally drafted No. 7 overall by Golden State before signing with the Mavericks in 2016, has averaged 18.8 points and 5.2 rebounds while shooting 44.5 percent (36.7 percent on 3-pointers) in 34.3 minutes over 204 games for Dallas.

Rick Carlisle raved about Harrison Barnes being a “model pro” and wished him the best at his next stop. pic.twitter.com/LXaIQPp1fO — Tim MacMahon (@espn_macmahon) February 7, 2019

Barnes later posted an effusive thank you message on Twitter, writing that the team, executives, and fanbase all "made Dallas feel like home."

The Mavericks, meanwhile, acquire Randolph's high-value expiring contract and Jackson, the No. 15 overall pick of the 2017 draft. The deal is expected to create enough cap space to allow for close to a max salary slot even after a recent trade that pairs Kristaps Porzingis with rookie sensation Luka Doncic. Per ESPN's Bobby Marks, they hold more than $13 million in room through June 30.

Jackson has appeared in 52 games for the Kings this season, averaging 6.7 points while shooting 42.4 percent from the field and 34.6 percent from deep.

Wojnarowski further reported that Randolph, who has yet to play this season, could become a free agent if he doesn't fit with the Mavericks plans. The Mavs are not necessitating that Randolph report to Dallas and he appears headed for the buyout market, per Stein.

Information from The Associated Press was used in this report.