How to disable sprinting in a particular level

Hi, does anyone know how to disable sprinting in a particular level as I want the first level to be in a forest and then the next level in a house. I don’t want to the player to be able to sprint in the house just walk. And then the player can sprint in the forest.
Much help would be appreciated…