Beispiel #1
0
        public void AddTo(double x, double z, string type, bool invert)
        {
            if (!stripping)
            {
                throw new InvalidOperationException("Can't add wall: strip belum mulai.");
            }
            if (!this.stripStarted)
            {
                throw new InvalidOperationException("Can't add wall: butuh tembok untuk memulai strip");
            }
            Wall last = this.last;
            Wall next;

            if (!invert)
            {
                next = WallBuilder.BuildWall(last.To, new Point3D(x, 0, z), bottom, height, type);
            }
            else
            {
                next = new InvertedWall(WallBuilder.BuildWall(new Point3D(x, 0, z), last.To, bottom, height, type));
            }
            this.walls.Add(next);
            last.after  = next.To;
            next.before = last.From;
            this.last   = next;
            this.closewall();
        }
Beispiel #2
0
        public void AddTo(double x, double z, string type, bool invert)
        {
            if (!stripping)
            {
                throw new InvalidOperationException("Can't add wall: strip not started.");
            }
            if (!this.stripStarted)
            {
                throw new InvalidOperationException("Can't add wall: need the first wall of the strip");
            }
            Wall last = this.last;            //(Wall)walls[walls.Count-1];
            Wall next;

            if (!invert)
            {
                next = WallBuilder.BuildWall(last.To, new Point3D(x, 0, z), bottom, height, type);
            }
            else
            {
                next = new InvertedWall(WallBuilder.BuildWall(new Point3D(x, 0, z), last.To, bottom, height, type));
            }
            this.walls.Add(next);
            last.after  = next.To;
            next.before = last.From;
            this.last   = next;
            this.closewall();
        }
Beispiel #3
0
 public void Add(double fx, double fz, double tx, double tz, string type)
 {
     if (!stripping)
     {
         throw new InvalidOperationException("Can't add wall: strip belum dimulai");
     }
     last = WallBuilder.BuildWall(new Point3D(fx, 0, fz), new Point3D(tx, 0, tz), bottom, height, type);
     walls.Add(last);
     this.closewall();
     if (!this.stripStarted)
     {
         last.CloseFrom(this.stripCloseStart);
         this.stripStarted = true;
     }
 }