
Why the game ends immediately
The visiting team bats first in each inning and the home team bats second. Once the home team takes the lead in the bottom of the final inning, the visitors will not receive another turn at bat, so the result is decided at that moment.

Ways a walk-off can happen
A walk-off can come from a single, double, triple, home run, walk, hit batter, error, wild pitch, passed ball, sacrifice fly, balk, or another legal event that allows the winning run to score. It does not have to be a home run.
How many runs count
On most walk-off plays, the game ends once the winning run scores, and later runners do not add unnecessary runs. A walk-off home run is different: the batter and all runners are entitled to score as long as they complete the bases legally.
Example
The score is tied 3-3 in the bottom of the ninth with a runner on third. The batter hits a sacrifice fly, the runner tags and scores, and the home team wins 4-3. That is a walk-off sacrifice fly.
Bottom line
Walk-off describes the timing and effect of the play, not the type of hit. It is any valid bottom-of-the-final-inning play that produces the winning run and ends the game.
