Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Functions

  • hasTouchScreen(): boolean
  • isMobile(): boolean
  • Check if the game runs on a mobile device (iPhone, iPad, Android). Note that the distinction between what is a mobile device and what is not is becoming blurry. If you use this for mobile controls, prefer to check if the device has touchscreen support.

    Returns boolean

  • isNativeMobileApp(): boolean
  • Check if the game is running as a native mobile app - which in the case of an exported GDevelop game means: running packaged inside Cordova/Capacitor.js.

    Note: this could be improved to also detect running inside an embedded webview.

    Returns boolean

    true if running inside Cordova (or Capacitor.js).

Generated using TypeDoc