MCPcopy Create free account
hub / github.com/FlaxEngine/FlaxEngine / OnDisable

Method OnDisable

Source/Engine/Audio/AudioSource.cpp:543–566  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

541}
542
543void AudioSource::OnDisable()
544{
545 // Cache playback state
546 _savedState = GetState();
547 _savedTime = GetTime();
548
549 // End playback
550 Stop();
551
552 // Remove source
553#if USE_EDITOR
554 GetSceneRendering()->RemoveViewportIcon(this);
555#endif
556 GetScene()->Ticking.Update.RemoveTick(this);
557 if (SourceID)
558 {
559 AudioBackend::Source::Remove(SourceID);
560 SourceID = 0;
561 }
562 Audio::Sources.Remove(this);
563
564 // Base
565 Actor::OnDisable();
566}
567
568void AudioSource::OnTransformChanged()
569{

Callers

nothing calls this directly

Calls 8

GetTimeFunction · 0.85
GetSceneFunction · 0.85
RemoveTickMethod · 0.80
GetStateFunction · 0.70
StopFunction · 0.50
RemoveFunction · 0.50
OnDisableFunction · 0.50
RemoveMethod · 0.45

Tested by

no test coverage detected