ActionScript 2.0 :: [FMX04] Storing Multiple _x At Runtime?

Jan 11, 2006

i am developing a photogallery with picts of different width.there's nothing with it,but i am trying to make an element which is more of a design nature.So i have an invisible mc/say "bbb" which is duplicated each time a new photo is loaded and its _x depends on the photos _width and the distance between the photo and the end of the screen regulates how many times "bbb" is duplicated.So on every new photo i got /possibly/ diferent number of instances with diferent _x.Still no poblem.But i want to put an bbb_dups.onRollOver=func(){if (this._x=curr_x){ tween(this._x+30)}else if (this._x=curr_x+30){ tween(backto curr._x)} so i need somehow to store each instances curr._x after the duplication which i dont know how.i've tried with an array but it doesn't seem to work for all the instances.

View 3 Replies


Similar Posts:


Actionscript 3.0 :: Storing Lot's Of Data At Runtime?

Oct 11, 2010

I'm now writting a little drawing tool, that will allow users to save their drawings and the redraw them. Now I'm only concerning myself with diferent colored lines with diferent thickness. So now I only need to store the values, that will be used later on when calling the canvas object's graphics.lineTo(....); method. I'm planning to save all of my drawings in XML, but I still need to load them up when I want to use them.

Given my situation, what's the best way to load up my data (after loading it in chunks): Arrays, Dictionaries, anonymous objects. We're talking about loading up, let's say ~ 1000 Point instances for a very simple shape, since I want the drawing to be pixel-perfect, since I will be modifying it to a more sophisticated tool later.

View 4 Replies

ActionScript 3.0 :: Storing The Multiple Swf?

Aug 26, 2010

I have multiple swf files for background . I have to load the entire swf's first and have to store it in array . Is it good to store swf in array or dictionary?

View 9 Replies

Storing Multiple Animation Files?

Aug 19, 2009

I want to have a TV screen and hundreds of (small) flash animations load up in the 'TV'. I'm assuming I'm going to have to use Actionscript, so I'm looking into that right now. However, what would be the best way to organise this? Each "TV" will have a different set of "Channels". Do I create each 'channel' and save them as seperate SWF files, or is it possible to have them all in one main file. I can then flick through each 'channel', which essentially unloads the current animation and loads the next one

View 2 Replies

ActionScript 3.0 :: Storing Multiple BitmapData Instances

Aug 3, 2009

I have a question about optimum resource management. So I am pondering what would be the most efficient way of storing a LARGE number of BitmapData instances in a SWF. The BitmapDatas would be generated at runtime. Only a minority of the BitmapData instances would be on screen at any one time. So far I've conceived three routes; Option one (simply store them in an array - this is then stored in the RAM right?)

ActionScript Code:
var array:Array = new Array();
var bitmapData1:BitmapData = new Bitmapdata();
var bitmapData2:BitmapData = new Bitmapdata();
array.push(bitmapData1);
array.push(bitmapData2);
[Code]...

View 0 Replies

ActionScript 2.0 :: Storing Values In Multiple Loops?

Jun 28, 2008

for (var s = 0; s<mainSections.length; s++) {//grabbing the fabric types Handblocks,Screenprints,and Wovens
for (var i = 0; i<subSection.length; i++) { //grabbing each fabric design of the fabric

[code]....

View 4 Replies

Actionscript 3 :: Storing Multiple Images In A Variable With In Flash Builder 4.5

Dec 6, 2011

I have a flash assignment that. The assignment is to create an application for playing a card game, I have to create an MXML component that has two variables, one variable stores the image of the back of a playing card, the other variable has t store all 52 options of a front facing card (the second variable will store over 50 images).

I've written the variable for the back of the card image like this:

[Code]...

View 1 Replies

ActionScript 3.0 :: Flash Game - Storing High Scores, Winners With Multiple Users?

May 16, 2011

I've been asked if I can build a game, which lots of people will play and the overall winner will get a prize.The game part is simple enough, and I know enough PHP/MySQL to put something together to store the results etc. But is there something already available which could do this part for me, it would save a lot of time, and would probably be better than something I build myself.

View 1 Replies

IDE :: Using Runtime Sharing Of Multiple SWFs?

Nov 1, 2011

I'm currently planning out the UI for a game with a complex UI system. I have done some runtime sharing tests using fonts that are setup for sharing in one fla, and I've setup the import in another. Both files are exported as swc files and are included in the flash develop project (the font is included completely). This worked fine.What I would like to do is have my UI loaded on-demand. I was planning to have a general UI elements library that contains elements setup for sharing (similar to the font), then have separate swfs that are loaded into the main swf when they are needed. These separate swfs would use elements from the shared library. I can get this to work exclusively in the IDE, or exclusively on the server, but not both (making development awkward).

The big stumbling block I'm hitting is to do with setting up the URL paths.I think that all of the runtime paths will be based on the running 'Main' swf location. So all import/export paths need to use paths that work from this root location.for example 'data/ui/top_ui.swf' might import objects from 'ui_elements.swf' (effectively 'data/ui/ui_elements.swf'). This import will function fine when testing from the IDE, but when running on the server, this will fail as it will try to load 'ui_elements.swf' from the root folder. Worse still, it will not fire an error (as it has found 'top_ui.swf' fine) but the load will never complete as it cannot find the runtime swf.

The reason for this folder structure is that we would really prefer to keep our assets in a folder that could in theory be re-located to another server (should the bandwidth usage dictate it). To put these ui swfs in their own folder then causes all the linkage to break in the Flash IDE making editing a kludge. Fix it in the IDE and it will no longer function on load.At the moment it looks like we will just have to export swc files and embed the lot in the main swf to keep this easy for code and art.

View 2 Replies

ActionScript 3.0 :: Loading Multiple Swf's In Runtime And Playing Them One After Other

May 25, 2009

loading multiple swf's as a playlist and playing them one after other on top of the other, so here even we have to play with display list for the visiblity. Tried to load single files but not getting for multiple files, what will be the event with which the dynamically loaded swf switch to other.These file names will be mentioned in XML file.

View 5 Replies

Actionscript 3 :: Merge Multiple Flv Files / Runtime

Mar 22, 2012

I've multiple FLV files, and during run time based on the user's selection i need to combine and merge multiple FLV files into single FLV file and play to the user.so far we are using as playlist with different flv files, but now we need to change the process.Can any one know how can i merge different FLV files during run time and play/download the file in single shot.

View 1 Replies

Professional :: Setting Up Runtime Shared Library URLs With Multiple Environments

Aug 26, 2010

I'm trying to figure out if we can use RSLs to contain common UI controls for our next project.  I'm running into an organizational issue that I can't quite figure out - how to get the RSLs to work in both a local development/debugging environment, and on a production web environment, with the same exporting/importing URLs.
 
Here's what my setup would look like.  Say I have a main application main.swf, an RSL lib.swf, and a UI module dialog.swf.
 
Main.swf loads or embeds dialog.swf.  lib.swf exports some symbols that dialog.swf imports.
 
On a local development environment, these swfs are found in folders like so:

[URL]
 
Here is the problem.  If I set the export/import url for symbols in lib.swf to "assets/lib/lib.swf" (relative to the location of main.swf), the runtime library gets loaded fine in the local environment.  But in the web environment, it does not load - the player just shows the "..." graphic indicating it is trying to load. 
 
Alternatively, I can use "http:/myapp.com/assets/lib/lib.swf" as the export/import url.  Now, it will work in the web environment.  However, in the local environment, dialog.swf will load symbols from the lib.swf that is out on the web, not the one that is local.  But I need it to load from the local version, so that designers can muck about with the assets and see the results locally before publishing to the web.
 
Is there some alternative way to set up the swf's, or way to set the URLs, or some other hoop I can jump through that will make the RSL load properly in either environment without having to manually change URLs all the time?
 
(Details: I am using Flash Builder 4, CS 5, Action Script 3, Flash Player 10... No Flex!  My example omits some details from my actual setup, such as the fact that we are using a preloader to load the main application, and a php script on the web page to start the preloader.)

View 4 Replies

Actionscript 3 :: Share TextArea Component In Multiple SWF - Runtime Share Library?

Jan 12, 2011

How to share TextArea Component in multiple swfsaylib.swf (has TextArea Componenet)main.swf (Import TextArea Componenet from lib.swf)section.swf (Import TextArea Componenet from lib.swf)

View 1 Replies

Load-time Weaving Of Pointcuts Into Existing Binary Code At Runtime With The AVM2 Runtime?

Feb 23, 2010

I've seen the Loom project, but are there any alternatives that are more mature (and actively developed)? I am looking for something that would allow load-time weaving of pointcuts into existing binary code at runtime with the AVM2 runtime.

Has any work been done in this area?

View 3 Replies

Difference Between The Flash Player Runtime And Adobe AIR Runtime?

Nov 16, 2009

I've been into coding for about 5 years now, but I'm a recent convert to Flash development. One of the questions I have at the moment is, considering that SWF files can be run by either Adobe Flash Player OR Adobe AIR, what's the real difference between the two runtime environments? What API's and Objects exist in one environment, but not the other?

Basically what I'm more or less trying to establish is, when would I want to develop an SWF for AIR, and when would I want to develop for Flash Player, considering that Flash Player can also execute locally (providing support for creating "desktop applications")

View 1 Replies

ActionScript 2.0 :: [FMX04] LoadVariables Need To Be Run Twice

Jan 7, 2006

i'm calling a php file, which is supposed to make an xml file. whenever i call the php file using this syntax, most of the time i get "cannot load file" in the xml loading section, but this updates the xml file.

[code] loadVariables("http://localhost/file.php",this,"POST");[/AS]
but when i do it this way. [code] loadVariables("http://localhost/file.php",NONE,"POST");[/AS]

the "cannot load file" messge doesn't get displayed, and the file loads perfectly, but this doesn't update the xml file.

so everytime i have to first use "this" and then "none".

what can i do so that whenever php is called, it'll update the xml file, and still load in the swf.

View 2 Replies

ActionScript 2.0 :: [FMX04]loadVariables Need To Be Run Twice?

Feb 20, 2011

i'm calling a php file, which is supposed to make an xml file. whenever i call the php file using this syntax, most of the time i get "cannot load file" in the xml loading section, but this updates the xml file.[code] loadVariables("http://localhost/file.php",this,"POST");[/AS]but when i do it this way.[code]loadVariables("http://localhost/file.php",NONE,"POST");[/AS]the "cannot load file" messge doesn't get displayed, and the file loads perfectly, but this doesn't update the xml file.so everytime i have to first use "this" and then "none".what am i doing wrong? what can i do so that whenever php is called, it'll update the xml file, and still load in the swf.

View 4 Replies

ActionScript 2.0 :: FMX04: Why Does CSS Work Alone But Not In App

Mar 1, 2005

When I use the code below it works fine and loads the CSS-file and shows the the html-textarea as it should be CSS-formatted. BUT when I try to put the SAME code into a movieclip within another fla-movie it does not work (loads text but not css) and I get un "undefined" all the time. After trying a lot of different things I've come to the conclusion that it MIGHT have soemthing to do with the .onLoad that gets "undefined" in some way. As you can see below I'm getting two vars from input textfields and then use a button to activate the function loadCSS().

[Code]...

View 6 Replies

ActionScript 2.0 :: [FMX04] Swap The Variable?

Apr 19, 2004

Like any of it's simple, but here's what I've got...I'm doing my loadVars, everything's going peachy, but now I want to swap the variable. I've got a bunch of vars in a text file, and here's how I'm doing it right now...

Code:
on (release) {
output1.text = myLoadVar.name2;
}

Now, this works ok, but with as many vars as I'm planning for, I'd like something that I didn't have to make a ton of frames just to have it run.

Code:
on (release) {
output1.text = myLoadVar.(name('prevnum'+1));
}

How do I do this?

View 5 Replies

ActionScript 2.0 :: [FMX04] No Duplication On Firing?

Nov 19, 2005

Im making my first flash game so forgive me if there is anything with my actionscript or my explaining that is messed up.

This game is a 4 player (<--will be) tank game that fires bullets and stuff. so far its working just how i want it to apart from one thing... the duplication for the bullet. This snippet of the script is the bit that should make the bullet firing. if you look at these to bits of script "_root.depth += 1;", "duplicateMovieClip(_root.bullet, "bullet"+depth, depth);" to my understanding the "depth" should increase BUT it doesn't? does anyone know what is going on?

[Code]...

View 12 Replies

ActionScript 2.0 :: [FMX04] Duplicatemovieclip And Path?

Feb 14, 2006

I have following lines inside a function

var u = clips.clip1.getDepth();
clips.clip1.duplicateMovieClip("clip1clone", u-1);

the problem is that clip1clone is not generated. I think it has to do something with path, I have to add somehow a path to clip1clone? I tried 0 instead of u-1 but it didnt work so I guess the problem is with path?

View 3 Replies

ActionScript 2.0 :: [FMX04] As Marquee Effect?

Sep 11, 2006

smooth out this scrolling text script. It works perfect but its not smooth. (keyframes are up at 45fps) I know I can just call the function quicker but it's just not the effect im lookin for. I want a steady smooth look to it.

Code:
iniText = "Hello this is some text.";
mov_cnt=0;[code]....

View 2 Replies

ActionScript 2.0 :: [FMX04] Are Back Buffers Possible

Aug 23, 2007

I'm attempting to create an effect system that will allow for motion blurs and a variety of other effects.My attempt to create this system is by using a series of movie clips that are duplicates of a main movie clip, each a snapshot slightly farther back in time.This doesn't work, as I think I may be lacking some fundemental understanding of how clip duplication works.Below is code that should be creating a duplicate clip, 10 frames behind in time. The clip exists but the sub-clip isn't attached.

Code:
// The main movie clip.
var main_mc : MovieClip;

[code].....

View 3 Replies

ActionScript 2.0 :: [fmx04] Turn Pages Like A Book?

Jan 19, 2004

I was looking over the script from AS.org. for the page flip navigation.[URL]But see the thing with the script from AS.org is that it does not allow you to use images as the pages.

View 3 Replies

ActionScript 2.0 :: FMX04 - Class Files Not Working

Aug 17, 2004

I have two class files that extend to movieclips......one targets _root.scrolling_mc, the other _root.messages_mc. I have multiple movieclips throughout the presentation with instance names scrolling_mc and messages_mc. This is where it gets interesting. After navigating from a scene with scrolling_mc to a scene with messages_mc, some of the behaviour of the scrolling_mc is still triggering. Its almost as if both class files are working side by side.

View 3 Replies

ActionScript 2.0 :: FMX04 - Control Variables In LoadVariablesNum?

Nov 15, 2004

I'd like to know if there is a way of controlling the variables that are sent with the AS command loadVariablesNum when calling an ASP.Let's say I don't want to send two variables that exist in that frame.

View 2 Replies

ActionScript 2.0 :: Customizing FMX04 Components (label)?

Mar 8, 2005

I'm trying to find a clear and concise book or online referece that can assist me in customizing the components that come with FMX04.Namely the label component. I know how to change the "halo" theme in general to get the buttons and text boxes to change color, but beyond that I am at a lost.

I have tried Macromedia, searched here/Flash Kit/google, but nothing that I can learn from. Live Docs has a feedback part where someone posted some code and while I can cut and paste it, I'm not completely sure how it all worked.

View 1 Replies

ActionScript 2.0 :: [FMX04] Make A Navigation System

Jan 16, 2006

I found this navigation system and im trying to figure out how to make it. Not going very well tho, i was wondering if anyone has some hints or a simular tutorial for this. This is the navigation system: [URL]

View 2 Replies

ActionScript 2.0 :: [FMX04] Fading Gallery Function?

Feb 24, 2006

I'm creating flash image galleries for a local design firm's site. Their pages are long, vertically scrolling, with large image galleries spaced down the page (about 900x400px each). Each of these shows an initial image, and then has buttons above to select image 1-9, or pre/next image. The images will need to dissolve from one to the next.Because there are so many of these galleries, I want to put each in a folder, name all of the images Image1.jpg, Image2.jpg, etc. and include a txt file to tell my navigation button how many images are in the gallery (this part works).

OK, but I just can't get the thing going now. Here's how I've approached it:
Each Gallery image is a MC that has an alpha in/out animation, with a stop action in between that also swaps it to a certain level (just so I can identify it using getInstanceAtDepth when I need to fade it out).Image_1 is attached to an empty container on stage at the start. I want to define a function that will be called by my gallery buttons that will 1) tell the clip currently onstage to fade out (that works), 2) attach the appropriate clip to my container clip at a particular level (this does not).

Code:
_global.galleryFader = function(clickVar) {
// "clickVar" is returned when the gallery number buttons are pressed

[code]....

View 1 Replies

ActionScript 2.0 :: [FMX04] Create A Button To Load A Swf?

Mar 16, 2006

I'm now having problems trying to work out how to create a button to load an swf and then go to a frame in the new swf and stop.I've got:

HTML Code:
on (press) {
loadMovieNum ("library.swf",0) ;
gotoAndStop(9);
}

But it doesnt seem to work.

View 1 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved