We value your input!
Please participate in Archicad 28 Home Screen and Tooltips/Quick Tutorials survey

Libraries & objects
About Archicad and BIMcloud libraries, their management and migration, objects and other library parts, etc.

Light object

Anonymous
Not applicable
I've made a 2D light symbol and saved it has an object.
Changed it's subtype to light.
Works fine except I'd like to get rid of (or bring in closer) the outer
4 bounding points shown in the attachment.
I've searched though the 2D script but don't see any obvious place to
adjust this.
Any hints appreciated.
Thanks
2D script
!
! Name : Light High Eff.gsm
! Date : Saturday, November 24, 2012
! Version : 16.00
! Written by ArchiCAD
!

mul2 A/0.442067, B/0.442067
add2 -73'-1.4267", -31'-0.5917"
pen penAttribute_1
hotspot2 74'-3.3062", 31'-9.2938"
hotspot2 73'-10.1289", 32'-2.4711"
hotspot2 73'-4.9516", 31'-9.2938"
hotspot2 73'-10.1289", 31'-4.1165"
pen penAttribute_2
line_property 0
line2 74'-3.3062", 31'-9.2938", 74'-6.8310", 31'-9.2938"
line2 73'-10.1289", 31'-4.1165", 73'-10.1289", 31'-0.5917"
line2 73'-4.9516", 31'-9.2938", 73'-1.4267", 31'-9.2938"
line2 73'-10.1289", 32'-2.4711", 73'-10.1289", 32'-5.9959"
circle2 73'-10.1289", 31'-9.2938", 0'-5.1773"
pen penAttribute_3
fill fillAttribute_1
poly2_b{5} 5, 2, 0, 3, penAttribute_3, penAttribute_3,
0'-0.0000", 0'-0.0000", 3'-3.3701", 0'-0.0000", 0'-0.0000", 3'-3.3701", 0'-0.0000",
73'-7.2199", 31'-7.5080", 1,
74'-1.6199", 31'-7.5080", 1,
74'-1.6199", 31'-11.1747", 1,
73'-7.2199", 31'-11.1747", 1,
73'-7.2199", 31'-7.5080", 1
define style{2} "AC_STYLE_1" "Arial", 5'-9.4444", 0

paragraph "AC_PRG_2" 4, 0'-0.0000", 0'-0.0000", 0'-0.0000", 2'-3.5591"
pen penAttribute_4
set style "AC_STYLE_1"
"H-EF"
endparagraph
textblock "AC_TEXTBLOCK_2" 0'-0.0000", 9, 0'-0.0000", 1'-11.6220", 3'-3.3701", 3'-3.3701",
"AC_PRG_2"
richtext2 74'-1.6199", 31'-7.5080", "AC_TEXTBLOCK_2"

MyLightObject-16.png
12 REPLIES 12
Anonymous
Not applicable
Hello,

You can erase the 'hotspot2' lines to get
rid of them. The problem is that there needs
to be at least one hotspot or the bounding
hotties are created by default.

You could add desired hotspots in the floor
plan before saving as an object.

I recommend placing the symbol to the origo
(0,0) before saving. That way the code is easier
to read + edit. For example you could just add a
line
hotspot2 0,0
to have one in the
middle.
Anonymous
Not applicable
Hello Juha
Thanks for the reply.
Made hotspot adjustments as you stated (I hope), but maybe I got it wrong as bounding ones are still there.

code:
!
! Name : HighEffLight-3.gsm
! Date : Saturday, November 24, 2012
! Version : 16.00
! Written by ArchiCAD
!

mul2 A/0.294294, B/0.294294
add2 0'-0.0000", 0'-0.0000"
pen penAttribute_1
hotspot2 0,0
pen penAttribute_2
line_property 0
line2 0'-5.7598", 0'-9.9655", 0'-5.7598", 0'-11.5864"
line2 0'-1.6208", 0'-5.7598", 0'-0.0000", 0'-5.7598"
line2 0'-5.8266", 0'-1.6208", 0'-5.8266", 0'-0.0000"
line2 0'-9.9655", 0'-5.8266", 0'-11.5864", 0'-5.8266"
arc2 0'-5.7932", 0'-5.7932", 0'-4.1725", 0, 180
arc2 0'-5.7932", 0'-5.7932", 0'-4.1725", 180, 0
pen penAttribute_3
fill fillAttribute_1
poly2_b{5} 5, 2, 0, 3, penAttribute_3, penAttribute_3,
0'-0.0000", 0'-0.0000", 3'-3.3701", 0'-0.0000", 0'-0.0000", 3'-3.3701", 0'-0.0000",
0'-2.5932", 0'-3.9599", 1,
0'-8.9932", 0'-3.9599", 1,
0'-8.9932", 0'-7.6265", 1,
0'-2.5932", 0'-7.6265", 1,
0'-2.5932", 0'-3.9599", 1
define style{2} "AC_STYLE_1" "Arial", 5'-9.4444", 0

paragraph "AC_PRG_10" 4, 0'-0.0000", 0'-0.0000", 0'-0.0000", 2'-3.5591"
pen penAttribute_4
set style "AC_STYLE_1"
"H-EF"
endparagraph
textblock "AC_TEXTBLOCK_10" 0'-0.0000", 9, 0'-0.0000", 1'-11.6220", 3'-3.3701", 3'-3.3701",
"AC_PRG_10"
richtext2 0'-8.9932", 0'-3.9599", "AC_TEXTBLOCK_10"
hotspot2.png
Anonymous
Not applicable
Hi lec,
to get rid off that hotspots you must select the "Details" button on the Parameters window and uncheck the item "Hotspots on bounding box"; then Save the object.
GDL code - Bounding box.jpg
Anonymous
Not applicable
...and that to happen you must have at
least one hotspot in the 2d code or in the
2d symbol.

HTH
Anonymous
Not applicable
Hi Andro and Juha again
Thanks for the replies.
Got the bounding box turned off per you suggestion, thank you.
(And added extra hotspots near the light as I'm sure you can see.)
But the wires still don't go to the light or my inner hot spots.
They still seem to go to the bounding box corner locations even though they are turned off now.
Maybe I should explain a bit.
I've just purchased Cadimage's Electrical object and it works fine for standard
AC lights (the round ones I'm showing).
However AC doesn't have several of the light symbols I want, so I'm trying to create my own.
Problem is if I can't get my lights to have wires come all the way to the light, (as the others are) it can be a confusing view, ie. (is it to that light or not?)
Don't think this is a Cadimage issue, as it works fine with AC lights but will try Monday if no solution by then.
Current script follows:

!
! Name : DimCanLight 3.gsm
! Date : Saturday, November 24, 2012
! Version : 16.00
! Written by ArchiCAD
!

mul2 A/0.377748, B/0.377748
add2 0'-2.8684", 0'-2.6455"
pen penAttribute_1
line_property 0
line2 0'-0.0000", 0'-9.7559", 0'-9.4771", 0'-9.7559"
line2 0'-9.4771", 0'-9.7559", 0'-9.4771", 0'-0.0000"
line2 0'-9.4771", 0'-0.0000", 0'-0.0000", 0'-0.0000"
line2 0'-0.0000", 0'-0.0000", 0'-0.0000", 0'-9.7559"
circle2 0'-4.5676", 0'-4.7905", 0'-4.2064"
circle2 0'-4.5676", 0'-4.7905", 0'-3.8148"
circle2 0'-4.5676", 0'-4.7905", 0'-3.4401"
line2 1'-0.0036", 0'-4.7905", 0'-8.7740", 0'-4.7905"
line2 0'-4.5676", 1'-0.2265", 0'-4.5676", 0'-8.9970"
line2 -0'-2.8684", 0'-4.7905", 0'-0.3612", 0'-4.7905"
line2 0'-4.5676", -0'-2.6455", 0'-4.5676", 0'-0.5841"
pen penAttribute_2
hotspot2 0'-0.3612", 0'-4.7905"
hotspot2 0'-4.5676", 0'-8.9970"
hotspot2 0'-8.7740", 0'-4.7905"
hotspot2 0'-4.5676", 0'-0.5841"
hotspot2 0'-4.5676", 0'-4.7905"
hotspot2 0'-0.0000", 0'-0.0000"
hotspot2 0'-0.0000", 0'-9.7559"
hotspot2 0'-9.4771", 0'-9.7559"
hotspot2 0'-9.4771", 0'-0.0000"
define style{2} "AC_STYLE_1" "Arial", 9'-0.3368", 0

paragraph "AC_PRG_26" 1, 0'-0.0000", 0'-0.0000", 0'-0.0000", 3'-3.3701"
pen penAttribute_3
set style "AC_STYLE_1"
"D"
endparagraph
textblock "AC_TEXTBLOCK_26" 0'-0.0000", 1, 0'-0.0000", 3'-3.3701", 3'-3.3701", 3'-3.3701",
"AC_PRG_26"
richtext2 0'-2.3864", 0'-8.5857", "AC_TEXTBLOCK_26"
my light object-4.png
Anonymous
Not applicable
Hello,

Did you save the object with the center of
it in the origo, not the lower left corner?
Anonymous
Not applicable
Juha wrote:
Hello,

Did you save the object with the center of
it in the origo, not the lower left corner?
Hi Juha
Not then, but now I have.
Did not seem to change anything.
I noticed that if I shortened the 4 lines leading out from circle then the connection point would follow to the effective intersection.....
So, by having the 4 lines inside the box is better but still elect lines are only going closer to the lower left of box no matter how I place the light, unlike AC's lights which have connection points at the center.
I tried a version where there was only one hotspot at the center of my object and centered on the origin, which did not help.
So somehow there is something different about a factory AC light and my
AC generated "D" light.
Certainly much more usable now, but still curious why not to the center
hotspot when there was only that one.
Thanks for all the help All.
LowrLeftCan.png
Anonymous
Not applicable
Close up view.
CkoseUp.png
David Maudlin
Rockstar
lec:

If the wires are generated by the Cadimage Add-On, then you will need to contact them or look into the scripts of their objects to see how this is handled.

David
David Maudlin / Architect
www.davidmaudlin.com
Digital Architecture
AC27 USA • iMac 27" 4.0GHz Quad-core i7 OSX11 | 24 gb ram • MacBook Pro M3 Pro | 36 gb ram OSX14