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

retrieve the ID of a Hotspot2

Anonymous
Not applicable
Hello,

I would like to know if it is possible to know the ID of a hotspot2 moved in 2D. Here, the point 3 in the drawing.


I can do it with :
parameter P [3] [x,y]
parameter P2 [3] [x,y] = P [3] [x,y]

script 2D : HOTSPOT2 P [3] , P[3] ,...
If I move some points, I can compare P to P2 to know if P was moved.
And after, PARAMETERS P2 [3] [x,y] = P [3] [x,y]

But it is not practical, if there are lot of points.
Thanks
Do you have any other solution?
7 REPLIES 7
Anonymous
Not applicable
up...

I don't know if it is understandable. If not, please tell me.

I want to retrieve the ID of the hotspot2 moved, or the number of the point moved in a parameter matrix (with many points).

Thanks
What is the purpose of this?
If editable poly - it is easier to manage with matrix parameters...

Best Regards,
Piotr
Anonymous
Not applicable
Piotr wrote:
What is the purpose of this?
If editable poly - it is easier to manage with matrix parameters...

Best Regards,
Piotr
Not that.
If I move the point 3 (in the drawing), can I know in the scripts, which point has been moved ?

I write again my solution from start :

------
An editable poly, use parameter P [4][x,y]
at first parameter P2 [4][x,y] = parameter P [4][x,y]

after hotspot2 moved, comparison P and P2 :
FOR point = 1 TO 4
IF P [point] ≠ P2 [point] OR P [point] ≠ P2 [point] THEN the point has been moved
NEXT point

and after P2 = P again :
PARAMETERS P2 [pointMoved] = P [pointMoved] , ditto y
------

it works, but it is long. Is there another way?

Thanks
Why not put the original coords to temporary matrix, than compare the temporary with the coords - the result can be the number of point moved by last move?
A lot of compares (assuming that poly is long) but can be automated

Remember the all coords in one matrix parameter (coords - eg. n-point no, m with 2 positions for x and y and maybe z),
You can get the matrix size so You can define the loop

if the MODPAR of your coords parameter occure - You can start compare...
Hotspot mooving would triger so.

Again - what You are trying to achieve with the point no?

Best Regards,
Piotr
Anonymous
Not applicable
Piotr wrote:

Again - what You are trying to achieve with the point no?

Best Regards,
Piotr
I make a wall object for landscape, garden with slope… with z point (hotspot 3D) for each corner, with straight and curves… (I don't understand why Graphisoft did not invent a wall tool to which one can define different heights).
In 2D, I can add points and move them.

I want to know the number of point moved, for example when I move a hotspot2 to curve the path between two points…
If there is no other solution, i'll use this solution with temporary matrix.
Thanks
To make the curve of a poly segment: add another matrix parameter: "bulge" - for all segments. Than if "bulge" changes from 0 than the poly segment will change from straight to curve, You have to calculate the arc from start and end of the segment and bulge to the circle arc in position.

Best Regards,
Piotr
Anonymous
Not applicable
Piotr wrote:
To make the curve of a poly segment: add another matrix parameter: "bulge" - for all segments. Than if "bulge" changes from 0 than the poly segment will change from straight to curve, You have to calculate the arc from start and end of the segment and bulge to the circle arc in position.

Best Regards,
Piotr
Yes, I do like that, thanks again.