Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 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 /
This question was closed Aug 17, 2013 at 07:31 AM by Fattie for the following reason:

Problem is not reproducible or outdated

avatar image
0
Question by rafaelmfernandez · Aug 17, 2013 at 06:07 AM · audio clippingaudio priority

Help adjusting Audio script settings to a specific sound

using UnityEngine; using System.Collections; public class PitchChange : MonoBehaviour { public AudioSource Audio; public float StartingPitch = 1.0f; public float EndingPitch = 2.0f; public float PitchUpScaleFactor = 3.0f; public float PitchDownScaleFactor = 2.0f; bool isMousePressed = false; void OnMouseDown() { isMousePressed=true; } void OnMouseUp() { isMousePressed=false; } // Update is called once per frame void Update () { //If mouse is pressed, increase pitch if(isMousePressed == true) { if(Audio.pitch <= StartingPitch) { Audio.Play(); } //Only increase pitch if "EndingPitch" value has not been reached if(Audio.pitch <= EndingPitch) { Audio.pitch += ((Time.deltaTime * StartingPitch) / PitchUpScaleFactor); } } //Otherwise, decrease pitch back to normal, until we reach starting pitch else { if(Audio.pitch > StartingPitch) { Audio.pitch -= ((Time.deltaTime * StartingPitch) / PitchDownScaleFactor); } else { Audio.Stop(); } } Debug.Log(Audio.pitch); } }Below Ive attached a link to a project Ive been working on. The script was created by someone in the community who was really generous to help me come up with something like this. Basically is a PA300/EQ2B Siren Simulator. These are both widely used sirens in the world but Im going for the FDNY PA300 Model however the EQ2B Is an overall general Siren no different sound on any model. The project has a simple button that winds up and winds down a certain audio you put on the audio source itself. Now what Ive been trying to accomplish for the last 6 hours is to get the closest I can to the real sirens by editing the parameters of the script. Now if ANYONE could even try to help achieve the sound and feel Im looking for it would help ALOT. Here are examples of the sirens Im trying to make.

FDNY PA300: http://www.youtube.com/watch?v=rg7tdrS06M8

and an EQ2B (Electronic Q Siren) : http://youtu.be/ntSjxlpI-nI?t=1m40s watch 4:16 for a windup of the siren (This is a minor response so not much siren use)

Now feel free to edit the audio, the script and the parameters to try to get closer. I really need anyones help. Ive been trying for 6 hours and havent been able to come up with anything close. Thank you!

link text

PA300: https://soundcloud.com/user851264436/fdny-pa300-in-action & https://soundcloud.com/user851264436/fdny-eng-309-reported-manhole

EQ: https://soundcloud.com/user851264436/fdny-eq2b

eq2b*pa300.zip (127.0 kB)
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 Sajidfarooq · Aug 17, 2013 at 06:15 AM 0
Share

Rafael, this is UnityAnswers. The format of this forum, unfortunately, is not suited to simply posting a zip file, and expecting a discussion where people try to edit/write/experiment with your code for you. For that, you should post in the Unity Forums.

Here, what you need to do is post code, and ask a very specific question related to that code.

avatar image Sajidfarooq · Aug 17, 2013 at 06:37 AM 0
Share

Thats much better.

Youtube is disable where I am at, so perhaps you can upload the audio of the siren elsewhere?

avatar image rafaelmfernandez · Aug 17, 2013 at 06:56 AM 0
Share

sure If you give me your email I can send you two samples of audio?

avatar image Sajidfarooq · Aug 17, 2013 at 06:57 AM 0
Share

Just share it on Sound Cloud

avatar image rafaelmfernandez · Aug 17, 2013 at 07:04 AM 0
Share

Done check the edit, im uploading another example of the PA300 now and an example of the EQ2b All are up

0 Replies

  • Sort: 

Follow this Question

Answers Answers and Comments

16 People are following this question.

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

Related Questions

Audio Listener not working. 1 Answer

How to change priority of audio clips 2 Answers

Footsteps Sound Effect causing other Audio Clipping or no sound at all. 1 Answer

Play Audio Specific Speakers 0 Answers

Audio Sounds Blurring Together 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