ORLANDO, Fla. -- Now 57 games into his NBA career, Victor Oladipo does not look like a rookie anymore. And he does not sound like one, either. His confidence is growing.

Oladipo, the No. 2 pick in the 2013 NBA Draft from Indiana, had 30 points, 14 assists and nine rebounds while carrying the Orlando Magic to a 129-121 double-overtime victory over the New York Knicks on Friday night.

Teammate Arron Afflalo had 32 points, but he exited the game with 2:23 remaining because of a sprained right ankle, leaving Oladipo to finish the job.

In the best performance of his budding career, Oladipo overshadowed the 44-point effort of Knicks All-Star Carmelo Anthony, outplaying him when it mattered most.

Oladipo, starting for the first time in almost three weeks, had eight points and two rebounds in the decisive second overtime. He scored nine points in the fourth quarter when he forced the first overtime.

"No question, I've come a long way. But I'm not even scratching the surface right now of what I can do," he said. "I want to be the greatest that's ever played this game. My goal is pretty simple."

Oladipo made it look simple when he dominated the game. He had only five points and four assists at halftime, then shifted into a higher gear, leading the Magic through their comeback victory.

"He wants to be the best. You can see that in him," Magic veteran guard Jameer Nelson said. "He's got a motor that no one else has. He's just beginning, but he's getting better and better pretty quickly."

Anthony, who had 30 points with three minutes remaining in the third quarter, made 16 of 28 shots from the field overall. He was coming off a 42-point effort in Wednesday's victory.

Anthony hit two 3-point shots in the second overtime, but it was Oladipo's two three-point plays that won the game.

"He was special tonight," Magic coach Jacque Vaughn said. "It was fun to be a part of. He was good in a lot of ways."

The Magic (17-40) snapped an eight-game losing streak to the Knicks (21-34), who are desperate to stay in contention for a playoff berth.

"Every game now is important," Knicks coach Mike Woodson said. "It's a tough loss. I thought we fought hard, but we have to be better defensively. They made their run in the fourth and we couldn't get it back."

Magic forward Tobias Harris had 22 points and eight rebounds. Center Nikola Vucevic had 14 points and a game-high 15 rebounds.

The Knicks got 15 points and eight assists from guard Raymond Felton and 14 points and 11 rebounds from center Tyson Chandler.

The Magic had a chance to win at the end of the first overtime, but Vucevic missed a short, heavily contested shot just before the buzzer sounded. He missed the final shot, also heavily contested, at the end of regulation.

Chandler lost two points with 1:04 remaining in the first overtime, with the score tied at 113, when his dunk was waved off by officials because of his own basket interference.

The Magic, sparked by Oladipo, outscored the Knicks 27-20 in the fourth quarter and forced the overtime after trailing by as many as 14 points in the third quarter.

The Magic tied the score at 106 with a jumper by Afflalo with 39 seconds remaining in regulation. Anthony committed a turnover when he stepped out of bounds with 22 seconds remaining, leaving the Magic with a final opportunity. Vucevic missed on a running, fallaway jumper just before the buzzer sounded, sending the game into overtime.

The Magic took their first lead of the second half at 98-96 when forward Maurice Harkless hit a short jumper with 5:27 remaining, capping a 10-0 burst that included a 3-pointer by guard E'Twaun Moore.

The Knicks answered with a basket by Anthony and 3-pointer by Felton for the 101-98 lead, but it was far from over.

The Knicks led by as many as 14 points in the third quarter, but the Magic cut the deficit to seven when Oladipo scored the last four points of the quarter.

Anthony had 19 points and seven rebounds at halftime when the Knicks led 60-53. The Knicks closed the second quarter with a 19-6 run, including the final six by Anthony.

Afflalo also had a big first half with 18 points, including 14 in the first quarter when he hit all three of his 3-point shots. The Magic led by as many as seven points in the second quarter.

The Knicks shot 57.5 percent from the field (23 of 40) in the first half.