Petit Computer Wiki
Advertisement

Syntax[]

GSPOIT([page,] x, y)

Purpose[]

GSPOIT is a function that reads the current color of a pixel from the graphics page at the coordinates x,y. This function uses the current draw page of the current screen to determine what page to read from. If the optional page value is provided, that page is used instead, and can be a page that is not currently a draw page for either screen. The returned value is a color index in [0,255].

If the pixel coordinates are out of range of the screen (x<0 or x>255 or y<0 or y>191) the value returned is -1.

Errors[]

Input Error
One or zero arguments provided Missing operand
Four or more arguments provided Syntax error
Any argument is a string Type Mismatch
page<0 or page>3 Out of range
Advertisement