Exclusive mode overlay
Overlay is ability to show a window on top of the current game window. There are 2 kinds of overlay modes, standard and exclusive.
In games which have a state with a mouse cursor (usually MOBA), users can interact with Overwolf app without pulling focus out of the game.
In games which have a state without a mouse cursor (usually FPS), users need a way to control and interact with the app’s window.
Standard mode
Standard mode is available in games where the mouse is enabled when playing the game. For example, in MOBA games such as League of Legends, Dota 2, and others, the mouse cursor is available, and therefore you are able to interact with the app windows without the need to pull keyboard and mouse focus input from the game.
Exclusive mode
Exclusive mode is available in games where the mouse is disabled when playing the game. For example, in FPS games such as CS2, Fortnite and others, there’s no mouse cursor so the only way to interact with the Overwolf app window is by activating exclusive mode. This will show a semi-transparent window overlayed on the game window which doesn't allow keyboard or mouse input to pass into the game.
How to enter exclusive mode
There are two options to enable the exclusive mode while you are in a game:
Ctrl + Tab
Pressing Ctrl + tab
while you are in a game set OW in exclusive mode will cause the game window get semi-transparent background, the OW dock is shown, and you can interact with your OW app's windows (if any windows are open).
Pressing Ctrl + tab
again, or clicking outside of the OW app's window, will "release" the exclusive mode.
Using a hotkey
In your app, if you have a window that is bundled to a hotkey, and you want to enter exclusive mode when the hotkey is pressed, you should:
- Set the flag focus_game_takeover to
ReleaseOnHidden
. - Set the focus_game_takeover_release_hotkey to the hotkey name.
This way when the hotkey is pressed, the window will show up and enter exclusive mode (enabling user interaction and accepting input from the user). When the hotkey is pressed again, the window will hide and exit exclusive mode.
In the above screenshot, you can see that the background is semi-transparent, and at the top of the screen a notification tells the user which hotkey releases exclusive mode (Ctrl + F
to hide this app and return to the game). The key combination will change based on the hotkey you choose for your apps.
Automatically on window launch
If you have a window that displays automatically (e.g. a startup window) and you want to enter exclusive mode automatically when the window is shown, you should:
- Set the flag focus_game_takeover to
ReleaseOnLostFocus
.
This way when the window is launched, it automatically enters exclusive mode (and enables user interaction and accepts input from the user). Once the user clicks outside the window, the window will exit the exclusive mode.
In the above screenshot, you can see at the top of the screen a notification that guides the user (hide all apps to return to the game).
Special Overlays
Several specific games: CSGO, Warzone, and Destiny 2, have some additional limitations in addition to the exclusive that is required to interact with the OW windows:
-
When one of these games is running in non-borderless fullscreen mode (other modes are fullscreen borderless and windowed mode), the exclusive mode is completely disabled, and there's no option to interact with your app's window at all. The only thing that you can do is to notify the user and ask them to change game mode to fullscreen borderless or windowed mode.
To detect if the game is running in non-borderless fullscreen, read the overwolf.games.OverlayInfo.exclusiveModeDisabled property. If it'strue
, it means that the exclusive mode is disabled, and you should display the user notification about it. (suggest him to change the mode to fullscreen borderless or windowed mode. Otherwise he will not be able to interact with your app's windows ) -
Overwolf allowed capturing these games only when it's in fullscreen-borderless mode. If the game is in fullscreen non-borderless or windowed mode (we'll support it also very soon), the capture will not work correctly.