Added an enum class to define the direction of the snake