| | 1 | | // <auto-generated> |
| | 2 | | // Generated by the protocol buffer compiler. DO NOT EDIT! |
| | 3 | | // source: decentraland/sdk/components/audio_source.proto |
| | 4 | | // </auto-generated> |
| | 5 | | #pragma warning disable 1591, 0612, 3021 |
| | 6 | | #region Designer generated code |
| | 7 | |
|
| | 8 | | using pb = global::Google.Protobuf; |
| | 9 | | using pbc = global::Google.Protobuf.Collections; |
| | 10 | | using pbr = global::Google.Protobuf.Reflection; |
| | 11 | | using scg = global::System.Collections.Generic; |
| | 12 | | namespace DCL.ECSComponents { |
| | 13 | |
|
| | 14 | | /// <summary>Holder for reflection information generated from decentraland/sdk/components/audio_source.proto</summary> |
| | 15 | | public static partial class AudioSourceReflection { |
| | 16 | |
|
| | 17 | | #region Descriptor |
| | 18 | | /// <summary>File descriptor for decentraland/sdk/components/audio_source.proto</summary> |
| | 19 | | public static pbr::FileDescriptor Descriptor { |
| | 20 | | get { return descriptor; } |
| | 21 | | } |
| | 22 | | private static pbr::FileDescriptor descriptor; |
| | 23 | |
|
| | 24 | | static AudioSourceReflection() { |
| | 25 | | byte[] descriptorData = global::System.Convert.FromBase64String( |
| | 26 | | string.Concat( |
| | 27 | | "Ci5kZWNlbnRyYWxhbmQvc2RrL2NvbXBvbmVudHMvYXVkaW9fc291cmNlLnBy", |
| | 28 | | "b3RvEhtkZWNlbnRyYWxhbmQuc2RrLmNvbXBvbmVudHMi7wEKDVBCQXVkaW9T", |
| | 29 | | "b3VyY2USFAoHcGxheWluZxgBIAEoCEgAiAEBEhMKBnZvbHVtZRgCIAEoAkgB", |
| | 30 | | "iAEBEhEKBGxvb3AYAyABKAhIAogBARISCgVwaXRjaBgEIAEoAkgDiAEBEhYK", |
| | 31 | | "DmF1ZGlvX2NsaXBfdXJsGAUgASgJEhkKDGN1cnJlbnRfdGltZRgGIAEoAkgE", |
| | 32 | | "iAEBEhMKBmdsb2JhbBgHIAEoCEgFiAEBQgoKCF9wbGF5aW5nQgkKB192b2x1", |
| | 33 | | "bWVCBwoFX2xvb3BCCAoGX3BpdGNoQg8KDV9jdXJyZW50X3RpbWVCCQoHX2ds", |
| | 34 | | "b2JhbEIUqgIRRENMLkVDU0NvbXBvbmVudHNiBnByb3RvMw==")); |
| | 35 | | descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, |
| | 36 | | new pbr::FileDescriptor[] { }, |
| | 37 | | new pbr::GeneratedClrTypeInfo(null, null, new pbr::GeneratedClrTypeInfo[] { |
| | 38 | | new pbr::GeneratedClrTypeInfo(typeof(global::DCL.ECSComponents.PBAudioSource), global::DCL.ECSComponents.PBA |
| | 39 | | })); |
| | 40 | | } |
| | 41 | | #endregion |
| | 42 | |
|
| | 43 | | } |
| | 44 | | #region Messages |
| | 45 | | /// <summary> |
| | 46 | | /// The AudioSource component can play an audio clips bundled with the scene, controlling some |
| | 47 | | /// of the behavior. |
| | 48 | | /// |
| | 49 | | /// In each AudioSource instance, the sound is spatially located at the associated entity’s position, |
| | 50 | | /// given by its Transform. |
| | 51 | | /// |
| | 52 | | /// Note that the `audio_clip_url` is not actually a URL, but rather the path of a file bundled with |
| | 53 | | /// the scene and declared in its manifest. The name was chosen because the URL use-case will |
| | 54 | | /// eventually be supported. |
| | 55 | | /// |
| | 56 | | /// `playing=true` when it's previously `playing=true` |
| | 57 | | /// a) if clip is playing and `current_time` is NOT SET, the clip remains in the current `current_time` |
| | 58 | | /// b) if clip is stopped or `current_time` is set, the clip is played from the `current_time` (if set) or from the b |
| | 59 | | /// |
| | 60 | | /// If other property (volume, loop, pitch) is changed while playing, the clip is keep playing with the new properties |
| | 61 | | /// Changing `audio_clip_url` while playing stops the current clip and plays the new one (as a new instance) |
| | 62 | | /// </summary> |
| | 63 | | public sealed partial class PBAudioSource : pb::IMessage<PBAudioSource> |
| | 64 | | #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE |
| | 65 | | , pb::IBufferMessage |
| | 66 | | #endif |
| | 67 | | { |
| 1 | 68 | | private static readonly pb::MessageParser<PBAudioSource> _parser = new pb::MessageParser<PBAudioSource>(() => new PB |
| | 69 | | private pb::UnknownFieldSet _unknownFields; |
| | 70 | | private int _hasBits0; |
| | 71 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 72 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| 0 | 73 | | public static pb::MessageParser<PBAudioSource> Parser { get { return _parser; } } |
| | 74 | |
|
| | 75 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 76 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 77 | | public static pbr::MessageDescriptor Descriptor { |
| 0 | 78 | | get { return global::DCL.ECSComponents.AudioSourceReflection.Descriptor.MessageTypes[0]; } |
| | 79 | | } |
| | 80 | |
|
| | 81 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 82 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 83 | | pbr::MessageDescriptor pb::IMessage.Descriptor { |
| 0 | 84 | | get { return Descriptor; } |
| | 85 | | } |
| | 86 | |
|
| | 87 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 88 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| 14 | 89 | | public PBAudioSource() { |
| | 90 | | OnConstruction(); |
| 14 | 91 | | } |
| | 92 | |
|
| | 93 | | partial void OnConstruction(); |
| | 94 | |
|
| | 95 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 96 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| 0 | 97 | | public PBAudioSource(PBAudioSource other) : this() { |
| 0 | 98 | | _hasBits0 = other._hasBits0; |
| 0 | 99 | | playing_ = other.playing_; |
| 0 | 100 | | volume_ = other.volume_; |
| 0 | 101 | | loop_ = other.loop_; |
| 0 | 102 | | pitch_ = other.pitch_; |
| 0 | 103 | | audioClipUrl_ = other.audioClipUrl_; |
| 0 | 104 | | currentTime_ = other.currentTime_; |
| 0 | 105 | | global_ = other.global_; |
| 0 | 106 | | _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); |
| 0 | 107 | | } |
| | 108 | |
|
| | 109 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 110 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 111 | | public PBAudioSource Clone() { |
| 0 | 112 | | return new PBAudioSource(this); |
| | 113 | | } |
| | 114 | |
|
| | 115 | | /// <summary>Field number for the "playing" field.</summary> |
| | 116 | | public const int PlayingFieldNumber = 1; |
| | 117 | | private bool playing_; |
| | 118 | | /// <summary> |
| | 119 | | /// whether the clip is currently playing. |
| | 120 | | /// </summary> |
| | 121 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 122 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 123 | | public bool Playing { |
| 34 | 124 | | get { if ((_hasBits0 & 1) != 0) { return playing_; } else { return false; } } |
| | 125 | | set { |
| 6 | 126 | | _hasBits0 |= 1; |
| 6 | 127 | | playing_ = value; |
| 6 | 128 | | } |
| | 129 | | } |
| | 130 | | /// <summary>Gets whether the "playing" field is set</summary> |
| | 131 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 132 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 133 | | public bool HasPlaying { |
| 0 | 134 | | get { return (_hasBits0 & 1) != 0; } |
| | 135 | | } |
| | 136 | | /// <summary>Clears the value of the "playing" field</summary> |
| | 137 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 138 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 139 | | public void ClearPlaying() { |
| 0 | 140 | | _hasBits0 &= ~1; |
| 0 | 141 | | } |
| | 142 | |
|
| | 143 | | /// <summary>Field number for the "volume" field.</summary> |
| | 144 | | public const int VolumeFieldNumber = 2; |
| | 145 | | private float volume_; |
| | 146 | | /// <summary> |
| | 147 | | /// the audio volume (default: 1.0). |
| | 148 | | /// </summary> |
| | 149 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 150 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 151 | | public float Volume { |
| 26 | 152 | | get { if ((_hasBits0 & 2) != 0) { return volume_; } else { return 0F; } } |
| | 153 | | set { |
| 8 | 154 | | _hasBits0 |= 2; |
| 8 | 155 | | volume_ = value; |
| 8 | 156 | | } |
| | 157 | | } |
| | 158 | | /// <summary>Gets whether the "volume" field is set</summary> |
| | 159 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 160 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 161 | | public bool HasVolume { |
| 18 | 162 | | get { return (_hasBits0 & 2) != 0; } |
| | 163 | | } |
| | 164 | | /// <summary>Clears the value of the "volume" field</summary> |
| | 165 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 166 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 167 | | public void ClearVolume() { |
| 0 | 168 | | _hasBits0 &= ~2; |
| 0 | 169 | | } |
| | 170 | |
|
| | 171 | | /// <summary>Field number for the "loop" field.</summary> |
| | 172 | | public const int LoopFieldNumber = 3; |
| | 173 | | private bool loop_; |
| | 174 | | /// <summary> |
| | 175 | | /// whether the clip should restart when finished. |
| | 176 | | /// </summary> |
| | 177 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 178 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 179 | | public bool Loop { |
| 36 | 180 | | get { if ((_hasBits0 & 4) != 0) { return loop_; } else { return false; } } |
| | 181 | | set { |
| 3 | 182 | | _hasBits0 |= 4; |
| 3 | 183 | | loop_ = value; |
| 3 | 184 | | } |
| | 185 | | } |
| | 186 | | /// <summary>Gets whether the "loop" field is set</summary> |
| | 187 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 188 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 189 | | public bool HasLoop { |
| 0 | 190 | | get { return (_hasBits0 & 4) != 0; } |
| | 191 | | } |
| | 192 | | /// <summary>Clears the value of the "loop" field</summary> |
| | 193 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 194 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 195 | | public void ClearLoop() { |
| 0 | 196 | | _hasBits0 &= ~4; |
| 0 | 197 | | } |
| | 198 | |
|
| | 199 | | /// <summary>Field number for the "pitch" field.</summary> |
| | 200 | | public const int PitchFieldNumber = 4; |
| | 201 | | private float pitch_; |
| | 202 | | /// <summary> |
| | 203 | | /// the audio pitch (default: 1.0). |
| | 204 | | /// </summary> |
| | 205 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 206 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 207 | | public float Pitch { |
| 6 | 208 | | get { if ((_hasBits0 & 8) != 0) { return pitch_; } else { return 0F; } } |
| | 209 | | set { |
| 2 | 210 | | _hasBits0 |= 8; |
| 2 | 211 | | pitch_ = value; |
| 2 | 212 | | } |
| | 213 | | } |
| | 214 | | /// <summary>Gets whether the "pitch" field is set</summary> |
| | 215 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 216 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 217 | | public bool HasPitch { |
| 17 | 218 | | get { return (_hasBits0 & 8) != 0; } |
| | 219 | | } |
| | 220 | | /// <summary>Clears the value of the "pitch" field</summary> |
| | 221 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 222 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 223 | | public void ClearPitch() { |
| 0 | 224 | | _hasBits0 &= ~8; |
| 0 | 225 | | } |
| | 226 | |
|
| | 227 | | /// <summary>Field number for the "audio_clip_url" field.</summary> |
| | 228 | | public const int AudioClipUrlFieldNumber = 5; |
| 14 | 229 | | private string audioClipUrl_ = ""; |
| | 230 | | /// <summary> |
| | 231 | | /// the clip path as given in the `files` array of the scene's manifest. |
| | 232 | | /// </summary> |
| | 233 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 234 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 235 | | public string AudioClipUrl { |
| 28 | 236 | | get { return audioClipUrl_; } |
| | 237 | | set { |
| 14 | 238 | | audioClipUrl_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); |
| 14 | 239 | | } |
| | 240 | | } |
| | 241 | |
|
| | 242 | | /// <summary>Field number for the "current_time" field.</summary> |
| | 243 | | public const int CurrentTimeFieldNumber = 6; |
| | 244 | | private float currentTime_; |
| | 245 | | /// <summary> |
| | 246 | | /// specifies the current playback time of the clip in seconds (default: 0). |
| | 247 | | /// </summary> |
| | 248 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 249 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 250 | | public float CurrentTime { |
| 0 | 251 | | get { if ((_hasBits0 & 16) != 0) { return currentTime_; } else { return 0F; } } |
| | 252 | | set { |
| 0 | 253 | | _hasBits0 |= 16; |
| 0 | 254 | | currentTime_ = value; |
| 0 | 255 | | } |
| | 256 | | } |
| | 257 | | /// <summary>Gets whether the "current_time" field is set</summary> |
| | 258 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 259 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 260 | | public bool HasCurrentTime { |
| 0 | 261 | | get { return (_hasBits0 & 16) != 0; } |
| | 262 | | } |
| | 263 | | /// <summary>Clears the value of the "current_time" field</summary> |
| | 264 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 265 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 266 | | public void ClearCurrentTime() { |
| 0 | 267 | | _hasBits0 &= ~16; |
| 0 | 268 | | } |
| | 269 | |
|
| | 270 | | /// <summary>Field number for the "global" field.</summary> |
| | 271 | | public const int GlobalFieldNumber = 7; |
| | 272 | | private bool global_; |
| | 273 | | /// <summary> |
| | 274 | | /// whether the audio plays at constant volume across the scene. |
| | 275 | | /// </summary> |
| | 276 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 277 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 278 | | public bool Global { |
| 0 | 279 | | get { if ((_hasBits0 & 32) != 0) { return global_; } else { return false; } } |
| | 280 | | set { |
| 0 | 281 | | _hasBits0 |= 32; |
| 0 | 282 | | global_ = value; |
| 0 | 283 | | } |
| | 284 | | } |
| | 285 | | /// <summary>Gets whether the "global" field is set</summary> |
| | 286 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 287 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 288 | | public bool HasGlobal { |
| 0 | 289 | | get { return (_hasBits0 & 32) != 0; } |
| | 290 | | } |
| | 291 | | /// <summary>Clears the value of the "global" field</summary> |
| | 292 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 293 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 294 | | public void ClearGlobal() { |
| 0 | 295 | | _hasBits0 &= ~32; |
| 0 | 296 | | } |
| | 297 | |
|
| | 298 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 299 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 300 | | public override bool Equals(object other) { |
| 0 | 301 | | return Equals(other as PBAudioSource); |
| | 302 | | } |
| | 303 | |
|
| | 304 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 305 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 306 | | public bool Equals(PBAudioSource other) { |
| 0 | 307 | | if (ReferenceEquals(other, null)) { |
| 0 | 308 | | return false; |
| | 309 | | } |
| 0 | 310 | | if (ReferenceEquals(other, this)) { |
| 0 | 311 | | return true; |
| | 312 | | } |
| 0 | 313 | | if (Playing != other.Playing) return false; |
| 0 | 314 | | if (!pbc::ProtobufEqualityComparers.BitwiseSingleEqualityComparer.Equals(Volume, other.Volume)) return false; |
| 0 | 315 | | if (Loop != other.Loop) return false; |
| 0 | 316 | | if (!pbc::ProtobufEqualityComparers.BitwiseSingleEqualityComparer.Equals(Pitch, other.Pitch)) return false; |
| 0 | 317 | | if (AudioClipUrl != other.AudioClipUrl) return false; |
| 0 | 318 | | if (!pbc::ProtobufEqualityComparers.BitwiseSingleEqualityComparer.Equals(CurrentTime, other.CurrentTime)) return f |
| 0 | 319 | | if (Global != other.Global) return false; |
| 0 | 320 | | return Equals(_unknownFields, other._unknownFields); |
| | 321 | | } |
| | 322 | |
|
| | 323 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 324 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 325 | | public override int GetHashCode() { |
| 0 | 326 | | int hash = 1; |
| 0 | 327 | | if (HasPlaying) hash ^= Playing.GetHashCode(); |
| 0 | 328 | | if (HasVolume) hash ^= pbc::ProtobufEqualityComparers.BitwiseSingleEqualityComparer.GetHashCode(Volume); |
| 0 | 329 | | if (HasLoop) hash ^= Loop.GetHashCode(); |
| 0 | 330 | | if (HasPitch) hash ^= pbc::ProtobufEqualityComparers.BitwiseSingleEqualityComparer.GetHashCode(Pitch); |
| 0 | 331 | | if (AudioClipUrl.Length != 0) hash ^= AudioClipUrl.GetHashCode(); |
| 0 | 332 | | if (HasCurrentTime) hash ^= pbc::ProtobufEqualityComparers.BitwiseSingleEqualityComparer.GetHashCode(CurrentTime); |
| 0 | 333 | | if (HasGlobal) hash ^= Global.GetHashCode(); |
| 0 | 334 | | if (_unknownFields != null) { |
| 0 | 335 | | hash ^= _unknownFields.GetHashCode(); |
| | 336 | | } |
| 0 | 337 | | return hash; |
| | 338 | | } |
| | 339 | |
|
| | 340 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 341 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 342 | | public override string ToString() { |
| 0 | 343 | | return pb::JsonFormatter.ToDiagnosticString(this); |
| | 344 | | } |
| | 345 | |
|
| | 346 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 347 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 348 | | public void WriteTo(pb::CodedOutputStream output) { |
| | 349 | | #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE |
| | 350 | | output.WriteRawMessage(this); |
| | 351 | | #else |
| 0 | 352 | | if (HasPlaying) { |
| 0 | 353 | | output.WriteRawTag(8); |
| 0 | 354 | | output.WriteBool(Playing); |
| | 355 | | } |
| 0 | 356 | | if (HasVolume) { |
| 0 | 357 | | output.WriteRawTag(21); |
| 0 | 358 | | output.WriteFloat(Volume); |
| | 359 | | } |
| 0 | 360 | | if (HasLoop) { |
| 0 | 361 | | output.WriteRawTag(24); |
| 0 | 362 | | output.WriteBool(Loop); |
| | 363 | | } |
| 0 | 364 | | if (HasPitch) { |
| 0 | 365 | | output.WriteRawTag(37); |
| 0 | 366 | | output.WriteFloat(Pitch); |
| | 367 | | } |
| 0 | 368 | | if (AudioClipUrl.Length != 0) { |
| 0 | 369 | | output.WriteRawTag(42); |
| 0 | 370 | | output.WriteString(AudioClipUrl); |
| | 371 | | } |
| 0 | 372 | | if (HasCurrentTime) { |
| 0 | 373 | | output.WriteRawTag(53); |
| 0 | 374 | | output.WriteFloat(CurrentTime); |
| | 375 | | } |
| 0 | 376 | | if (HasGlobal) { |
| 0 | 377 | | output.WriteRawTag(56); |
| 0 | 378 | | output.WriteBool(Global); |
| | 379 | | } |
| 0 | 380 | | if (_unknownFields != null) { |
| 0 | 381 | | _unknownFields.WriteTo(output); |
| | 382 | | } |
| | 383 | | #endif |
| 0 | 384 | | } |
| | 385 | |
|
| | 386 | | #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE |
| | 387 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 388 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 389 | | void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { |
| | 390 | | if (HasPlaying) { |
| | 391 | | output.WriteRawTag(8); |
| | 392 | | output.WriteBool(Playing); |
| | 393 | | } |
| | 394 | | if (HasVolume) { |
| | 395 | | output.WriteRawTag(21); |
| | 396 | | output.WriteFloat(Volume); |
| | 397 | | } |
| | 398 | | if (HasLoop) { |
| | 399 | | output.WriteRawTag(24); |
| | 400 | | output.WriteBool(Loop); |
| | 401 | | } |
| | 402 | | if (HasPitch) { |
| | 403 | | output.WriteRawTag(37); |
| | 404 | | output.WriteFloat(Pitch); |
| | 405 | | } |
| | 406 | | if (AudioClipUrl.Length != 0) { |
| | 407 | | output.WriteRawTag(42); |
| | 408 | | output.WriteString(AudioClipUrl); |
| | 409 | | } |
| | 410 | | if (HasCurrentTime) { |
| | 411 | | output.WriteRawTag(53); |
| | 412 | | output.WriteFloat(CurrentTime); |
| | 413 | | } |
| | 414 | | if (HasGlobal) { |
| | 415 | | output.WriteRawTag(56); |
| | 416 | | output.WriteBool(Global); |
| | 417 | | } |
| | 418 | | if (_unknownFields != null) { |
| | 419 | | _unknownFields.WriteTo(ref output); |
| | 420 | | } |
| | 421 | | } |
| | 422 | | #endif |
| | 423 | |
|
| | 424 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 425 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 426 | | public int CalculateSize() { |
| 0 | 427 | | int size = 0; |
| 0 | 428 | | if (HasPlaying) { |
| 0 | 429 | | size += 1 + 1; |
| | 430 | | } |
| 0 | 431 | | if (HasVolume) { |
| 0 | 432 | | size += 1 + 4; |
| | 433 | | } |
| 0 | 434 | | if (HasLoop) { |
| 0 | 435 | | size += 1 + 1; |
| | 436 | | } |
| 0 | 437 | | if (HasPitch) { |
| 0 | 438 | | size += 1 + 4; |
| | 439 | | } |
| 0 | 440 | | if (AudioClipUrl.Length != 0) { |
| 0 | 441 | | size += 1 + pb::CodedOutputStream.ComputeStringSize(AudioClipUrl); |
| | 442 | | } |
| 0 | 443 | | if (HasCurrentTime) { |
| 0 | 444 | | size += 1 + 4; |
| | 445 | | } |
| 0 | 446 | | if (HasGlobal) { |
| 0 | 447 | | size += 1 + 1; |
| | 448 | | } |
| 0 | 449 | | if (_unknownFields != null) { |
| 0 | 450 | | size += _unknownFields.CalculateSize(); |
| | 451 | | } |
| 0 | 452 | | return size; |
| | 453 | | } |
| | 454 | |
|
| | 455 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 456 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 457 | | public void MergeFrom(PBAudioSource other) { |
| 0 | 458 | | if (other == null) { |
| 0 | 459 | | return; |
| | 460 | | } |
| 0 | 461 | | if (other.HasPlaying) { |
| 0 | 462 | | Playing = other.Playing; |
| | 463 | | } |
| 0 | 464 | | if (other.HasVolume) { |
| 0 | 465 | | Volume = other.Volume; |
| | 466 | | } |
| 0 | 467 | | if (other.HasLoop) { |
| 0 | 468 | | Loop = other.Loop; |
| | 469 | | } |
| 0 | 470 | | if (other.HasPitch) { |
| 0 | 471 | | Pitch = other.Pitch; |
| | 472 | | } |
| 0 | 473 | | if (other.AudioClipUrl.Length != 0) { |
| 0 | 474 | | AudioClipUrl = other.AudioClipUrl; |
| | 475 | | } |
| 0 | 476 | | if (other.HasCurrentTime) { |
| 0 | 477 | | CurrentTime = other.CurrentTime; |
| | 478 | | } |
| 0 | 479 | | if (other.HasGlobal) { |
| 0 | 480 | | Global = other.Global; |
| | 481 | | } |
| 0 | 482 | | _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); |
| 0 | 483 | | } |
| | 484 | |
|
| | 485 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 486 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 487 | | public void MergeFrom(pb::CodedInputStream input) { |
| | 488 | | #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE |
| | 489 | | input.ReadRawMessage(this); |
| | 490 | | #else |
| | 491 | | uint tag; |
| 0 | 492 | | while ((tag = input.ReadTag()) != 0) { |
| | 493 | | switch(tag) { |
| | 494 | | default: |
| 0 | 495 | | _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); |
| 0 | 496 | | break; |
| | 497 | | case 8: { |
| 0 | 498 | | Playing = input.ReadBool(); |
| 0 | 499 | | break; |
| | 500 | | } |
| | 501 | | case 21: { |
| 0 | 502 | | Volume = input.ReadFloat(); |
| 0 | 503 | | break; |
| | 504 | | } |
| | 505 | | case 24: { |
| 0 | 506 | | Loop = input.ReadBool(); |
| 0 | 507 | | break; |
| | 508 | | } |
| | 509 | | case 37: { |
| 0 | 510 | | Pitch = input.ReadFloat(); |
| 0 | 511 | | break; |
| | 512 | | } |
| | 513 | | case 42: { |
| 0 | 514 | | AudioClipUrl = input.ReadString(); |
| 0 | 515 | | break; |
| | 516 | | } |
| | 517 | | case 53: { |
| 0 | 518 | | CurrentTime = input.ReadFloat(); |
| 0 | 519 | | break; |
| | 520 | | } |
| | 521 | | case 56: { |
| 0 | 522 | | Global = input.ReadBool(); |
| | 523 | | break; |
| | 524 | | } |
| | 525 | | } |
| | 526 | | } |
| | 527 | | #endif |
| 0 | 528 | | } |
| | 529 | |
|
| | 530 | | #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE |
| | 531 | | [global::System.Diagnostics.DebuggerNonUserCodeAttribute] |
| | 532 | | [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] |
| | 533 | | void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { |
| | 534 | | uint tag; |
| | 535 | | while ((tag = input.ReadTag()) != 0) { |
| | 536 | | switch(tag) { |
| | 537 | | default: |
| | 538 | | _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); |
| | 539 | | break; |
| | 540 | | case 8: { |
| | 541 | | Playing = input.ReadBool(); |
| | 542 | | break; |
| | 543 | | } |
| | 544 | | case 21: { |
| | 545 | | Volume = input.ReadFloat(); |
| | 546 | | break; |
| | 547 | | } |
| | 548 | | case 24: { |
| | 549 | | Loop = input.ReadBool(); |
| | 550 | | break; |
| | 551 | | } |
| | 552 | | case 37: { |
| | 553 | | Pitch = input.ReadFloat(); |
| | 554 | | break; |
| | 555 | | } |
| | 556 | | case 42: { |
| | 557 | | AudioClipUrl = input.ReadString(); |
| | 558 | | break; |
| | 559 | | } |
| | 560 | | case 53: { |
| | 561 | | CurrentTime = input.ReadFloat(); |
| | 562 | | break; |
| | 563 | | } |
| | 564 | | case 56: { |
| | 565 | | Global = input.ReadBool(); |
| | 566 | | break; |
| | 567 | | } |
| | 568 | | } |
| | 569 | | } |
| | 570 | | } |
| | 571 | | #endif |
| | 572 | |
|
| | 573 | | } |
| | 574 | |
|
| | 575 | | #endregion |
| | 576 | |
|
| | 577 | | } |
| | 578 | |
|
| | 579 | | #endregion Designer generated code |