2022-12-30 06:00 AM
Hi All,
Am trying to get the GDL Debugger to work on a place instance of an object but not having much luck.
I have followed the instructions here: https://gdl.Graphisoft.com/tips-and-tricks/how-to-use-the-gdl-debugger and I think I'm doing everything right but it doesn't seem to be working. The fact that these instructions are slightly out of date probably doesn't help.
This is the steps I am following:
1. I have the GDL editor open on the 2D (or 3D window).
2. I open the GDL Debugger, and click Selection... while I have the placed object selected. The GUID of the placed instanced and the gsm name get filled in.
3. I go back to the main floorplan or 3D model view - not the 2D or 3D views within the GDL editor.
4. GDL Debugger disappears.
5. I force a refresh and rebuild on the floorplan or 3d model.
6. I reopen the GDL editor, GDL debugger reappears, and there a collection of Parameter (OK), 2D (OK) and 3D (OK) in the output window but nothing else appears to happen. The BREAKPOINT play step in etc buttons remain greyed out.
The Execute, Playback and Dump Pars buttons also appear to do nothing.
If I just press 'Run with Default Params' button, then GDL Editor 2D View (or 3D View window) appears, and I can jump to the first breakpoint I have added to my script, and then step line by line and watch the 2D or 3D generation.
Thanks,
Scott
Solved! Go to Solution.
2023-01-02 11:27 AM
Hi,
select one of the listed runs, and then press Execute or Playback.
2022-12-30 10:11 AM
Hello @scottjm
I've used the debugger scarcely and it seemed that it really is two parts : the top one is for the object editor where you can add parameter names and use breakpoints to see their values and the bottom one that checks the object that is instantiated.
That's how I ended up understanding it but maybe I've used it wrong. Myself, I use PRINT statements as a way to dump param values and debug instantiated objects...
2022-12-30 11:23 AM
@scottjm I have tried to get my head round the debugger and failed, but same as @MetalFingerz I can usually build in checks to identify the problem areas, some of which aren't immediately obvious until you isolate bits of code. Using GOSUB in your coding can speed up isolating problems.
2022-12-30 04:38 PM
The linked manual is not only hopelessly out of date, it also lists more limitations than it to be considered useful. 😂
I also have never bothered to try and incorporate it my workflow. PRINT all the way!
But let's hit @Peter Baksa, he should be able to shed some light on it. (:
2022-12-31 06:19 AM - edited 2022-12-31 06:37 AM
In most cases, i use the normal "Text"-command to write down the parameter-values during developing direct in the 2D (or also in 3D with 3D-Texts) - mostly, to get the right numberings or to check calculations like angles or distances, to see them direct in the resulting sketches or objects.
Its not necessary to see every value of every parameter in every step - with the use of text - you can point on the important values directly. So - i never used this debugger.
Just make a (small enough ) style für this Text-commands before using them
Another way for checking right calculations i use - is to make visible circles - radiuses (circle2D) - where i can see calculated distances directly without having got the right angles before.
(where do intersect 2 circles - is it the right calculated point..?? )
In 3D, i also use the Circle - command to 3D-control the right xyz-Place of the exact place after the coordinate-shifting at the time, because circles can be seen very easy in complex situations - also in defining cutplanes.
Visually controlling the right function of my code during developing complex situations is essential for my style of coding.
This is also the purpose, i don't use extern scripting-editors, because i nearly check every single step in this ways and it would be much too slow even with copy-paste between extern editors and the builtin, not to speak of using XML-converters.
In simple objects, its easy and very fast, to use the 2D-3D GDL-builtin window, but, if you begin to use editable hotspots, you will have to strg+s every single step for control the right function of editable hotspots in the real drawingeditors. (That time - to just simply save the object - until it reacts in the editor is still too long and for me "not usable" with external editors)
In some cases, i don't remove the control text, because the User can use it as well: here for example the Z-hights of the points of my streetparts displayd in 2D:
2023-01-02 11:27 AM
Hi,
select one of the listed runs, and then press Execute or Playback.
2023-01-03 04:59 AM
Amazing! Thank you @Peter Baksa! seems so obvious now that you say it.
And thanks for all your feedback everyone else, I’ve always used Print extensively too but it always seemed so primitive, being able to see how the script actually progresses through the code is super helpful.