Task

Create a window and draw a pixel in it, subject to the following:

  the window is 320 x 240
  the color of the pixel must be red (255,0,0)
  the position of the pixel is x = 100, y = 100
 
. "Set the sprite's reference character located at the"
. "upper-left corner of the board (char 0)"
set "SPR0_REFX" to 0
set "SPR0_REFY" to 0
 
. "Offset that reference by 256, leading to the first character"
. "in the extended character set"
set "SPR0_OFFSET" to 256
 
. "Set the width and height of the sprite"
set "SPR0_WIDTH" to 1
set "SPR0_HEIGHT" to 1
 
. "Unbound the sprite, removing the grid restriction"
set "SPR0_UNBOUND" to 1
 
. "Mark the sprite for display on the overlay (this may not be necessary)"
set "SPR0_OVERLAY" to 1
 
set "xPos" to 100
set "yPos" to 100
 
. "Display the sprite at the given location"
put c0c Sprite p00 at "('xPos')" "('yPos')"
 