Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 11 Next capture
2021 2022 2023
1 capture
11 Jun 22 - 11 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by srylain · Aug 03, 2015 at 05:30 PM · audiosource

AudioSource.PlayDelayed() bug

I've been using AudioSource.PlayDelayed() in order to ensure that the audio starts at the exact time I need it to, and have found that sometimes it plays a small bit of the audio when the function is called.

Is this a bug or is there something I'm missing? I haven't tried it yet, but would just setting the volume of the AudioSource to zero and then back up later be a good workaround?

Comment
Add comment · Show 5
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Bears · Aug 19, 2015 at 03:53 PM 0
Share

I'm having the same exact issue. Have you found a fix for this or are you still just adjusting the volumes?

avatar image YoungDeveloper · Aug 19, 2015 at 03:57 PM 0
Share

have you tried creating your own wrapper functions?

avatar image srylain · Aug 19, 2015 at 05:32 PM 0
Share

I've think I found that this happens because there's a CPU spike or something, not quite sure why it still happens but I believe it just has something to do with the current CPU load.

I haven't actually done anything to try and fix it yet (as it's not that bad of a problem), but I was just posting this to see if there was a way to fix it when it comes time for me to actually fix it.

In my case, what's happening is that I switch to a new scene, start loading my audio (there are multiple clips, I stream them), and whenever it happens it happens before the scene even changes over to show the new one.

avatar image rumaniel · Feb 02, 2016 at 07:08 AM 0
Share

Still occurring this issue in Unity 4.9.1f1

avatar image KarlKarl2000 · Aug 21, 2016 at 03:48 PM 0
Share

I have this same bug too.. its on AUdioSource.play and AudioSource.playdelayed... frustrating :(

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by Craftnime · Aug 27, 2015 at 06:09 AM

 yield WaitForSeconds(AmountOfTime);
 AudioSource.Play();

If you want an Audio source to start after a certain amount of time, use the above. HOWEVER, this will NOT work in Update().

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

7 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

What does the numSamples parameter in GetOutputData actually mean? 1 Answer

AudioClips automatically fastforwarding at beginning of scenes 0 Answers

audiosources not playing after object destruction 0 Answers

Add animation for volume of BGM audiosource 0 Answers

Audio Clip duration not getting updated 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges