Texturing lagre terrain

Hi, I’ve created a large terrain 500x500m with a lot of hills and now I’m trying to texture it. I’m following this tutorial https://www.youtube.com/watch?v=LlqtFW8AWjE and everything works fine until I’m trying to do texture paint on hills (4:50 minute). In my case painting works only on flat surface and I don’t know how to solve this problem.