Esempio n. 1
0
        /// <summary>
        ///  Clones a teleporter to create a new copy.
        /// </summary>
        /// <returns>A new copy of the Teleporter</returns>
        public Teleporter Clone()
        {
            var teleporter = new Teleporter(_teleportZones.Length);

            for (var i = 0; i < _teleportZones.Length; i++)
            {
                teleporter._teleportZones[i] = _teleportZones[i];
            }

            return teleporter;
        }
Esempio n. 2
0
        /// <summary>
        ///  Clones a teleporter to create a new copy.
        /// </summary>
        /// <returns>A new copy of the Teleporter</returns>
        public Teleporter Clone()
        {
            Teleporter teleporter = new Teleporter(this.teleportZones.Length);

            for (int i= 0; i < teleportZones.Length; i++)
            {
                teleporter.teleportZones[i] = teleportZones[i];
            }

            return teleporter;
        }