Version: 5.3 (switch to 5.4b)
IdiomaEnglish
  • C#
  • JS

Idioma de script

Selecciona tu lenguaje de programación favorito. Todos los fragmentos de código serán mostrados en este lenguaje.

NetworkReader

class in UnityEngine.Networking

Sugiere un cambio

¡Éxito!

Gracias por ayudarnos a mejorar la calidad de la documentación de Unity. A pesar de que no podemos aceptar todas las sugerencias, leemos cada cambio propuesto por nuestros usuarios y actualizaremos los que sean aplicables.

Cerrar

No se puedo enviar

Por alguna razón su cambio sugerido no pudo ser enviado. Por favor <a>intente nuevamente</a> en unos minutos. Gracias por tomarse un tiempo para ayudarnos a mejorar la calidad de la documentación de Unity.

Cerrar

Cancelar

Cambiar al Manual

Descripción

General purpose serializer for UNET (for reading byte arrays).

This class works with NetworkWriter and is used for serializing data for UNet commands, RPC calls, events and low level messages.

Variables

PositionThe current position within the buffer.

Constructores

NetworkReaderCreates a new NetworkReader object.

Funciones Públicas

ReadBooleanReads a boolean from the stream.
ReadByteReads a byte from the stream.
ReadBytesReads a number of bytes from the stream.
ReadBytesAndSizeThis read a 16-bit byte count and a array of bytes of that size from the stream.
ReadCharReads a char from the stream.
ReadColorReads a unity Color objects.
ReadColor32Reads a unity color32 objects.
ReadDoubleReads a double from the stream.
ReadGameObjectReads a reference to a GameObject from the stream.
ReadInt16Reads a signed 16 bit integer from the stream.
ReadInt32Reads a signed 32bit integer from the stream.
ReadInt64Reads a signed 64 bit integer from the stream.
ReadMatrix4x4Reads a unity Matrix4x4 object.
ReadMessageThis is a utility function to read a typed network message from the stream.
ReadNetworkHash128Reads a NetworkHash128 assetId.
ReadNetworkIdReads a NetworkInstanceId from the stream.
ReadNetworkIdentityReads a reference to a NetworkIdentity from the stream.
ReadPackedUInt32Reads a 32-bit variable-length-encoded value.
ReadPackedUInt64Reads a 64-bit variable-length-encoded value.
ReadPlaneReads a unity Plane object.
ReadQuaternionReads a Unity Quaternion object.
ReadRayReads a Unity Ray object.
ReadRectReads a Unity Rect object.
ReadSByteReads a signed byte from the stream.
ReadSceneIdReads a NetworkSceneId from the stream.
ReadSingleReads a float from the stream.
ReadStringReads a string from the stream. (max of 32k bytes).
ReadTransformReads a reference to a Transform from the stream.
ReadUInt16Reads an unsigned 16 bit integer from the stream.
ReadUInt32Reads an unsigned 32 bit integer from the stream.
ReadUInt64Reads an unsigned 64 bit integer from the stream.
ReadVector2Reads a Unity Vector2 object.
ReadVector3Reads a Unity Vector3 objects.
ReadVector4Reads a Unity Vector4 object.
SeekZeroSets the current position of the reader's stream to the start of the stream.
ToStringReturns a string representation of the reader's buffer.