ReplayState Methods

Ultimate Replay

ReplayState Methods

The ReplayState type exposes the following members.

Methods
  Name Description
Public method Clear
Clears all buffered data from this ReplayState and resets its state.
Public method Read16
Read a short from the state.
Public method Read32
Read an int from the state.
Public method ReadBool
Read a bool from the state.
Public method ReadByte
Read a byte from the state.
Public method ReadBytes(Int32)
Read a byte array from the state.
Public method ReadBytes(Byte, Int32, Int32)
Fill a byte array with data from the state.
Public method ReadColor
Read a colour from the state.
Public method ReadColor32
Read a colour32 from the state.
Public method ReadFloat
Read a float from the state.
Public method ReadFloatLowPrecision
Attempts to read a low precision float. You should only use this method when the value is relativley small (less than 65000).
Public method ReadIdentity
Read a ReplayIdentity from the state.
Public method ReadQuat
Read a quaternion from the state.
Public method ReadState
Read the specified amount of bytes as a new ReplayState.
Public method ReadString
Read a string from the state
Public method ReadVec2
Read a vector2 from the state.
Public method ReadVec3
Read a vector3 from the state.
Public method ReadVec4
Read a vector4 from the state.
Public method ToArray
Get the ReplayState data as a byte array.
Public method TryReadObject
Attempts to read an object state from this ReplayState.
Public method TryWriteObject
Attempts to write an object to this ReplayState. This method may write extra meta data for deserialization purposes which may cause excessive storage size. Use one of the Write(Byte) methods if the type is known at compile time.
Public method Write(Boolean)
Write a bool to the state.
Public method Write(Byte)
Write a byte to the state.
Public method Write(Byte)
Write a byte array to the state.
Public method Write(Int16)
Write a short to the state.
Public method Write(Int32)
Write an int to the state.
Public method Write(Single)
Write a float to the state.
Public method Write(String)
Write a string to the state.
Public method Write(Color)
Write a colour to the state.
Public method Write(Color32)
Write a colour32 value to the state.
Public method Write(Quaternion)
Write a quaternion to the state.
Public method Write(Vector2)
Write a vector2 to the state.
Public method Write(Vector3)
Write a vector3 to the state.
Public method Write(Vector4)
Write a vector4 to the state.
Public method Write(ReplayIdentity)
Write the specified replay identity to this ReplayState.
Public method Write(ReplayState)
Write the entire contents of a ReplayState to this ReplayState. All bytes will be appended.
Public method Write(Byte, Int32, Int32)
Write a byte array to the state using an offset position and length.
Public method WriteLowPrecision
Attempts to write a 32 bit float value as a low precision 16 bit representation. You should only use this method when the value is relativley small (less than 65000). Accuracy may be lost by storing low precision values.
Top
See Also