That sound like screensaver or suspend mode is turning on.
You can install the gnome extension "caffeine" or "espresso" to avoid goingyour system to sleep during watching videos or playing games.
Install gnome extension manager
sudo apt install gnome-shell-extension-manager
then open it and search for the extension and install it.
By default caffeine and espresso are enabled when apps are in fullscreen mode. You can turn caffeine on in the quick settings of the taskbar (click on the battery/WLAN/speakers icon) and espresso with the cup icon in the taskbar.
At tab "installed" in extension manager you can make the settings for the extension when you click on the cog wheal.
These Gnome extensions have the advantage that you don't have to change the suspend and screensaver settings just to watch movies, listen to music or play games without interruption.