GDL
About building parametric objects with GDL.
SOLVED!

Cant changer surface

Anonymous
Not applicable
Hi

I have som objects that have been made of morphs, and some has been importer as RFA objects, and converted to morph. When im saving them after morph, im saving them as MEP PARTS.
The problem is, i cant change the surface where i want it to.

If you look on the attached image, i want to change the surafe there, at number 1, but when i do, nothing is happening. But at number 2, i can change it, but i dont want to change it there. Where can this be fixed?
1 ACCEPTED SOLUTION

Accepted Solutions
Solution
Barry Kelly
Moderator
You will need to open the object and edit the 3D script.

Search for all of the lines that say .... material "Plastic - White"
There are more than I show in the image.

This is hard coding the material to Plastic - White.

Replace the line with ... material MainBoxMaterial

This will now use the material parameter that you want - make sure you don't use quotes.

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

View solution in original post

16 REPLIES 16
Peter Baksa
Graphisoft
Graphisoft
Did you also turn off the override at 2 by clicking the paintbrush icon?
Péter Baksa
Software Engineer, Library as a Platform
Graphisoft SE, Budapest
Anonymous
Not applicable
Hi.

Yes, when its off its the same, cant change it where i want to.
Peter Baksa
Graphisoft
Graphisoft
It looks like the created object uses hard-coded attributes. The parameters you see on the UI are parameters of the selected subtype, but they aren't connected to anything in the script. I will report it as a bug.
Péter Baksa
Software Engineer, Library as a Platform
Graphisoft SE, Budapest
Anonymous
Not applicable
Alright.

So what can i do with it now? Can it be fixed somehow? Do I just need to wait?
Peter Baksa
Graphisoft
Graphisoft
SandraGS wrote:
Alright.

So what can i do with it now? Can it be fixed somehow? Do I just need to wait?
You have to edit the generated 3D script to use parameters instead of hard-coded string attributes. You might have to add more parameters if the morph has many surfaces.
Péter Baksa
Software Engineer, Library as a Platform
Graphisoft SE, Budapest
Anonymous
Not applicable
This is very new to me, so can you maybe show me an example? Of where i need to change it?

Its a lot in the script, and i dont know where to start or what to remove or anything.
Lingwisyer
Guru
Is the whole object a single material? If so...

Open the Parameters Script of the object and find the parameter that matches what you have highlighted in your image. Take note of that variable (A).
In the 3D Script add a line at the start that is "Material [variable A]"
Search through the rest of the script and remove any other "Material" commands. Just putting an exclamation mark infront of the command will ignore it.



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 
Peter Baksa
Graphisoft
Graphisoft
SandraGS wrote:
This is very new to me, so can you maybe show me an example? Of where i need to change it?

Its a lot in the script, and i dont know where to start or what to remove or anything.
The 3D script contains statements like

r = REQUEST{2} ("Building_Material_info", "Water", "gs_bmat_surface", bms_47)
set building_material "Water", 104, -1
material "Wood - Pine Grained Horizontal"
In this situation building_material only defines the cut surface and fill of the object. The materials are the outer surfaces. Count the number of different strings for each type.

In the parameter list search for "surface". There is the generated parameter MainBoxMaterial. Add new surface or building material parameters in the quantity you need. You can use MainBoxMaterial for the main surface. Give them a nice name and replace the strings in the script with the names, without quotation marks. eg
material MainBoxMaterial
Péter Baksa
Software Engineer, Library as a Platform
Graphisoft SE, Budapest
Anonymous
Not applicable
Hi.

So, both your suggestions didnt work for me.

I couldnt find any paramters that matches what im looking for in the parameter script..

And when im trying to change the surface, nothing happens.

But i had support case with a client earlier, and found out that some objects in the archicad library, has the same problem, just there you actully can change it where you want to.

Maybe this says you guys something more then me? Why can i change it there?

Didn't find the answer?

Check other topics in this Forum

Back to Forum

Read the latest accepted solutions!

Accepted Solutions

Start a new conversation!