예제 #1
0
 /// <summary>
 ///
 /// </summary>
 /// <param name="_owner"></param>
 /// <param name="_x"></param>
 /// <param name="_y"></param>
 /// <param name="_z"></param>
 /// <param name="wloc"></param>
 protected internal VoxelImpl(VarHeightBuilding _owner, byte _x, byte _y, byte _z, WorldLocator wloc)
     : base(_owner, wloc)
 {
     this.x = _x;
     this.y = _y;
     this.z = _z;
 }
예제 #2
0
            /// <summary>
            ///
            /// </summary>
            /// <param name="display"></param>
            /// <param name="pt"></param>
            /// <param name="heightCutDiff"></param>
            public override void Draw(DrawContext display, Point pt, int heightCutDiff)
            {
                VarHeightBuilding o = owner;

                if (heightCutDiff < 0)
                {
                    ISprite[] sps = o.type.GetSprites(x, y, z, o.height);
                    for (int i = 0; i < sps.Length; i++)
                    {
                        sps[i].Draw(display.Surface, pt);
                    }
                }
                else
                if (z == 0)
                {
                    ResourceUtil.EmptyChip.DrawShape(display.Surface, pt, o.heightCutColor);
                }
            }