How to detect if a gamepad is or is not connected

I’m making menus for my game and was wondering if there is a way to tell if a gamepad is connected?

Hi @WilliamBoersma31,

Check the following browser API:


Hey @Leonidas I Know It’s Been A While Since I Last Responded To This Thread But When I Put In gamepad It’s Undefined And The Code Editor Asks Me If I Meant gamepad Which Is A Variable That Is Equal To I tried that but it made connected null what should I do from here

Update: There was a typo on the site the gamepad was supposed to have a uppercae G so I fixed that but gp.connected is still null

Here is a screen shot of the code

Hi @WilliamBoersma31,

Can you share a sample project to take a look?

Here Is My Code I Want this.Pad To Be True When There Is A Pad And False When There Is Not,62890522

right now it’s in slashes because I’m testing other things