예제 #1
0
		public void Initialize(Contour terrain, ContourSegmentConfig config, ContourSegmentAttributes attributes) {
			this.terrain = terrain;
			this.config = config;
			this.attributes = attributes;

			transform.parent = terrain.transform;
			transform.localPosition = Vector2.zero;

			CalculateSlopeVector();
			CalculatePerpendicularSlopeVector();
			GenerateEndPoint();
			GenerateMidPoints();
	//		BumpifyMidPointsIfNeeded();
			CollectAllPointsInList();
			CalculateSurfaceMeasures();
			CalculateDistAtEnd();
		}
예제 #2
0
		public ContourSegmentGenerator(ContourSegmentAttributes attributes) {
			this.attributes = attributes;
		}