STORY   LOOP   FURRY   PORN   GAMES
• C •   SERVICES [?] [R] RND   POPULAR
Archived flashes:
228055
/disc/ · /res/     /show/ · /fap/ · /gg/ · /swf/P0001 · P2560 · P5120

<div style="position:absolute;top:-99px;left:-99px;"><img src="http://swfchan.com:57475/91854506?noj=FRM91854506-26DN" width="1" height="1"></div>

This is the wiki page for Flash #154792
Visit the flash's index page for basic data and a list of seen names.


soundboard.swf
171,2 KiB, 00:00 | [W] [I]

Threads (1):

[VHDRVE3]F http://swfchan.org/5871/
ARCHIVEDDiscovered: 23/7 -2014 17:07:45 Ended: 22/2 -2015 12:23:45Flashes: 1 Posts: 4
/ > /show/ > Thread 5871 Age: 213.78d Health: 1% Posters: 2 Posts: 4 Replies: 2 Files: 1+3
>> Anon 13932 Testing soundboard Trying to make a sound board with flashdevelop. This is the code I used in ActionScript 3: package { import flash.display.Sprite; import flash.events.Event; import flash.display.SimpleButton; import flash.events.MouseEvent; import flash.media.Sound; import flash.net.URLRequest; [Embed(source = "../Sounds/Vocaroo_s0CEsDXdcBuk.mp3")] public class Main extends Sprite { public function Main():void { var goButton:SimpleButton = new SimpleButton(); var myButtonSprite:Sprite = new Sprite(); myButtonSprite.graphics.lineStyle(1, 0x555555); myButtonSprite.graphics.beginFill(0xff00 0,1); myButtonSprite.graphics.drawRect(0,0,200 ,30); myButtonSprite.graphics.endFill(); goButton.overState = goButton.downState = goButton.upState = goButton.hitTestState = myButtonSprite; goButton.addEventListener(MouseEvent.CLI CK, PlaySound); addChild(goButton); } public function PlaySound(event:MouseEvent):void { var mySound:Sound = new Sound(); mySound.load(new URLRequest("../Sounds/Vocaroo_s0CEsDXdcB uk.mp3")); mySound.play(); } } } [IMG] SoundBoard.swf (171.2 KiB) 800x600, Compressed. 1 frame, 30 fps (00:00). Ver10, AS3. Network access: Yes. Text: Bitmaps: Audio: Yes. Video: <METADATA> [find in archive]
>> Anon 13933 Ok it does not work. Ok the problems seems to be that it only works, because I have the sound file. But how do I compile the sound file with the swf file?
>> Anon 13955 >># you make it in flash
>> Anon 13988 I found the problem. I did not use embed the right way: Here is the updated version. package { import flash.display.Sprite; import flash.events.Event; import flash.display.SimpleButton; import flash.events.MouseEvent; import flash.media.Sound; import flash.net.URLRequest; import flash.text.TextField; public class Main extends Sprite { [Embed(source = "../Sounds/f1.mp3")] private const embeddedSound:Class; public function Main():void { //create the button var goButton:SimpleButton = new SimpleButton(); //set the graphics for the button var myButtonSprite:Sprite = new Sprite(); myButtonSprite.graphics.lineStyle(1, 0x555555); myButtonSprite.graphics.beginFill(0xff00 0,1); myButtonSprite.graphics.drawRect(0,0,100 ,20); myButtonSprite.graphics.endFill(); //define the state of the button goButton.overState = goButton.downState = goButton.upState = goButton.hitTestState = myButtonSprite; //Create text for button: var textForButton:TextField = new TextField(); textForButton.text = "hello"; textForButton.x = (myButtonSprite.width - 25)/2 ; textForButton.y = (myButtonSprite.height - 20) /2 ; goButton.addEventListener(MouseEvent.CLI CK, PlaySound); addChild(goButton); myButtonSprite.addChild(textForButton); } public function PlaySound(e:Event) { var soundClip:Sound = new embeddedSound(); soundClip.play(); } } }



http://swfchan.net/31/154792.shtml
Created: 23/7 -2014 17:13:29 Last modified: 24/10 -2018 14:32:34 Server time: 26/04 -2024 00:13:27