Esempio n. 1
0
        public ViewBump(int x, int y, ViewBump parent)
        {
            X = x;

            Y = y;

            Parent = parent;
        }
Esempio n. 2
0
        public View(Line shallowLine, Line steepLine)
        {
            ShallowLine = shallowLine;

            SteepLine = steepLine;

            ShallowBump = null;

            SteepBump = null;
        }
Esempio n. 3
0
        private void AddSteepBump(int x, int y, List <View> activeViews, int viewIndex)
        {
            activeViews[viewIndex].SteepLine.End = new Vector2Int(x, y);

            activeViews[viewIndex].SteepBump = new ViewBump(x, y, activeViews[viewIndex].SteepBump);

            ViewBump currentBump = activeViews[viewIndex].ShallowBump;

            while (currentBump != null)
            {
                if (activeViews[viewIndex].SteepLine.Below(currentBump.X, currentBump.Y))
                {
                    activeViews[viewIndex].SteepLine.Begin = new Vector2Int(currentBump.X, currentBump.Y);
                }

                currentBump = currentBump.Parent;
            }
        }
Esempio n. 4
0
    private static void AddSteepBump(Vector2Int p, IList <View> activeViews, int viewIndex)
    {
        activeViews[viewIndex].SteepLine.xf = p.x;
        activeViews[viewIndex].SteepLine.yf = p.y;

        activeViews[viewIndex].SteepBump = new ViewBump(p, activeViews[viewIndex].SteepBump);

        ViewBump currentBump = activeViews[viewIndex].ShallowBump;

        while (currentBump != null)
        {
            if (activeViews[viewIndex].SteepLine.Below(currentBump.P))
            {
                activeViews[viewIndex].SteepLine.xi = currentBump.P.x;
                activeViews[viewIndex].SteepLine.yi = currentBump.P.y;
            }

            currentBump = currentBump.Parent;
        }
    }
Esempio n. 5
0
 public ViewBump(Vector2Int p, ViewBump parent)
 {
     P = p;
     Parent = parent;
 }
Esempio n. 6
0
 public ViewBump(Vector2Int p, ViewBump parent)
 {
     P      = p;
     Parent = parent;
 }