window_get_width();
Returns: Real
With this function you can get the current width (in pixels) of the game window.
ww = window_get_width();
The above code will store the current window width in the variable "ww".