Exemple #1
0
 public void AddSeg(Seg seg)
 {
     if (seg == null)
         throw new ArgumentNullException("seg");
     if (seg.World != world)
         throw new ArgumentException("Seg is from another world.");
     if (seg.Front == null || seg.Front.Sector != sector)
         Core.Console.LogWarning("A seg has been added to a subsector for another sector.");
     if (segs.Contains(seg))
         Core.Console.LogWarning("A seg has been added to a subsector it already exists in.");
     segs.Add(seg);
 }
Exemple #2
0
 public void AddSeg(Seg seg)
 {
     if (seg == null)
     {
         throw new ArgumentNullException("seg");
     }
     if (seg.World != world)
     {
         throw new ArgumentException("Seg is from another world.");
     }
     if (seg.Front == null || seg.Front.Sector != sector)
     {
         Core.Console.LogWarning("A seg has been added to a subsector for another sector.");
     }
     if (segs.Contains(seg))
     {
         Core.Console.LogWarning("A seg has been added to a subsector it already exists in.");
     }
     segs.Add(seg);
 }