ORLANDO -- Hours before Thursday night's game Toronto Raptors coach Dwane Casey talked about teaching his young team "to make winning plays in clutch situations."
Guard DeMar DeRozan, obviously, is a quick learner.
With two defenders hanging over him, DeRozan came to the rescue, hitting a game-winning, fallaway jumper from 22 feet as time expired, leading the Raptors to a 97-95 victory over the Orlando Magic.
DeRozan scored 22 points, including 14 in the fourth quarter when the Raptors held off a late charge by the Magic at Amway Center, finally reversing their habit of losing close games.
The Raptors (16-27) were coming off an excruciating, overtime loss Wednesday night in Miami, their third overtime loss in the previous eight days.
"We've been in a lot of situations where the ball just wasn't falling for us at the end of games," DeRozan said. "It just wasn't bouncing our way. Tonight it did, and we got one."
Unheralded center Amir Johnson had 21 points and 10 rebounds for the Raptors, who had six players with at least 10 points, including Alan Anderson with 13 points.
The Magic (14-28) were led by center Nikola Vucevic with 19 points and 14 rebounds, although he was hardly a factor in the second half. Arron Afflalo had 16 points and Glen Davis scored 15. Jameer Nelson had 14 points, 11 assists and seven rebounds.
DeRozan hit seven of his eight shots in the fourth quarter. After a time-out with 4.3 seconds remaining and the score tied, DeRozan took a pass on the wing and waited for the double-team to come. He kept his dribble alive and took the fallaway shot just before time expired.
"He just made a helluva shot," Johnson said. "We've lost some close ones, but we never stopped fighting. We knew if we kept playing hard, they would start going our way. Tonight, it did."
The Magic outscored the Raptors, 29-22, in the fourth, but it was too little, too late. The Raptors led through much of the second half.
Orlando's J.J. Redick tied the game at 93 with 53 seconds remaining when he completed a four-point play, his third of the season. After DeRozan scored, E'Twaun Moore tied it at 95 with 20 seconds remaining on a short jumper.
The Raptors waited for the final shot before time expired, running their play designed for DeRozan.
"I knew if I got a good shot off, I had a chance of it going in," DeRozan said. "It was up to me to try and make something happen. This one should do a lot for us. We needed it."
The Raptors led, 48-47, at intermission after Johnson and DeRozan scored back-to-back baskets before the break. Offensively, the first half was dominated by the two starting centers.
Vucevic had 14 points and nine rebounds, while Johnson had 14 points and four rebounds before halftime. The Magic led by as many as eight points and the Raptors by six in a see-saw first half.
The Raptors made a 12-2 run at the end of the first quarter, a 10-5 run to close the second and a 13-5 flourish to close the third.
NOTES: Closing out tight games has been a huge problem lately for the Raptors, who lost in overtime in three of their previous four games before Thursday. Of their first 27 losses this season, they led in the fourth quarter 10 times. . . . The Magic don't have to look very far for the reason behind their recent collapse. In their first 25 games this season (12-13), they were allowing 94.4 points per game. In their next 16 games (2-14), they allowed 108.6 points per game. ... Afflalo must have adjusted his offensive focus Thursday night. He took three shots in the first three minutes, contrasting with Tuesday in Detroit, when he took no shots in his first 34 minutes. ... Davis played in his sixth consecutive game since returning from a shoulder injury, but he still hasn't returned to his early-season form when he was playing so well. "It just takes time," coach Jacque Vaughn said. "It takes time to get your rhythm and conditioning back." ... Magic reserve center Gustavo Ayon will be the guest of honor Friday at a reception at the Mexican Consulate in Orlando. ... Toronto's Andrea Bargnani, who missed his 21st consecutive game with a torn right elbow ligament, worked out on the court before the game. He appeared to be close to a return.