Giuseppe,
That LINE2 command that Moonlight has shown you is just an example of a command in GDL scripting.
It will be of no use in your object.
You already have many line commands in your script, which have hard coded X & Y co-ordinates.
The problem with your script is that it has a MUL command that will stretch the lines based on the sizes you use for the length and width (A & B).
Everything after this MUL command will stretch proportionally.
To script this object properly, you would delete the MUL command and all LINE2 commands would refer to the A & B sizes.
For example to make a line that would stretch the length of the 'A' parameter you would use ...
LINE2 0, 0, A, 0
To make it stretch the height of the 'B' parameter ...
LINE2 0, 0, 0, B
To make it stretch both the length (A) and height (B) ....
LINE2 0, 0, A, B
To try and understand this without learning GDL will be rather difficult.
Your best be is to use existing objects that are scripted to be stretchy, or make a new special object for each size variation you need.
Or of course learn GDL, but that is a rather long process.
I've been doing it for 20 years and I am still learning new tricks.
Barry.
One of the forum moderators.
Versions 6.5 to 27
i7-10700 @ 2.9Ghz, 32GB ram, GeForce RTX 2060 (6GB), Windows 10
Lenovo Thinkpad - i7-1270P 2.20 GHz, 32GB RAM, Nvidia T550, Windows 11