InsertLayer(pos, type, id, x, y[, hidden])
type
and the object id specified by id
into layer position
pos
. All the following layers will be moved downwards and therefore
they will get a new id. The new layer will also be displayed
at the position specified by x
and y
. If you specify 0 as pos
,
the layer will be inserted as the last layer.
The following object types are currently supported:
#BRUSH
id
at x, y
#TEXTOBJECT
id
at x, y
#ANIM
id
at x, y (V2.0)
#VIDEO
id
at x, y (V6.0)
Starting with Hollywood 1.9 you can specify the optional argument
hidden
, which will insert a hidden layer which you can bring to
front using ShowLayer() or ShowLayerFX().
You need to enable layers before you can use this function. See Layers introduction for details.
True
if the layer shall be hidden (defaults
to False
) (V1.9)EnableLayers() SetFillStyle(#FILLCOLOR) Box(0, 0, 100, 100, #RED) Circle(#CENTER, #CENTER, 50, #BLUE) TextOut(#RIGHT, #BOTTOM, "Hello World") InsertLayer(1, #BRUSH, 1, #CENTER, #CENTER)The code above inserts brush 1 as the first layer. This means that all the other layers will be re-positioned. The red rectangle will get layer position 2 now (was layer 1), the blue circle will be layer 3 (was layer 2) and the "Hello World" text will be layer 4 (was layer 3).