;Alan's painting prop edit script. ;This room uses 'mouseover' to select a color from a 'color bar' door picture ON SELECT { ;************************************************************************ ;Define the shape of the door, how many equi-shaped sections there are. 132 xleft = 361 xright = 67 ytop = 99 ybottom = 8 sections = ;************************************************************************ ; [ ;****************************************************** ;Specify colors in color chart in form "R G B" ;List colors in order of left to right, top to bottom of color chart ; "0 0 0" "192 192 192" "255 255 255" "47 0 80" "255 95 160" "0 255 0" "255 255 0" "0 255 255" ;****************************************************** ] colorarray = ; ;****************************************************** ;specify center of paint area 240 xcenter = 212 ycenter = ;****************************************************** ; [ ;****************************************************** ;Specify paint pattern in format [ x-start x-stop ] ;where x is the number of pixels away from the center of the paint area. ;List from top of paint area to bottom of paint area. [ -25 25 ] [ -45 45 ] [ -60 60 ] [ -70 70 ] [ -78 78 ] [ -85 85 ] [ -90 90 ] [ -94 94 ] [ -97 97 ] [ -99 99 ] [ -100 100 ] [ -101 101 ] [ -102 102 ] [ -101 101 ] [ -100 100 ] [ -99 99 ] [ -97 97 ] [ -94 94 ] [ -90 90 ] [ -85 85 ] [ -78 78 ] [ -70 70 ] [ -60 60 ] [ -45 45 ] [ -25 25 ] ;****************************************************** ] paintpattern = ; ;get the paint color MOUSEPOS POP x = xright xleft - sections / width = x xleft - width / mouseover = colorarray mouseover GET "PENCOLOR" & STRTOATOM EXEC ; ;set up paint ; ycenter paintpattern LENGTH 2 / 9 * - 4 + y1 = 0 i = PAINTCLEAR 9 PENSIZE PENBACK { paintpattern i GET temparray = xcenter temparray 0 GET + x1 = xcenter temparray 1 GET + x2 = x1 y1 x2 4 - y1 LINE i ++ 8 y1 += } { i paintpattern LENGTH < } WHILE } ON LEAVE { { PAINTCLEAR } NBRROOMUSERS 2 < IF }