Esempio n. 1
0
            public override void Draw(BranchLines s)
            {
                s.SetColor(petal);

                for (int i = 0; i < 8; i++)
                {
                    float r = (float)i / 8 * TWO_PI + offset;
                    float x = Mathf.Cos(r), y = Mathf.Sin(r);
                    var   p = new Vector3(x, y, 0f) * 0.1f * t;
                    s.DrawLine(from, from + p);
                }

                s.NoLights();
                s.SetColor(head);
                s.DrawCircle(from, Quaternion.LookRotation(Vector3.forward), 0.025f * t);
            }
Esempio n. 2
0
 public virtual void Draw(BranchLines s)
 {
     s.SetColor(Color.black);
     s.DrawLine(from, cur);
     children.ForEach(c => c.Draw(s));
 }