00:00
00:00
TheElSalvador
Crunt face

Toledo Jackson @TheElSalvador

Age 90

crawdad slingshot

Gumbles School of Horror

Joined on 11/6/07

Level:
21
Exp Points:
4,690 / 4,900
Exp Rank:
10,341
Vote Power:
6.29 votes
Rank:
Portal Security
Global Rank:
24,210
Blams:
215
Saves:
197
B/P Bonus:
8%
Whistle:
Normal
Medals:
392

Fuckity fuck(need as3 help of the .as variety!)

Posted by TheElSalvador - December 13th, 2011


So I built a game using a generic framework with .as files. I can upload the .swf just fine but the mp3 files cannot load. Is there a way I can URLRequest the pages that the songs are on (they're all in the audio portal.)? I have only used local mp3 files thus far so I guess I'm not sure what is possible when loading from a URL.

Basically it looks something like this(focusing on the sounds only)
package{
import flash.media.Sound;
import flash.media.SoundChannel;
import flash.net.URLRequest;

Main{
private var sc:SoundChannel;
}

private function addGameScreen():void {
var gameTune:Sound = new Sound(new URLRequest("gameTune.mp3"));
sc=gameTune.play(0, 99);
blah blah
blah blah
}

Can I do something to the addGameScreen function to make it load from the audio portal or is that beyond the realm of possibility?

(Basic framework of the game just in case it matters):
-Folder containing the following<
myGame.fla
Main.as[framework for the game and music control]
Game.as[bulk of the game's code]
Enemy.as[blah blah]
Bullet.as[blah blah blah]
song1.mp3
song2.mp3
song3.mp3
song4.mp3>

I can post my main.as in it's entirety if it helps resolve this.


Comments

It's gonna take some sorcery on my part but I'm going to try and modify my project so I can upload it to newgrounds.