Just when things looked the darkest, Rocco Becht delivered to keep Iowa State unbeaten.

Becht directed three long second-half scoring drives and punched in the game-winning touchdown himself with 30 seconds left, lifting the ninth-ranked Cyclones to a 38-35 victory over UCF on Saturday night in a thriller at MidAmerican Energy Field at Jack Trice Stadium.

Iowa State rallied from a 28-14 deficit early in the second half to move to 7-0 overall, matching the best start in school history, and 4-0 in the Big 12. The 1938 team also started 7-0. It's the first ever 4-0 conference start for an ISU team.

Becht overcame two costly interceptions to finish with 371 total yards, including a career-high 97 on the ground and two TDs.  He led touchdown drives of 75 and 76 yards to draw the Cyclones to 28-27 and then, with UCF leading 35-30, took the Cyclones 80 yards in 11 plays after getting the ball with just 1:48 left.

Completions of 29 and 16 yards to Jaylin Noel put the Cyclones in striking distance and a pass interference penalty gave them a first down at the UCF 4. After an incomplete pass, Becht ran for 3 yards and then the final 1 for the touchdown. His 2-point conversion run made it a three-point game.

Jontez Williams' interception with 8 seconds left – his fourth straight game with a pick -- sealed the victory in the first meeting between the two schools.

Becht finished 20 of 46 for 274 yards and a touchdown, the 11th straight game in which he has passed for at least one score. His scrambling also was a big factor and he finished with 97 yards in 20 carries, part of a 530-yard outburst by the Cyclones, who are idle next week before hosting Texas Tech on Nov. 2.

This one definitely was not easy. UCF (3-4, 1-3) came in with the No. 1 rushing attack in the league and piled up 354 yards on the ground, the most against ISU since Baylor ran for 469 on Oct. 1, 2016.

But the Cyclones have shined in the second half all season and they did it again, holding the Knights to 133 rushing yards over the final two quarters and limiting RJ Harvey to 12 yards in nine carries. That was after Harvey rambled for 178 yards in the opening half, including an 80-yard run on which he went untouched to the end zone to tie the game at 14 early in the second half.

The Knights also scored on quarterback Jacurri Brown's 67-yard run, which made it 28-14, and Brandon Adams returned an interception 63 yards for a touchdown that put UCF up 21-14 late in the first half.

Brandon Marshall's 70-yard interception off Becht early in the second half put the Knights at the ISU 1 and Harvey scored on the next play for a 35-27 lead. Kyle Konrardy's 30-yard field goal cut the lead to 35-30, setting the stage for Becht's late heroics.

But the defense had to come through first and it did, stopping the Knights at the ISU 44 and forcing a punt. Another UCF first down at that point probably would have ended the game.

Becht also scored on a 1-yard to cap the first drive of the second half and finished the next one with a 12-yard TD pass to Jayden Higgins. Carson Hansen added touchdowns runs of 57 and 5 yards, giving him five in the past two games, and finished with 91 yards in nine carries

Becht, a sophomore, moved past Alex Espinoza into sixth place on the school's total offense chart, running his figure to 5,114 yards in just 20 games. His 11 straight games with a TD passes matches Brock Purdy for the second longest streak in school history. Purdy has the longest at 12 straight games.