Use the capture method the game supports
For games that prevent the Game Capture hook, use windowed or borderless mode and Window Capture. OBS specifically lists Destiny 2 and Counter-Strike 2 in that case.
If a fullscreen game disappears only when you switch away from it, make a recording while it stays active and inspect the file afterwards. Minimized fullscreen behaviour is not evidence that the recording was black.
To set the source up from the start, see how to capture a game in OBS.
Check permission and competing hooks
Some games are captured only when OBS runs as administrator; OBS names Call of Duty, Genshin Impact, Honkai: Star Rail and Zenless Zone Zero. On Windows, close OBS, right-click it and choose Run as administrator. Close conflicting overlays or frame-rate tools for an isolated trial. On a multi-GPU laptop, set both OBS and the game to the high-performance GPU.
If an HDMI device is black instead of an OBS Game Capture source, use capture-card troubleshooting. Those are different capture paths.
Test with the game active
Record the actual game in the selected display mode with your normal scene. Keep it active during the recording, then inspect the file. Restore unrelated settings before adding overlays back one at a time.