Example #1
0
        private void WriteStateful(NetDataWriter writer)
        {
            foreach (var kvp in world.statefulObjects)
            {
                if (arbiter || kvp.Value.Ownable.HasAuthority(remoteID))
                {
                    IStreamable streamable = kvp.Value.GetComponent <IStreamable>();

                    if (streamable != null)
                    {
                        writer.Put(kvp.Key);
                        streamable.Write(writer);
                    }
                }
            }
        }
Example #2
0
        private void WriteStateful(NetDataWriter writer)
        {
            foreach (var kvp in world.statefulObjects)
            {
                if (arbiter)
                {
                    IStreamable streamable = kvp.Value.GetComponent <IStreamable>();

                    if (streamable != null)
                    {
                        writer.Put(kvp.Key);
                        writer.Put(kvp.Value.Identity.GUID);
                        streamable.Write(writer);
                    }
                }
            }
        }
Example #3
0
 /// <summary>
 ///
 /// </summary>
 public virtual int Write(byte[] buffer, int offset, int count)
 {
     return(m_RawStream.Write(buffer, offset, count));
 }