Show Posts
|
Pages: [1] 2 »
|
Try adding the following lines at the very end of the file. function firstStart():void { playButton.y = 100; pauseButton.y = 0; pauseButton.visible = true; playButton.visible = false; pline.visible = true; ExternalInterface.call("js_playTune", root.loaderInfo.parameters.pid); playTune(root.loaderInfo.parameters.mp3_path); progressTimer.start(); }
firstStart(); This should work unless the code has issues elsewhere. I haven't really thoroughly checked it, but it seemed to be okay, elsewhere, at a quick glance. That made it work. Thank you very much! Sent 1 Bitcoin to the address in your signature.
|
|
|
Well i can not try anything i do not have the class GLPlayer anyway. but you can try to add onPlayClick(null); at the end of the code, it might just work.
No doesn't work. Also when I do that it shrinks the .swf file from 4kb to 1kb and doesn't load at all. Perhaps somebody else here has at least CS4 to have a look at it.
|
|
|
Do you have the actual .mp3 ?[EDIT] didn't saw the .fla... i'll have a look  Do you have a version compatible with flash CS3 ? ( do not have above... ) CS4 is the lowest I can save in  Here's the code, maybe that helps: var timerResolution:int = 200; var glp:GLPlayer; var curPath:String; var playOnce:Boolean = root.loaderInfo.parameters.playOnce;
pauseButton.visible = false;
function playTune(s:String) : void { if (!glp || curPath != s) { glp = new GLPlayer(new URLRequest(s)); curPath = s; } glp.position = 0; if (playOnce) { glp.playOnce(); } else { glp.playLoop(); } }
function pauseTune() : void { if (!glp) return; glp.pause(); }
function getTunePosition() : Number { if (!glp) return 0.0; return glp.position-50; }
function getTuneLength() : Number { if (!glp) return 0.0; return glp.length; }
function isTuneLoaded() : Boolean { if (!glp) return false; return glp.canSeek; }
var pline:Sprite = new Sprite(); var progressTimer:Timer = new Timer(timerResolution); progressTimer.addEventListener(TimerEvent.TIMER, showProgress);
pline.visible = false; addChild(pline);
function drawProgress(cur:Number, total:Number) : void { if (!total || total == 0) return pline.graphics.clear(); pline.graphics.clear(); var max:Number = cur/total*360.0; var rad, cx, cy : Number; var r:Number = 12.5; pline.graphics.lineStyle(0.1, 0x888888); for (var i=0; i<max; i++) { rad = i*Math.PI/180.0; cx = r*Math.sin(rad); cy = r*Math.cos(rad); pline.graphics.drawCircle(cx+15, cy+15, 1); } }
function showProgress(ev:TimerEvent):void { var cpos:Number = getTunePosition(); var totalLen:Number = getTuneLength(); drawProgress(cpos, totalLen); if (playOnce && cpos >= totalLen-timerResolution-100) { setTimeout(function() { onPauseClick(); }, timerResolution+150); } }
function onPlayClick(ev:MouseEvent):void { playButton.y = 100; pauseButton.y = 0; pauseButton.visible = true; playButton.visible = false; pline.visible = true; ExternalInterface.call("js_playTune", root.loaderInfo.parameters.pid); playTune(root.loaderInfo.parameters.mp3_path); progressTimer.start(); }
function onPauseClick(ev:MouseEvent=null):void { pauseButton.y = 100; playButton.y = 0; pauseButton.visible = false; playButton.visible = true; pline.visible = false; progressTimer.stop(); progressTimer.reset(); ExternalInterface.call("js_pauseTune", root.loaderInfo.parameters.pid); pauseTune(); }
function onPauseOver(ev:MouseEvent):void { pline.visible = false; }
function onPauseOut(ev:MouseEvent):void { pline.visible = true; } Security.allowInsecureDomain("*"); Security.allowDomain("*"); ExternalInterface.addCallback("halt", onPauseClick); playButton.addEventListener(MouseEvent.CLICK, onPlayClick); playButton.addEventListener(MouseEvent.MOUSE_OVER, onPauseOver); pauseButton.addEventListener(MouseEvent.MOUSE_OVER, onPauseOver); pauseButton.addEventListener(MouseEvent.MOUSE_OUT, onPauseOut); pauseButton.addEventListener(MouseEvent.CLICK, onPauseClick);
|
|
|
[removed link] uses a small action script that loops mp3's.
the source file is at [removed link] (Adobe Flash CS4)
I want the mp3 to autostart on pageload instead of waiting for the user to click the play button.
It should be fairly simple to do, however, I know nothing about Action Scripts.
Bounty: 1 BTC
Let me know if you need additional info!
|
|
|
I didn't want to spend too much time on this but I liked the challenge. so here's a basic design. modifications are possible. let me know if you think this is interesting to you. 
|
|
|
Man.. guys like you are the reason why I hate the law.
If you don't like a service don't do business with it.
|
|
|
And, such rules are not that easy to pass. They'll need to define what bitcoin is, to explain how it differs from facebook money and the gaming industry money, why people living in democracies can't buy bits with their money, etc. It will be even harder if we put up some fight.
good point
|
|
|
yeah I know this thread hasn't been posted in in 120 days, but fuck it I'll just shoot it up to the top once more  And they said you couldn't eat money....
|
|
|
Tradehill....
you should've never called yourself a hill when the market leader already was a mountain.
I mean...
|
|
|
Is this really the end of the thread?
|
|
|
 I'm selling shares now for $1,000,000USD per share, with a trillion shares available. Is everyone ready to get in on this bleeding edge synergy? That logo will at least get you all the chicks, in spite of all reasonable skepticism, guaranteed!
|
|
|
why the hell would you save the www after all that talk of redoing the internet naming scheme?
bit://enjoy.coke/
makes more sense at that point... because you could already get that domain if you made a top level named coke. Which is where we got all these other top level names from such as .info, .name, .biz
The first part (enjoy) would become the TLD. Registering that would enable you to create urls like ...://enjoy.coke/ ...://enjoy.pepsi/ ...://enjoy.watching.pics.of.my.naked.sister/cherrypie_mayhem.jpg for example  Registering "www" first you could sell as many traditional looking web addresses as you want and thereby adopt the entire web while youre at it...
|
|
|
17. und 18. wären für mich beide in Ordnung.
|
|
|
That's a rather powerful spell to use on something as trivial as that.
Huh? Spell? What do you mean?
|
|
|
Mein HOWTO soll nur eine Möglichkeit aufzeigen wie zwei Privatpersonen schnell und unkompliziert tauschen können.
Die normale Variante über den Client gestaltet sich wegen des Bestätigungsprozesses (und eventueller Blockchain-Updates) gerade bei kleineren Transaktionen nämlich sehr aufwendig.
Aber jeder wie er mag.
Speedy
|
|
|
with the emergence of distributed dns's such as namecoin, could the fundamental logic of domains be redefined alltogether?
could a url be made to look like this?:
protocol://space.subspace1.subspace2.subspace3/folder/file?=POST_DATA
with 'space' being the domain name and the idea of TLD's and country name suffixes dropped entirely?
I'm writing this because I had a science ficticious hallucination last night and a white-bearded guy with a pointed hat and an e-cigar told me the domain name system was gonna be renamed to 'space name system' (SNS) and that those www.'s and dot-something's were gonna be a thing of the past.
I also saw something about desktops disappearing and 3d nodebrowsers...uh never mind
|
|
|
|