Beispiel #1
0
    /// <summary>
    /// Generates a curve
    /// </summary>
    /// <param name="renderPipes">Generate a pipe too</param>
    public void Create(bool renderPipes)
    {
        InitializeData(renderPipes);
        SetVertices();
        SetTriangles();
        mesh.RecalculateNormals();

        AlignCurveBasePoints();

        obstacleFactory = this.gameObject.AddComponent <ObstacleFactory>();
        obstacleFactory.SetCurve(this);
    }