public void OnEnable(TinySelector selector, TinyBuffer buffer)
 {
     _selector = selector;
     _buffer   = buffer;
 }
        public static TinyNode GetNodeUnder(this TinyGraph graph, Vector2 point, TinySelector selector = null)
        {
            var nodes = graph.Nodes.Where(x => TinyGUI.GetNodeRect(x.Position).Contains(point));

            return(selector == null?nodes.FirstOrDefault() : nodes.OrderByDescending(selector.IsSelected).FirstOrDefault());
        }
Beispiel #3
0
 public void OnEnable(TinySelector selector) =>
 _selector = selector;