Draw on the stage with a virtual pen: colour, size, and stamping.
// Create a color from a hex value
Color.fromHex("#ff0000");
// Create a color from red, green and blue components
Color.fromRGB(255, 255, 255);
// Erase everything the pen has drawn on the stage
self.penClear();
// Put the pen down so the sprite draws as it moves
self.penDown();
// Lift the pen up so the sprite stops drawing
self.penUp();
// Stamp the sprite's image onto the stage
self.stamp();
// Set the pen's thickness
self.penSize = 100;
// Change the pen's thickness by a given amount
self.penSize += 1;
// Set the pen color
self.penColor = Color.fromHex("#ff0000");
// Get the current pen thickness
self.penSize;
// Get the current pen color
self.penColor;
// Check whether the pen is currently down
self.isPenDown;