Exemplo n.º 1
0
    public static void Draw(Vector2[] points)
    {
        for (var i = 0; i < points.Length - 1; i++)
        {
            PointDrawer._Draw(points, i);
        }

        /*var p1 = new UnityEngine.Vector3(points[points.Length - 1].x, 0, points[points.Length - 1].y);
         * var p2 = new UnityEngine.Vector3(points[0].x, 0, points[0].y);
         * Debug.DrawLine(p1, p2);*/
    }
Exemplo n.º 2
0
    // Update is called once per frame
    void Update()
    {
        if (Points == null)
        {
            return;
        }


        var points = Points;

        PointDrawer.Draw(points);
    }
        //public void ResetPump()
        //{
        //    OnGetPoint = null;
        //    OnGetFirstPoint = null;
        //    OnGetMiddlePoint = null;
        //    OnGetLastPoint = null;
        //}

        ///// <summary>
        ///// startup event pump
        ///// </summary>
        //public void Run()
        //{
        //    TraversePositionSetAndSpringEvent(layer.PositionSet);
        //}


        #region add new event binding

        public void DrawPoint(PointDrawer pd)
        {
            OnGetPoint += pd.Draw;
        }