Game Maker Xin 1.1 extension documentation

I've made this reference sheet cuz I couldn't find any info about this ancient legacy Game Maker extension anywhere on the internet. Tested in Game Maker 8.0 Pro on Steam Deck via Proton Experimental 2024-10-23.

Quick start

Diagram of an Xbox 360 controller with example code snippets for accessing each controller input.

Table of functions

FunctionParametersReturnsexample

xin_update(id = 0)

int id = port number

Port numbers are Zero indexed! i.e. Player 1 is id 0, Player 4 is id 3.

Returns bool (0 = disconnected, 1 = connected)

Returns Boolean connection status of the gamepad connected to the specified port.

switch(xin_update(0)) //player 1's controller
{case 0: plug = "unplugged";break;
case 1: plug = "connected"}
draw_text(x,y,plug)

xin_get_input(id = 0)

int id = port number

Port numbers are Zero indexed! i.e. Player 1 is id 0, Player 4 is id 3.

Returns int value showing button id

Returns int value representing button number

switch(xin_update(0)) //player 1's controller
{case 0: plug = "unplugged";break;
case 1: plug = "connected"}
draw_text(x,y,plug)

xin_get_input button values

idbutton
7A
8B
9X
10Y
11LB
12RB
13Left stick click
14Right stick click
15Dpad up
16Dpad down
17Dpad left
18Dpad right
19Start / Menu
20Back / View

Credits

Xbox 360 controller diagram by Alphathon is licensed under CC-BY-SA 3.0

Modified by blobeee to replace labels with concise Xin 1.1 example code.

Xin 1.1 by JacksonYarr is in the public domain according to the info displayed in the Extension Package Manager

Extension Packages window with Xin v1.1 selected. The author of Xin is JacksonYarr and the license is set to Public Domain.