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

No change of values A, B, ZZYZX

zofa groningen
Contributor
I made a parametrical object in which change the size by using hotspots and a custom parameter. When I use the object and change the size by using the hotspots, the values A, B, ZZYZX don't change. They stay at the default value as set in the objects parameter. For the rest the object works ok.

I modelled a shape, saved this as an object and edited the 2D en 3D scripts to make it parametrical.

I think my problem is very basic but I'm rather new in GDL
Hans Overdiep • AC 10 - 27 • MacOS 14.3 • IMac 2020 10 Core i9 • 64 GB • 16 GB Radeon Pro 5700 XT
8 REPLIES 8
Joachim Suehlo
Advisor
Please post your scripts, especially 3D-Script.
And did you use anywhere the command "PARAMETERS"?
Joachim Suehlo . AC12-27 . MAC OSX 13.5 . WIN11
GDL object creation: b-prisma.de
Barry Kelly
Moderator
zofa wrote:
I made a parametrical object in which change the size by using hotspots and a custom parameter.

This is probably your problem.
As your script is not using A, B and ZZYZX to manipulate the size of the object.
You are using custom parameters (length, width & height) so it is these parameters that you hotspots are changing.
As Joachim suggested, it is probably easier if you can attach your object (zip file) or at least show us the script.

Barry.
One of the forum moderators.
Versions 6.5 to 27
Dell XPS- i7-6700 @ 3.4Ghz, 16GB ram, GeForce GTX 960 (2GB), Windows 10
Lenovo Thinkpad - i7-1270P 2.20 GHz, 32GB RAM, Nvidia T550, Windows 11
Lingwisyer
Guru
If glob_modpar_name = x then A = x
If glob_modpar_name = y then B = y
If glob_modpar_name = z then ZZYZX = z

If glob_modpar_name = A then x = A
If glob_modpar_name = B then y = B
If glob_modpar_name = ZZYZX then z = ZZYZX

AC22-23 AUS 7000Help Those Help You - Add a Signature
Self-taught, bend it till it breaksCreating a Thread
Win10 | R5 2600 | 16GB | GTX1660 
Barry Kelly
Moderator
Lingwisyer wrote:
If glob_modpar_name = x then A = x
If glob_modpar_name = y then B = y
If glob_modpar_name = z then ZZYZX = z

If glob_modpar_name = A then x = A
If glob_modpar_name = B then y = B
If glob_modpar_name = ZZYZX then z = ZZYZX
Don't forget if you do this synchronising of variables you also need to change the values displayed.
PARAMETERS A=A, B=B, ZZYZX=ZZYZX, x=x, y=y, z=z
Otherwise you are changing the values of the variable for future calculations, but are not updating what the user sees in the parameter list.

Barry.
One of the forum moderators.
Versions 6.5 to 27
Dell XPS- i7-6700 @ 3.4Ghz, 16GB ram, GeForce GTX 960 (2GB), Windows 10
Lenovo Thinkpad - i7-1270P 2.20 GHz, 32GB RAM, Nvidia T550, Windows 11
zofa groningen
Contributor
Thank you all for replying. I attached the object.

In the meantime I'll try your suggestions.
Hans Overdiep • AC 10 - 27 • MacOS 14.3 • IMac 2020 10 Core i9 • 64 GB • 16 GB Radeon Pro 5700 XT
zofa groningen
Contributor
Just adding "PARAMETERS A=HOR" in the parameter script solved it.
Thank you all voor replying.

Hans
Hans Overdiep • AC 10 - 27 • MacOS 14.3 • IMac 2020 10 Core i9 • 64 GB • 16 GB Radeon Pro 5700 XT
Lingwisyer
Guru
The issue with only doing that is if someone decides to modify A. Nothing will happen, and it will no longer show the correct value until you modify HOR again. This can be resolved by using the GLOB_MODPAR_NAME command to identify the last parameter modified then follow through from that.



Ling.

AC22-23 AUS 7000Help Those Help You - Add a Signature
Self-taught, bend it till it breaksCreating a Thread
Win10 | R5 2600 | 16GB | GTX1660 
Barry Kelly
Moderator
zofa wrote:
Just adding "PARAMETERS A=HOR" in the parameter script solved it.
Thank you all voor replying.

Hans
This will work but as Ling mentioned, does not help if someone adjusts A.

You will need
if GLOB_MODPAR_NAME = "A" then
HOR = A
PARAMETERS HOR = HOR
endif

Or just change your script so you don't use the 'HOR' variable at all.
Just use 'A' in its place (don't forget to change 'A' value to 100 or it will be really wide).
Everywhere in your scripts that you use 'HOR', just change it to 'A'.

That also allows you object to be adjusted in the info box without having to open the parameters (not so important if you have the editing hotspots though).

Barry.
One of the forum moderators.
Versions 6.5 to 27
Dell XPS- i7-6700 @ 3.4Ghz, 16GB ram, GeForce GTX 960 (2GB), Windows 10
Lenovo Thinkpad - i7-1270P 2.20 GHz, 32GB RAM, Nvidia T550, Windows 11