Last Modified: 9/3/2021
Returns the button state of a 3 or 6 button controller.
| Name | Type | Required | Description |
| ControllerPort | Integer | No | ControllerPort 0 is player 1, ControllerPort 1 is player 2. |
| Bit | Hex | Decimal | Button |
| 0 | &h001 | 1 | Up |
| 1 | &h002 | 2 | Down |
| 2 | &h004 | 4 | Left |
| 3 | &h008 | 8 | Right |
| 4 | &h010 | 16 | B |
| 5 | &h020 | 32 | C |
| 6 | &h040 | 64 | A |
| 7 | &h080 | 128 | Start |
| 8 | &h100 | 256 | Z |
| 9 | &h200 | 512 | Y |
| 10 | &h400 | 1024 | X |
| 11 | &h800 | 2048 | Mode |
| Syntax: JoyPad([<ControllerPort>]) |
|
While 1 j = JoyPad() If j.7 Then Print "START" Exit While End If Sleep 1 Wend End |