GetPointerX

Description

This is an emulated input method that uses whatever device inputs are available to produce a screen pointer. If the device has a mouse then this returns the current X position of the mouse. Otherwise the AGK will check for a touch screen and, if found, will return the X position of the most recent touch event. If no events are taking place it is the last X position recorded by a touch event. On devices that have neither mice nor touch screens the AGK will attempt to create some form of screen pointer controlled by analog sticks or similar.

This coordinate will be in view coordinates, if you are offsetting the view port you may want to convert it to world coordinates using ScreenToWorldX.

Definition

float GetPointerX()