0

I want to write small multiplatform game. I created Contruct2 plugin for my game and i have any specific methods for different operation system.

How can i detect device type in plugins runtime.js?

TyM6JIep
  • 406
  • 8
  • 23

1 Answers1

0

I found solution:

if (this.runtime.isAndroid) {
    // ...
} else if (this.runtime.isiOS) {
    // ...
} else if (this.runtime.isWindowsPhone8 || this.runtime.isWindowsPhone81) {
    // ...
}
TyM6JIep
  • 406
  • 8
  • 23