To get a better shot at winning at the NBA’s best team Thursday night, the Suns needed to save some of their legs with a solid effort Wednesday night against the league’s worst team.

Goran Dragic’s All-Star-quality effort ended up being good enough as the Suns were pushed for four quarters.

Dragic scored 30 points in 24 minutes, the 24 minutes of the game that the Suns outscored Milwaukee by 20 at Bradley Center in a 126-117 victory that set a new Suns season scoring high.

On the eve of All-Star Game reserve announcements, Dragic’s resume for All-Star selection was updated by becoming the fourth NBA player in the past six seasons to score 30 in 24 minutes or fewer. His star shined because he was clutch and tough, as he scored 13 consecutive Suns points down the stretch to cinch the win and got the last 10 of them after injuring his left elbow on a fall.

Dragic was driving when he was fouled by Milwaukee’s John Henson and his left elbow landed first. An X-ray taken after the game was negative, but Dragic’s elbow immediately swelled after the play. He stayed in and made two free throws and then followed with 3-point shots on the next two trips to build the Suns’ lead to 16 with 2:12 to go.

“Emotions,” Dragic said. “You’re so much in the zone. Adrenaline keeps going.”

Dragic’s elbow became more swollen and sore after the game. It is a concern because he has fallen on that elbow previously this season and fractured it as a teenager.

Suns coach Jeff Hornacek was trying to get through the night without taxing his star point guard too much, with the fourth road game in five nights coming Thursday night at Indiana, where the Pacers were resting Wednesday night with memories of a 24-point drubbing they took in Phoenix eight days ago.

The Suns (27-18) were in position to make quick work of Milwaukee (8-37), a team that had trailed by 35 and 39 points in its previous two games. They took a 57-34 lead in the second quarter but let it get cut to 12 by halftime, fouled heavily early in the third quarter and found themselves clinging to a five-point lead with seven minutes to go.

After committing 26 turnovers at Phoenix, Milwaukee only made nine Wednesday night to take 11 more shots and offset the Suns’ 53.8 percent shooting. Milwaukee has the league’s lowest scoring offense and is the worst shooting team, but its 117 points was a season high.