<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Rotating Dynamic Hotspot Help? in Libraries &amp; objects</title>
    <link>https://community.graphisoft.com/t5/Libraries-objects/Rotating-Dynamic-Hotspot-Help/m-p/226469#M5443</link>
    <description>If I look at page 197 of the GDL Reference Guide in ArchiCAD 20, the diagram is quite clearly going counter clockwise, perhaps this is intended?&lt;BR /&gt;
&lt;BR /&gt;
Edit: this is also how the angles work in ArchiCAD when drafting.</description>
    <pubDate>Mon, 04 Sep 2017 11:01:34 GMT</pubDate>
    <dc:creator>Erwin Edel</dc:creator>
    <dc:date>2017-09-04T11:01:34Z</dc:date>
    <item>
      <title>Rotating Dynamic Hotspot Help?</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/Rotating-Dynamic-Hotspot-Help/m-p/226468#M5442</link>
      <description>&lt;DIV class="actalk-migrated-content"&gt;&lt;R&gt;Hi, &lt;BR /&gt;
I have tried using the script given in the gdl guide but I can't seem to get it to work. Does anyone know how to make it work correctly?&lt;BR /&gt;

&lt;PRE&gt;! --------------------------------------------------------------------------------
! Center
! --------------------------------------------------------------------------------
hotspot2 0, 0, unID, ang, 6     : unID = unID + 1

! --------------------------------------------------------------------------------
! Base
! --------------------------------------------------------------------------------
hotspot2 r, 0, unID, ang, 4     : unID = unID + 1

! --------------------------------------------------------------------------------
! Moving
! --------------------------------------------------------------------------------
hotspot2 r * COS(ang), r * SIN(ang), unID, ang, 5     : unID = unID + 1&lt;/PRE&gt; I have created parameters for ang and R.&lt;BR /&gt;
&lt;BR /&gt;
I really just need some explanation of the code. For some reason the angle increases when going anti-clockwise instead of clockwise. In 2D. The base does isn't position above at what should be 0 degrees.&lt;/R&gt;&lt;/DIV&gt;</description>
      <pubDate>Mon, 04 Sep 2017 09:10:58 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/Rotating-Dynamic-Hotspot-Help/m-p/226468#M5442</guid>
      <dc:creator>JGoode</dc:creator>
      <dc:date>2017-09-04T09:10:58Z</dc:date>
    </item>
    <item>
      <title>Re: Rotating Dynamic Hotspot Help?</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/Rotating-Dynamic-Hotspot-Help/m-p/226469#M5443</link>
      <description>If I look at page 197 of the GDL Reference Guide in ArchiCAD 20, the diagram is quite clearly going counter clockwise, perhaps this is intended?&lt;BR /&gt;
&lt;BR /&gt;
Edit: this is also how the angles work in ArchiCAD when drafting.</description>
      <pubDate>Mon, 04 Sep 2017 11:01:34 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/Rotating-Dynamic-Hotspot-Help/m-p/226469#M5443</guid>
      <dc:creator>Erwin Edel</dc:creator>
      <dc:date>2017-09-04T11:01:34Z</dc:date>
    </item>
    <item>
      <title>Re: Rotating Dynamic Hotspot Help?</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/Rotating-Dynamic-Hotspot-Help/m-p/226470#M5444</link>
      <description>&lt;BLOCKQUOTE&gt;Erwin wrote:&lt;BR /&gt;If I look at page 197 of the GDL Reference Guide in ArchiCAD 20, the diagram is quite clearly going counter clockwise, perhaps this is intended?&lt;BR /&gt;
&lt;BR /&gt;
Edit: this is also how the angles work in ArchiCAD when drafting.&lt;/BLOCKQUOTE&gt; Seems very strange. I was having some other issues when changing the centre point of the rotation so I have had to keep it at 0, 0 which is inconvenient. Thanks for the help.</description>
      <pubDate>Mon, 04 Sep 2017 11:28:14 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/Rotating-Dynamic-Hotspot-Help/m-p/226470#M5444</guid>
      <dc:creator>JGoode</dc:creator>
      <dc:date>2017-09-04T11:28:14Z</dc:date>
    </item>
    <item>
      <title>Re: Rotating Dynamic Hotspot Help?</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/Rotating-Dynamic-Hotspot-Help/m-p/226471#M5445</link>
      <description>&lt;BLOCKQUOTE&gt;JGoode wrote:&lt;BR /&gt;Seems very strange. I was having some other issues when changing the centre point of the rotation so I have had to keep it at 0, 0 which is inconvenient. Thanks for the help.&lt;/BLOCKQUOTE&gt;

All of the hotspots need to have the same base co-ordinates.&lt;BR /&gt;
An easy way to do this is leave the base at 0,0 but put an ADD before the hotspots&lt;BR /&gt;
i.e.&lt;BR /&gt;

&lt;PRE&gt;ADD x, y
! Center 
! -------------------------------------------------------------------------------- 
hotspot2 0, 0, unID, ang, 6     : unID = unID + 1 

! -------------------------------------------------------------------------------- 
! Base 
! -------------------------------------------------------------------------------- 
hotspot2 r, 0, unID, ang, 4     : unID = unID + 1 

! -------------------------------------------------------------------------------- 
! Moving 
! -------------------------------------------------------------------------------- 
hotspot2 r * COS(ang), r * SIN(ang), unID, ang, 5     : unID = unID + 1

DEL 1
&lt;/PRE&gt;

or
&lt;PRE&gt; ! Center 
! -------------------------------------------------------------------------------- 
hotspot2 x+0, y+0, unID, ang, 6     : unID = unID + 1 

! -------------------------------------------------------------------------------- 
! Base 
! -------------------------------------------------------------------------------- 
hotspot2 x+r, y+0, unID, ang, 4     : unID = unID + 1 

! -------------------------------------------------------------------------------- 
! Moving 
! -------------------------------------------------------------------------------- 
hotspot2 x+r * COS(ang), y+r * SIN(ang), unID, ang, 5     : unID = unID + 1
&lt;/PRE&gt;

Adding a flag value of 512 to the centre hotspot (type 6) will make it rotate in the opposite direction.&lt;BR /&gt;
&lt;BR /&gt;
Barry.</description>
      <pubDate>Tue, 05 Sep 2017 00:44:58 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/Rotating-Dynamic-Hotspot-Help/m-p/226471#M5445</guid>
      <dc:creator>Barry Kelly</dc:creator>
      <dc:date>2017-09-05T00:44:58Z</dc:date>
    </item>
    <item>
      <title>Re: Rotating Dynamic Hotspot Help?</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/Rotating-Dynamic-Hotspot-Help/m-p/226472#M5446</link>
      <description>&lt;BLOCKQUOTE&gt;Barry wrote:&lt;BR /&gt;&lt;BLOCKQUOTE&gt;JGoode wrote:&lt;BR /&gt; Seems very strange. I was having some other issues when changing the centre point of the rotation so I have had to keep it at 0, 0 which is inconvenient. Thanks for the help.&lt;/BLOCKQUOTE&gt;

All of the hotspots need to have the same base co-ordinates.&lt;BR /&gt;
An easy way to do this is leave the base at 0,0 but put an ADD before the hotspots&lt;BR /&gt;
i.e.&lt;BR /&gt;

&lt;PRE&gt;ADD x, y
! Center 
! -------------------------------------------------------------------------------- 
hotspot2 0, 0, unID, ang, 6     : unID = unID + 1 

! -------------------------------------------------------------------------------- 
! Base 
! -------------------------------------------------------------------------------- 
hotspot2 r, 0, unID, ang, 4     : unID = unID + 1 

! -------------------------------------------------------------------------------- 
! Moving 
! -------------------------------------------------------------------------------- 
hotspot2 r * COS(ang), r * SIN(ang), unID, ang, 5     : unID = unID + 1

DEL 1
&lt;/PRE&gt;

or
&lt;PRE&gt; ! Center 
! -------------------------------------------------------------------------------- 
hotspot2 x+0, y+0, unID, ang, 6     : unID = unID + 1 

! -------------------------------------------------------------------------------- 
! Base 
! -------------------------------------------------------------------------------- 
hotspot2 x+r, y+0, unID, ang, 4     : unID = unID + 1 

! -------------------------------------------------------------------------------- 
! Moving 
! -------------------------------------------------------------------------------- 
hotspot2 x+r * COS(ang), y+r * SIN(ang), unID, ang, 5     : unID = unID + 1
&lt;/PRE&gt;

Adding a flag value of 512 to the centre hotspot (type 6) will make it rotate in the opposite direction.&lt;BR /&gt;
&lt;BR /&gt;
Barry.&lt;/BLOCKQUOTE&gt; Thanks very much. This is very useful.</description>
      <pubDate>Tue, 05 Sep 2017 08:07:28 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/Rotating-Dynamic-Hotspot-Help/m-p/226472#M5446</guid>
      <dc:creator>JGoode</dc:creator>
      <dc:date>2017-09-05T08:07:28Z</dc:date>
    </item>
  </channel>
</rss>

