Clearance Zone on Z axis for cable tray and fittings. Revit 22 clash detection

I’ve been searching for ways to have a clearance zone for cable trays and fittings in dynamo. I’ve seen how others have done it (Cable tray clearance – Dynamo scripts) but list.maximumitem is not outputting as max but as item.

Can you illustrate what you mean by this?

Perhaps show us your graph we can check.

Wait so what part isnt working? The directshape generation or the transparency view override?

Here is another way could probably work as well