예제 #1
0
 public void ReserveCoverPoint(CoverPoint coverPoint)
 {
     if (coverPoint == null || coverPoint.IsValidFor(this.Body))
     {
         if (this.ReservedCoverPoint != null && this.ReservedCoverPoint != coverPoint)
         {
             this.ReservedCoverPoint.ReservedFor = null;
         }
         this.ReservedCoverPoint = coverPoint;
         if (this.ReservedCoverPoint != null)
         {
             this.ReservedCoverPoint.ReservedFor = this.Body;
             this.ReservedCoverTime = Time.time;
         }
     }
 }
 public void ReserveCoverPoint(CoverPoint coverPoint)
 {
     if (coverPoint != null && !coverPoint.IsValidFor((BaseEntity)this.Body))
     {
         return;
     }
     if (this.ReservedCoverPoint != null && this.ReservedCoverPoint != coverPoint)
     {
         this.ReservedCoverPoint.ReservedFor = (BaseEntity)null;
     }
     this.ReservedCoverPoint = coverPoint;
     if (this.ReservedCoverPoint == null)
     {
         return;
     }
     this.ReservedCoverPoint.ReservedFor = (BaseEntity)this.Body;
     this.ReservedCoverTime = Time.get_time();
 }