overwolf.settings.games API
Use this API to view the game-settings features functions.
Please read our best practices for using game settings can be found here.
Special OW URL's
You can also use the following helpful URLs to open the relevant Overwolf game settings in the Appstore:
overwolf://store/game-settings/game-id/[game-id]
A clickable link that opens the Overwolf (game-id) game settings window from your app.overwolf://store/game-settings/appid-id/[extension-id]
A clickable link that opens the Overwolf (targeted by your app) game settings window from your app.
Methods Reference
- overwolf.settings.games.getOverlayEnabled()
- overwolf.settings.games.enableOverlay()
- overwolf.settings.games.getAutoLaunchEnabled()
- overwolf.settings.games.setAutoLaunchEnabled()
Events Reference
- overwolf.settings.games.onOverlayEnablementChanged
- overwolf.settings.games.onAutoLaunchEnablementChanged
Types Reference
- OverlayEnabledResult Object
- AutolaunchEnabledResult Object
- OverlayEnablementChangedEvent Object
- AutoLaunchEnablementChangedEvent Object
getOverlayEnabled(gameClassId, callback)
Version added: 0.112
Provides per-game settings as set by the user via the Overwolf store.
Parameter | Type | Description |
---|---|---|
gameClassId | int | The game ID for which the flag is retrieved for |
callback | (Result: OverlayEnabledResult) => void | A callback function which will be called with the status of the request |
enableOverlay(gameClassId, callback)
Version added: 0.250
Enables game overlay for the specified game
Parameter | Type | Description |
---|---|---|
gameClassId | int | The game ID to enable Overlay for |
callback | (Result) => void | The result of the operation |
Notes
- This method can only be called as a result of a direct user gesture (i.e. mouse click)
- This method can only be called for games this App is targeting in the manifest (or all games if it is targeting
all
)
getAutoLaunchEnabled(gameClassId, callback)
Version added: 0.112
Returns the current Auto-Launch enabled setting for the calling app in a given game (gameClassId).
Parameter | Type | Description |
---|---|---|
gameClassId | int | The game ID for which the flag is retrieved for |
callback | (Result: AutolaunchEnabledResult) => void | A callback function which will be called with the status of the request |
setAutoLaunchEnabled(gameClassId, enabled, callback)
Version added: 0.173
Sets the current Auto-Launch enabled setting for the calling app in a given game (gameClassId).
Parameter | Type | Description |
---|---|---|
gameClassId | int | The game ID for which the flag is set |
enabled | bool | whether auto-launch should be enabled |
callback | (Result: AutolaunchEnabledResult) => void | A callback function which will be called with the status of the request |
onOverlayEnablementChanged
Version added: 0.124
Fired when the overlay is enabled or disabled for a game, with the following structure: OverlayEnablementChangedEvent Object
Event Data Example: Success
{ "gameId": 7764, "enabled": false}
onAutoLaunchEnablementChanged
Version added: 0.124
Fired when auto launch is enabled or disabled for a game, with the following structure: AutoLaunchEnablementChangedEvent Object
OverlayEnabledResult Object
Parameter | Type | Description |
---|---|---|
success | boolean | inherited from the "Result" Object |
error | string | inherited from the "Result" Object |
enabled | boolean |
Example data: Success
{
"enabled": true
}
AutolaunchEnabledResult Object
Parameter | Type | Description |
---|---|---|
success | boolean | inherited from the "Result" Object |
error | string | inherited from the "Result" Object |
autoLaunchEnabled | boolean |
Example data: Success
{
"autoLaunchEnabled": true
}
OverlayEnablementChangedEvent Object
Parameter | Type | Description |
---|---|---|
gameId | number | |
enabled | boolean |
Event data example
{ "gameId": 7764, "enabled": false }
AutoLaunchEnablementChangedEvent Object
Parameter | Type | Description |
---|---|---|
gameId | number | |
appId | string | |
enabled | boolean |
Event data example
{ "gameId": 7764, "appId": "hffhbjnafafjnehejohpkfhjdenpifhihebpkhni", "enabled": false }