Пример #1
0
        /// <summary>
        ///     Attaches this <see cref="GlobalObject" /> to the specified <paramref name="player" />.
        /// </summary>
        /// <param name="player">The player.</param>
        /// <param name="offset">The offset.</param>
        /// <param name="rotation">The rotation.</param>
        /// <exception cref="System.ArgumentNullException">player</exception>
        public virtual void AttachTo(BasePlayer player, Vector3 offset, Vector3 rotation)
        {
            if (player == null)
            {
                throw new ArgumentNullException(nameof(player));
            }

            Internal.AttachObjectToPlayer(Id, player.Id, offset.X, offset.Y, offset.Z, rotation.X, rotation.Y,
                                          rotation.Z);
        }