-- Runs to modify the player after they've gotten an upgrade

function UpgradeManager:SetWalkspeedToCurrentUpgrade(player)
	local stats = player:WaitForChild("stats")
	local playerUpgrades = stats:WaitForChild(GameSettings.upgradeName)
	local points = stats:WaitForChild(GameSettings.pointsName)

	--Change the players movement speed 
	local character = player.Character or player.CharacterAdded:wait()
	local humanoid = character:WaitForChild("Humanoid")
	humanoid.WalkSpeed = GameSettings.movementSpeed(playerUpgrades.Value)
end

