Esempio n. 1
0
        public void GetICrossSectionAdjusters(List <ICrossSectionAdjuster> activeAdjusters, Matrix4x4 basis, Vector3 vehicleMainAxis)
        {
            if (crossSectionAdjusters == null)
            {
                return;
            }

            for (int i = 0; i < crossSectionAdjusters.Count; ++i)
            {
                ICrossSectionAdjuster adjuster = crossSectionAdjusters[i];
                //adjuster.TransformBasis(basis);

                if (adjuster.AreaRemovedFromCrossSection(vehicleMainAxis) != 0)
                {
                    adjuster.SetForwardBackwardNoFlowDirection(1);
                    activeAdjusters.Add(adjuster);
                }
                else if (adjuster.AreaRemovedFromCrossSection(-vehicleMainAxis) != 0)
                {
                    adjuster.SetForwardBackwardNoFlowDirection(-1);
                    activeAdjusters.Add(adjuster);
                }
                else
                {
                    adjuster.SetForwardBackwardNoFlowDirection(0);
                }
            }
        }