This shape script is supposed to replace the standard stick-figure Actor with a simple box. (I can't see how to post an image so I have to describe it)
Problem: the shape is wide and shallow, and the actor image is narrow and tall. The shape appears but the clickable area to select and resulting selection markers are those of the actor image not that of the defined shape.
I had to create sub shapes because the Print("#name#") string was wrapping inside the actor shape, which is obviously related to the same underlying problem of not having overridden (even though it is checked - the shape does appear as specified) the standard Actor shape.
Clearly this is wrong - but what is the right way to do this?
shape main
{
setfillcolor(255, 255, 255); // (R,G,B)
rectangle(0, 0, 360, 40); // (x1,y1,x2,y2)
addsubshape("topspace", 360, 6);
shape topspace
{
Print("");
}
addsubshape("namecompartment", 360, 34);
shape namecompartment
{
h_align = "center";
Print("#name#");
}
}
Many thanks
Julian