Placing trusses with dynamo and python

I got pretty far in my dynamo sqript. Even used Python to get the desired result. Next step now is to find a way to lock the top Chord beam joins.
Then still I have to figure out a way how to use this script when I have different diagonal profiles within one truss. I could changes then manually off course. But when some of the main parameters changes and I have to run the script again, and my changes I did manually will be lost. And have to change the desired diagonals again manually.

Revit version 2018.3 and dynamo is