HOUSTON -- On a night when James Harden scored 48 points, which almost qualifies as ho-hum by the standards of the historic tear he's on, Eric Gordon played the hero role for the Houston Rockets.

Gordon scored 16 of his 30 points in the final two minutes of regulation and in overtime in Houston's 138-134 comeback win Saturday night over the Los Angeles Lakers.

His double-clutch 3-pointer with two seconds left in the fourth quarter tied the score, giving the Rockets a chance to steal a win in a game they trailed by 21 points in the first half and never led until Gordon swished another 3 on the opening possession of overtime.

"Eric is a big-time player and he makes those shots," Harden said. "Obviously double clutch, the difficult level was pretty high, but he has the confidence and we have the confidence in him to shoot those shots, especially closing games like that."

If Rockets coach Mike D'Antoni went by the letter of the law, Gordon wouldn't have been in the game to make those big shots due to his minutes restriction after missing eight games because of a right knee contusion.

Gordon, who returned for Wednesday's overtime loss to the Brooklyn Nets, played 32 minutes, exceeding his restriction by eight.

"They didn't explain to me about overtime," D'Antoni said jokingly. "I kept it right in regulation. Caution to the wind, baby. ... He's that good. We need him. Going forward, we'll have to have that."

It was a win the injury-ravaged Rockets desperately needed; Houston had lost four of its previous seven games despite the offensive brilliance of Harden, whose run of 19 straight 30-plus-point performances ranks as the longest in NBA history by any player other than Wilt Chamberlain.

"Hey, during that point, it's winning time," said Gordon, who scored 20 points in 21 minutes in the loss to the Nets. "You've got to do whatever it takes to win, and I've got to listen to my body also. It felt good, and I have no issues right now."

Harden was spectacular again against the Lakers, falling only two points shy of his third 50-point performance in a row. He had 15 points in the fourth quarter, including eight in the final minute of regulation, but the Rockets went to Gordon with the game on the line.

With Josh Hart denying Harden, Austin Rivers inbounded the ball to Gordon just to the right of the top of the arc. Gordon pump-faked, attempting to create some separation from Kentavious Caldwell-Pope, before hitting a leaning 3.

"I was just trying to shoot that thing with confidence," said Gordon, who was 7-of-16 from the field and 5-of-10 from 3-point range. "I saw KCP running out to me, and I thought he was going to fly right by me, but he stood right there. So I had to try to shoot it with confidence, and I'm glad it went in."

The Lakers tried to make Harden's life as difficult as possible by defending him tightly every second Houston had the ball. That sometimes meant allowing the Rockets to play 4-on-4 while Harden walked up the floor with a defender in his face.

The Lakers were determined to force other Rockets to try to beat them. That strategy certainly worked in the first half, when Harden scored 16 points on 5-of-12 shooting and the rest of the Rockets scored 30 points on 11-of-37 shooting, as the Lakers took an 18-point halftime lead. But Harden still managed to get an efficient 48 points -- shooting 14-of-30 from the field, 8-of-19 from 3-point range and 12-of-15 from the line -- and Gordon got hot just in time.

"It takes a lot of burden off me," Harden said of having Gordon back in the lineup. "He's so offensively gifted and talented -- being able to shoot the basketball, being able to get to the rim, being able to make plays for others. You get a guy like that on the floor with you, it makes the game easier not only for myself, but for everybody."