Skip to main content

Game Launch

Runs right when the game’s process is created. To listen for a game launch event, you must do one of the following:

Usage

overlay.on("gameLaunch", ({ game, reject }) => {
	// ...
});

Rejecting a Game Launch

You can reject the game launch from being handled by the overlay by calling reject():
overlay.on("gameLaunch", ({ game, reject }) => {
	if (game === "valorant") {
		reject();
		return;
	}

	// ...
});
This is useful if you have a setting that disables your overlay for a given game.
Calling reject() will do the following for the particular game:
  • Prevent the overlay from rendering in the game
  • Block game events from being emitted
  • Prevent gameReady from being emitted

Game Ready

Runs once the overlay is ready to render in game and start listening for game events.
overlay.on("gameReady", ({ game, inGameRenderingSupported } : { game: string, inGameRenderingSupported: boolean }) => {
	if (game === "siege") {
		// ...
	}
});

Game Closed

overlay.on("gameClose", ({ game }) => {
	if (game === "siege") {
		// ...
	}
});