 |
|
BaselScript |
Beschreibung
Draw rectangle
draw tile=rect .... parameterliste
Parameter:
x1 = x_left
y1 = y_top
x2 = x_right
y2 = y_bottom
w = width (wenn x2 undefiniert ist)
h = height (wenn y2 undefiniert ist)
name = name
filling = 0/1
color = wert
stroke_width = wert
transparent = (0-100)
section=name (Diese Sektion wird durch Klicken auf das Rechteck aufgerufen - Rechteck als Button benutzen)
Beispiel:
scene = 1 name ="draw rect" bgcolor=#bb6699 mode=graphic
section init
clear canvas
#x1 = 400
#y1 = 200
draw tile = rect name=#l1 x1 = #x1 y1 = #y1 w = 300 h = 200 color=#ff0000 filling = 1
#x1 = 10
#y1 = 400
#x2 = 400
#y2 = 900
draw tile = rect name=#l2 x1 = #x1 y1 = #y1 x2 = #x2 y2 = #y2 color=#00ff55 filling = 0 stroke_width= 40 section=button
draw canvas
end section
section button
message "Over rect pressed"
end section
end scene 1