Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

Coding Forum


You are currently viewing our Coding Forum as a guest. Please register to participate.
Login



Reply
Actionscript 2 - sound problem
Old 03-31-2008, 07:37 PM Actionscript 2 - sound problem
shivaji's Avatar
Ultra Talker

Posts: 318
Trades: 0
I am create Flash menu. This menu have atached on each button simple sound lenght 1.08 seconds. The pages are very light and when I click on button only half or less sound is comming out before I get new page. This stop my sound. I am not very good in AS and I don't know how to play full sound track and then start to load a new page. I was try some functions from Internet but without result. Any help is welcome.

Here is my AS:

Code:
on(release) { 
clickSound = new Sound(); 
clickSound.attachSound("CLICK"); 
clickSound.start(); 
getURL("o_nama.php", "_self"); 
}

Shivaji
__________________

Please login or register to view this content. Registration is FREE
- uncommon free scripts

Please login or register to view this content. Registration is FREE
- Städte, Sport, Party, Gourment, Apartments, Hotels
shivaji is offline
Reply With Quote
View Public Profile Visit shivaji's homepage!
 
 
Register now for full access!
Old 03-31-2008, 07:57 PM Re: Actionscript 2 - sound problem
vectorialpx's Avatar
Extreme Talker

Posts: 241
Name: octavian
Location: Bucharest
Trades: 0
you play the sound and redirect why?
trie to add the sound at the up button frame... is more simple
__________________
you can
Please login or register to view this content. Registration is FREE
vectorialpx is offline
Reply With Quote
View Public Profile Visit vectorialpx's homepage!
 
Old 03-31-2008, 08:15 PM Re: Actionscript 2 - sound problem
shivaji's Avatar
Ultra Talker

Posts: 318
Trades: 0
Quote:
you play the sound and redirect why?
This is photographer store and sound is cameara click. The sound is not playing all time. I would like to play sound when button is pressed down and then start to redirect on right page.
__________________

Please login or register to view this content. Registration is FREE
- uncommon free scripts

Please login or register to view this content. Registration is FREE
- Städte, Sport, Party, Gourment, Apartments, Hotels
shivaji is offline
Reply With Quote
View Public Profile Visit shivaji's homepage!
 
Old 04-01-2008, 06:44 AM Re: Actionscript 2 - sound problem
vectorialpx's Avatar
Extreme Talker

Posts: 241
Name: octavian
Location: Bucharest
Trades: 0
you can make 2 buttons: with and without sound on UP..
anyway... in the actionscript


// on the frame:
sunet = new Sound();
sunet.loadSound('external_sound.mp3');
// it loads with the page

// on the button
on (press) {
sunet.start();
}
on(release){
do_something else... redirect or else
}
__________________
you can
Please login or register to view this content. Registration is FREE
vectorialpx is offline
Reply With Quote
View Public Profile Visit vectorialpx's homepage!
 
Old 04-01-2008, 07:19 AM Re: Actionscript 2 - sound problem
shivaji's Avatar
Ultra Talker

Posts: 318
Trades: 0
Thanks, I will try ASAP.
__________________

Please login or register to view this content. Registration is FREE
- uncommon free scripts

Please login or register to view this content. Registration is FREE
- Städte, Sport, Party, Gourment, Apartments, Hotels
shivaji is offline
Reply With Quote
View Public Profile Visit shivaji's homepage!
 
Old 04-01-2008, 07:51 AM Re: Actionscript 2 - sound problem
shivaji's Avatar
Ultra Talker

Posts: 318
Trades: 0
Ahhhh, it is not work. Again I got page before sound finish. I need some type of delay but I don't know how to.
__________________

Please login or register to view this content. Registration is FREE
- uncommon free scripts

Please login or register to view this content. Registration is FREE
- Städte, Sport, Party, Gourment, Apartments, Hotels
shivaji is offline
Reply With Quote
View Public Profile Visit shivaji's homepage!
 
Old 04-01-2008, 11:40 AM Re: Actionscript 2 - sound problem
vectorialpx's Avatar
Extreme Talker

Posts: 241
Name: octavian
Location: Bucharest
Trades: 0
aa... you need the sound to be finished

on (release) {
sunet.start();
sunet.onSoundComplete = function() {
getURL('or_what_ever');
}
}
__________________
you can
Please login or register to view this content. Registration is FREE
vectorialpx is offline
Reply With Quote
View Public Profile Visit vectorialpx's homepage!
 
Old 04-01-2008, 01:35 PM Re: Actionscript 2 - sound problem
shivaji's Avatar
Ultra Talker

Posts: 318
Trades: 0
Thanks a lot vectorialpx, I got it! It is not working with
sunet.loadSound('external_sound.mp3');
but I am include your function in my script. What the best, yesterday I am try the same think but it is not work because I didn't close and reopen window. I am just refresh and this is reason why is not work properly. Small mistake big problem. Thanks again.
__________________

Please login or register to view this content. Registration is FREE
- uncommon free scripts

Please login or register to view this content. Registration is FREE
- Städte, Sport, Party, Gourment, Apartments, Hotels
shivaji is offline
Reply With Quote
View Public Profile Visit shivaji's homepage!
 
Reply     « Reply to Actionscript 2 - sound problem
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.28213 seconds with 12 queries