Video playing help

Using this code, when watching a video, it occasionally buffers so that it can get more packets to keep playing. Is there a way I can make it run smoothly without buffering.

Use the link to the video you want to play directly. Example: "www.go.com/}vedio.mp4"

Thank you

Does this work for everything like YouTube, TikTok, etc

You need to get the video link itself in MP4 format, for example. The link should end with a dot followed by the video format.
On YouTube, it's difficult to get the exact video link. You need a file extension to play YouTube videos. As for TikTok, I don't know the nature of the videos there. Is it possible to extract the exact video link or not? I don't know.