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

ParkingLot ER - FREE GDL parametric object

sinceV6
Advocate
Hello.

This is a way of saying thanks to everyone in the forum that actively share information, knowledge and advice. I hope you find this contribution useful. My only request is that if you like it after testing, you can pm me for a symbolic donation if you wish, buy me a beer, send me a post card or at least come back and leave a comment here. Also don't be afraid to show some work if you use it.

It was done in the very scarce spare time I have to fulfill the need for a single ParkingLot object with features I constantly use. This was built on top of the "Dynamic Polyline ER" object, just an example of what can be done with it. It might not be the most efficient script -I'm no GDL expert-, but hey... it works for me.

"ParkingLot ER"

FREE GDL parametric object

FEATURES:
-Create and manage vast parking lot layouts with ease.
-No limit on segment numbers: careful though... it is quite complex and has a lot of features and parameters, and just like every complex GDL object, the more segments, the longer it will take to edit and regenerate. I have tested it with 1000 parking spots and it still manages (1000 cars in a single story is a lot of cars. Only in rare cases I go above 100 or 150 per story). Use the special option "Editing large layout" for faster editing, as it disables display of some elements while editing.
-Graphical editing of parking space groups, size, depth, etc.
-Global width and depth, or set it per segment
-Each segment (group of parking spaces) can:
--Have a different parking space size
--Have a different depth
--Turn ON/OFF each side stripe
--Have (or not) car tire bumper & offset
-Symbolic 2D representation options
-Random 2D cars with different seed and density settings
-Number each parking space and show subtotals per segment and grand total, this allows you to have only one object per story to manage all the parking layout.
-3D elevation and inclination per segment (length and depth): it can easily do parking spaces in ramps and platforms in different levels; work first in plan, then elevate in 3D.

-Over 100 parameters allow you to tweak the representation.


LIMITATIONS:
-No user interface script.
-No angled or radial parking. Sorry. I don't use these that much. If your angled layout doesn't have that many spaces, you can build it usign "ParkingLot ER" in a zig-zag manner, alternating ON/OFF segments.
-Not really a limitation, but doesn't have sub-groups (as in "a blank space every 3 cars"); but since it is very flexible, you can just create a segment for each group, and another one for each space (with segment set to OFF)
-Intersection of stripes of consecutive "ON" segments are not cleaned (when side stripes position is set to "Center"). Small quirk. Maybe I'll fix it someday. It doesn't bother me that much.
-Numbering is left->right per segment. You need to keep this in mind when placing/adding segments. TIP: if you need flexibility here, you can place two objects: one for the parking spaces, no numbers; and the other one hiding everything but the numbers and use this one for that purpose.
-Random cars only in 2D.
-Because of the way the script works, when adding a segment that lands in the very beginning (0,0) of the object, it might refuse to build that segment. Just create the last point elsewhere and then drag it to the desired position.

In the Depository->Sitework->Vehicles
http://archicad-talk.graphisoft.com/object_depository.php?

I've kind of tested it, and is working OK for me. If you find any bugs, let me know; I'll fix them if/when I have time.
Enjoy. (for AC15+)

PLER01.png
14 REPLIES 14
Gops
Participant
sinceV6 wrote:
Hi!

For 2D representation, you can create the fill of your pattern and use that in the object's options (parking space background fill).

Best regards.
As you advice I finally manage to do it this way.
sinceV6 wrote:
Hi!

For 3D, it would be better to use a texture. If you are asking because you need it for rendering, a texture (with displacement) should work

Best regards.
This also was very helpful.

Thanks a lot and sorry that I did not figure out the parking background fill at first and thought that it should be added to your smart object.
AC 16-17, Win 7 4 Gig RAM
sinceV6
Advocate
Glad I could help and you found the object useful. If you can, share how you used it! It would be great to actually see it used in a project.

I know that the interface script would help a lot to lay down and see all the options in a friendly way, but I've always thought it is just too much code for that. The parameter list works for me.

Best regards.
Sebasti_n Cerda P_
Participant
Hi Since V6

Great Job!
Thanks!

I found a small bug. when I choose fixed size the 3D model does´t show wright.
sinceV6
Advocate
Well that's weird How come I didn't catch that one before? I usually test each feature thoroughly before moving on to the next one.

Anyway, great catch. Easy fix. Found a couple of variables that were wrong, and somehow the tests came clean.

segmentMiniumuSize

should be

segmentMinimumSize

in the part that checks the sizeMode variable in the masterScript.

You could just correct those or, the easy way: open the object, look for the "Calculate # of spaces per segment" part in the MasterScript and replace the whole chunk with:
 
!===CALCULATE # OF SPACES PER SEGMENT AND PARKING SPACE SIZE PER SEGMENT===== 
DIM spacesInSegment[], spaceSize[], spaceSize3D[] 
 
FOR i=1 TO segments+1 
	IF segmentMinimumSize < minSizes THEN segmentMinimumSize = minSizes 
NEXT i 
segmentMinimumSize[points+1]=spaceMinimumSize 
 
PARAMETERS segmentMinimumSize = segmentMinimumSize 
 
FOR i=1 TO segments 
	IF segmentControl<0 THEN 
		spacesInSegment=0 
		GOTO 'NEXT SEGMENT SPACES' 
	ENDIF 
	!========== 
	IF constantMinimumSize THEN 
		spacesInSegment = INT(hypotenuse2D/spaceMinimumSize) 
	ELSE 
		spacesInSegment = INT(hypotenuse2D/segmentMinimumSize) 
	ENDIF 
 
	spacesInSegment = spacesInSegment 
	!========== 
	IF spacesInSegment>0 THEN 
		IF sizeMode = 'Adjusted' THEN 
			spaceSize = hypotenuse2D/spacesInSegment 
			spaceSize3D = hypotenuse3D/spacesInSegment 
		ENDIF 
		!========== 
		IF sizeMode = 'Fixed' THEN 
			IF constantMinimumSize THEN 
				spaceSize = spaceMinimumSize 
				spaceSize3D = spaceMinimumSize * (hypotenuse3D/hypotenuse2D) 
			ELSE 
				spaceSize = segmentMinimumSize 
				spaceSize3D = segmentMinimumSize * (hypotenuse3D/hypotenuse2D) 
			ENDIF 
		ENDIF 
	ENDIF 
	!========== 
 
'NEXT SEGMENT SPACES': 
 
NEXT i 
 


Should work now, if not, let me know.

Sorry for the inconvenience.

Best regards.
Sebasti_n Cerda P_
Participant
Great! Now it´s working perfectly