I wouldn’t say that AMD is “doing better” than Nvidia in the gaming market but as another commenter said, their success is probably mostly due to an excellent price/performance ratio compared to NVidia.
Intel is also somewhat making ground with their Arc GPUs.
The key to doing well in the gaming market are good prices, and good gaming performance with DirectX and Vulkan.