/// <summary> /// Serialize struct to NetDataWriter (fast) /// </summary> /// <param name="writer">Serialization target NetDataWriter</param> /// <param name="obj">Struct to serialize</param> public void Serialize <T>(NetDataWriter writer, T obj) where T : class, new() { StructInfo info = RegisterInternal <T>(); _hasher.WriteHash(info.Hash, writer); info.Write(writer, obj); }