- Code: Select all
drawWin(r, g, b, transparency);
NOTE that this has to be in a Canvas Actor. The width and height are dependent on the canvas.
Simply replace r g b with the colors you want, and anywhere between 0 - 1 (EG: 0.50), where transparency is. Here's what this looks like :3
The code: Copy and paste this in the Global Code
- Code: Select all
void drawWin(int R, int G, int B, double TRANS) {
int i;
setpen(R, G, B, TRANS, 1);
moveto(3, 3);
for (i=3;i<height-4;i++) {
moveto(3, i);
lineto(width-4, i);
}
setpen(R*1.2, G*1.2, B*1.2, 0, 3);
moveto(0, 0);
lineto(0, height-1);
lineto(width-1, height-1);
lineto(width-1, 0);
lineto(0, 0);
setpen(R/2, G/2, B/2, 0, 3);
moveto(4, 4);
lineto(4, height-5);
lineto(width-5, height-5);
lineto(width-5, 4);
lineto(4, 4);
}