After changing course on a contract to return to the Dallas Mavericks, guard Yogi Ferrell has agreed to a two-year, $6.2 million deal to sign with the Sacramento Kings.

Ferrell is known as a good locker-room presence and is a fit in the backcourt. The 6-foot guard talked to Kings general manager Vlade Divac and assistant general manager Brandon Williams before making his decision. The Kings believe Ferrell will play a critical role in their uptempo style of play around a talented young core of Harry Giles, De’Aaron Fox and Marvin Bagley III.

“I heard the vision and optimism from Vlade and Brandon, and got a view of the culture and direction from veterans I look up to, and that was impactful,” Ferrell told Yahoo Sports. “I see the explosive potential from a starving young group that wants to open the floor up with more shooting and play with speed and smarts.

“I’m excited about the opportunity to grow with this team and I can’t wait to bring my heart to Sacramento.”

Ferrell’s representatives informed the Mavericks on Friday morning of his decision to change course on a two-year, $5.3 million deal. Ferrell had interest from several teams, including New Orleans and Cleveland, before coming to terms with the Kings.

He had a $2.9 million qualifying offer with the Mavericks rescinded on July 13.

Ferrell, 25, joined the Mavericks on a 10-day contract in January 2017, one month after the Brooklyn Nets waived him. Ferrell was an instant success and had a performance of 32 points with nine 3-pointers against the Portland Trail Blazers on Feb. 3, 2017, leading to a two-year deal.

In 82 games last season, Ferrell averaged 10.2 points, three rebounds and 2.5 assists per game.

Ferrell went undrafted in 2016 after a standout career at Indiana University.

More from Yahoo Sports:

• This has to be the worst blown call in baseball history

• Tiger Woods nearly annihilates British Open spectators

• NFL won’t enforce anthem policy as NFLPA works with league on solution

• Mannix: It’s now up to Melo to decide how the rest of his career plays out

