I am having an issue with compiling a .swf. I get the following error on what seems to be related to the images. There is about 40 that are all very similar the the error code listed below:
5000: The class 'com.decalmywall.Emb_EMB_BORDER' must subclass 'flash.display.BitmapData' since it is linked to a library symbol of that type.
I am having an issue with using BitmapData.draw(stage). I am getting the following error:
SecurityError: Error #2123: Security sandbox violation: BitmapData.draw: file:///C|/Documents%20and%20Settings/bla...bla...bla.swf cannot access null. No policy files granted access. Here is a portion of my code:
var bd:BitmapData = new BitmapData(2800, 2100); bd.draw(stage);//this is where the error happens All of the files referenced (.xml/.jpg/.swf) are located in the same local folder as the main .swf. How do I get around this error? The main objective is to print the stage using PrintJob(). I am using Flash Professional CS5.5 and publishing to Flash 10.0/10.1. Let me know if I need to supply any more info.
- I have a player.as with code to control playback of videos - I have a skin.as with code to control and organise skin components - The skin.as file loads a "shared library" (quotes as I don't think I'm doing this correctly) which is essentially a swf file with nothing on the stage. It's library contains things like: play buttons, scrub bars etc. all these assets have associated, linked class files to add functionality.
1. Load the containing swfs 2. Create new instances of the linked classes 3. Add them to the stage to be used.
However, there is an issue preventing me from using the linked assets in this way - I can't use the linked assets unless- - I add something to the stage of the "shared library" swf - I then do something like skinSwf.addChild(libraryFile) What I want to do is just use the linked assets, not have to deal with any other parts of the "shared library" file.
I'm trying to link a clip to a class, and it goes well until I try to access MovieClips or TextFields placed on the stage within that clip from code in the class. My code is below; there is a TextField called output_txt on the stage within this clip.
class Main extends MovieClip{ public function Main() { //trace("123"); <--if I replace the line below with this, it traces nicely output_txt.text = "123"; stop(); } }
How can find out the linked url of the image in the flash of a website? I looked for the image url some time. but couldn't find itif find the linked url of the image, and i want to alter an image linked url address. where is the code in?
i've been all afternoon trying to figure out a solution to my problem, and I can't seem to find it, or cannot implement it. Let me lay it out for you: I have an actionscript file linked to a movieclip. (movieclip:skate class linked: generic_skate).I have it set up that way so I can create an array of skates easily (i'm using a for loop to create them), and each skate has its own attributes (name, description, price and the image that is supposed to go on the deck)In the stage, i have three text boxes, one for the price, other for the name, and another one for the description.In the generic_skate class, I'm handling all the mouse events (in this case mouseOver and mouseOut.
What i want to accomplish is: when the user hovers over a skate, the info shows up in the text fields and when he hovers out, the info goes away. My problem: Since I'm doing all the mouse interaction in the class file, my guess is that I have to access the stage to get to the text boxes that are placed there to change its info or somehow create a "middle" man to do all the handling.
On the mxmlc command line, I can include paths to RSL files. I can choose to link these RSLs at runtime by setting
-static-link-runtime-shared-libraries=false What if I need to link to some rsls and embed (static-link) other rsls? Is there a way to set the link settings for each rsl?
I'm working on a project that requires more than a simple hitTest. Bitmap collision seems the best way to go. My end goal is to be able to determine which side a rectangle was hit: top, right, down or left. If there is a way to do this with a simple hitTest I'd love to hear about it. The problem I'm running into while following the Flash Example with bitmap.hitTest is that as soon as I apply BitmapData to an mc that already exists on stage the collision detection stops working. I am wondering if this is an inherent issue and I have to rely on creating the movieclips via script then attaching BitmapData.
The Flash example is as follows, this code works correctly: ActionScript Code: import flash.display.BitmapData; import flash.geom.Point; var myBitmapData:BitmapData = new BitmapData(100, 80, false, 0x00CCCCCC); var mc_1:MovieClip = this.createEmptyMovieClip("mc", this.getNextHighestDepth()); mc_1.attachBitmap(myBitmapData, this.getNextHighestDepth()); [Code] .....
What i want to do is get a png from my library load it into bitmapData then into bitmap then onto the stage.I don't even have enough success here yet to have code to post. Please for the LOVE of Mike!
I am copying a bunch of shapes from my stage to a set of bitmaps for filtering.
Is there a faster way to do this? Is there a way to copy everything over together from the stage rather than how I'm doing it by copying the shapes in my array one by one?[code]...
When I publish the file, I'm getting the following error message in the Output panel:
**Error** Scene=Scene 1, layer=Layer 2, frame=1:Line 7: The class or interface 'BitmapData.loadBitmap' could not be loaded. var plaid:BitmapData.loadBitmap("plaid");
I am trying to use the reflect class from "http://pixelfumes.blogspot.com/2007/03/reflection-class-v3-with-source .html" but I keep getting this error:
ArgumentError: Error #2015: Invalid BitmapData. at flash.display::BitmapData() at Reflect() at Site_fla::GalleryPage_29/loadThumbs() at Site_fla::GalleryPage_29/sortXML()
[Code]...
btw, first I used assigned thumbContainer as the mc argument (outside the loadThumbs() function) and it worked but not exactly what I wanted... because I thought it is supposed to update when the movieclip is animated but it actually didn't... when I use a scroller, only the thumbs that are first loaded to the stage get the reflection..
I've been using BitmapData.copyPixels() to draw graphics onto a canvas (Bitmap).I need to rotate the resulting graphics without the use of draw() because it's vastly slower.How can I rotate the target graphic? I'm assuming that there might be a formula or library that I can use which will first reorganize the pixels that make up a graphic based on an origin (point) and radians.I'm pretty certain that I'm not capable of creating such logic, so if there are any known libraries that do this, that would be awesome.I'd like to achieve something similar to XNA's SpriteBatch.Draw() method, which accepts rotation as its 5th argument.
how to use the bitmapData collision method. Now I'm trying to figure out if there is a way to see at what angle or coordinate of the bitmapData the collision happens? I need it in order to figure the accurate bounce angle after the collision occurs.
I'm currently working on a flash game and I need to know how to addChild a BitmapData or draw a BitmapData to screen. If I can't than how can I give a DisplayObject my BitmapData?
I've made a mobile version of my software, with low-res images and such, and I can now fully buffer all my content (including a 360 frame animation which is buffered to memory). Problem is, that everytime I update the view, more memory is used.When I write image = new BitmapData();, does it store the previously created BitmapData's in memory? Do I have to flush the memory somehow before I draw my second picture in BitmapData?Example:
ActionScript Code: // In this example I draw using the same bitmapData several times, also //overwriting the first image. Do I have to somehow delete the data first, to
I am using the draw() method of the BitmapData to encode a jpeg of part of the image. Now this should be easy enough given the object I want to draw to the bitmap is on the stage at design time so I know its location and dimetions exactly! Heres the code I have in place.
Code: var myBitmapSource:BitmapData = new BitmapData ( street.width, street.height, false, 0x333333); myBitmapSource.draw(street, null, null, null, new Rectangle( 96, 5, 571, 450 ), true );
I know for a FACT that no part of the street clip I am drawing out is in negative space, and it's registration is (0,0). However, it cuts off A lot of the top of my image. y=5 in the above rectangle is where I need the top to be, but it cuts the top off of the image... even if I change it to 0, it has no effect.
The title might be a little misleading. Look at my code and I will explain
public static function loadTile(tileDir:String = "empty"):void { if(tileDir != "empty") { tPoint = new Point(0,0); tRect = new Rectangle(0,0,30,30);
[Code]...
I am trying to do tiling with sprites. I want my tiles to be interactive, so that is why I am using the sprite object instead of using regular bitMaps to represent my tiles. You might be wondering why I wouldnt just use graphics.beginBitmapFill(tImage); and graphics.drawRect(0, 0,tWidth ,tHeight ); to pick out the tiles I want to use. Well reason being is because it turns out that drawRect() first and second parameters actually alter the location of where the actual sprite sits at.
So if I set the x and y properties of the sprite to x = 20, and y = 20. then I set my drawRect(20,20). it actually adds an extra 20 pixels to my x and y coords of my sprite. And I know the reason why, I just need to know a better way.
Whenever I add a new layer, it seems to be linked to my 1st layer.If I delete something on the stage on the new layer, it's also deleted from the 1st layer. If I try locking the 1st layer, anything on the new layer-although not locked itself -can't be selected.
I am currently making a website in flash for a football team and i would like to make a list of all the players names which link to separate player profiles in the same flash document.
I am using the loader class to load an external swf and attach it to an empty movieclip, the final step follows: // function loadComplete(e:Event):void { mc_launch.addChild(gLoader); MovieClip(gLoader.content).gotoAndPlay("start");}
When navigating away from the movie clip, it's dumped as follows: MovieClip(gLoader.content).closeAllStreams();gLoader.unload();
The linked swf has two important frames in the beginning. The first frame is labeled "hold" and has the following: var gSC:SoundChannel = new SoundChannel(); var gSCBusy:Boolean = false;var gSlideIndex:Number = 0; var gAudioPosition:Number = 0; var gPlayList:Array = ["start","slide01","slide02"] var gAudioList:Array = ["intro.mp3","",""] var gRunMode:String = Capabilities.playerType;stop();
The fifth frame is labled "start" and the singing and dancing begins from there. The stop(); function in the first frame is used to prevent the loading swf from executing before its 100% downloaded (I had some early trouble where the music would start before the screen assets were in place). My problem: This works perfectly the first time the linked swf is downloaded and attached, however, if you navigate away and then back I get the error "gSlideIndex NAN" which indicates to me that the first frame in the linked swf is not executed on subsequent attachments, the playhead jumps straight to "start" and my globals are never declared. Why would a linked swf execute frame 1 the first time it's attached to mc_launch but not the second?
Sounds simple enough. I have a number of swfs (quiz01.swf, quiz02.swf.....) all linked to one quiz.as file. The quizes in turn are loaded by another swf, Main.swf. I need to get the name of the specific quiz that is loaded, so I can identify an external xml file.
Tried using the "loaderURL" in the as, but it gives the name of the Main.swf. How can I just get the name of the swf that is associated with the quiz.as file?
I have an external .flv and I simply need to be able to pause it with a frame action and start it back up with another frame action.I found some references to "flvStream.play" through google but I haven't been able to properly implement it.
I've got an FLV video linked to an external SWF (a substage) that is itself linked to another SWF (the main stage) The FLV plays fine if I publish and run the substage independently but when the substage is loaded into the main stage at runtime I lose the video, all the other screen elements from the substage work fine. I thought it might be a path issue so I hardcoded a fully qualified URL as the video source with the same results; works independently, fails when loaded into the main stage at run time.
I am using linked TLFTextField in flash cs5 and want to access the text of a particular TLFTextField within the chain. Is there a way to access the text in a TLFtextField within a chain
currently using flex builder 3. I am having trouble setting up linked folders between 2 of my projects.Basically I have a project for a Map Editor, and a project for the Tile Game. I want to share the map folder between the two projects but I keep getting package errors and I don't know how I should nest the folders/projects or where to put the maps or how to import classes from these linked folders.The project folders are currently arranged like this....Flex/Game...Flex/MapEditora maps folder needs to be shared between the two projects
I have one scene linked to another through a button, when I click on the button that links to scene two it takes me to the scene but doesn't play the animation it just shows the non animated components. Is there something really obvious I am missing here because if I go to the scene (when I am not testing the movie) the animation works perfectly.