Advertisement
Braber01

Untitled

Jun 30th, 2011
378
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. /*
  2. [SWF] C:\Users\Owner\Documents\WOFlash\Wheel.swf - 2154538 bytes after decompression
  3. TypeError: Error #1009: Cannot access a property or method of a null object reference.
  4. at Wheel_fla::MainTimeline/init()[Wheel_fla.MainTimeline::frame1:6]
  5. at Wheel_fla::MainTimeline/frame1()[Wheel_fla.MainTimeline::frame1:11]
  6. ---------------------------------------------------------------------------------
  7. Sound Plays but doesn't show Stage
  8. */
  9.  
  10. import flash.media.Sound;
  11.  
  12. var soundClip:Sound;
  13.  
  14. function init():void {
  15.     soundClip.load(new URLRequest(".\\Wheel of Fortune.mp3"));
  16.     soundClip.addEventListener(Event.COMPLETE,soundLoaded);
  17.     soundClip.addEventListener(ProgressEvent.PROGRESS,soundLoading);
  18. }
  19.  
  20. init();
  21.  
  22. function soundLoaded(e:Event):void {
  23.     soundClip.play();
  24. }
  25.  
  26. function soundLoading(e:ProgressEvent) {
  27.     this.txt_load.text = e.bytesLoaded.toString() + " / " + e.bytesTotal.toString();
  28. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement