Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    Flash








Optimization


My Flash file is only 136K, yet it takes forever to load on the website. I know I need to optimize it. (Obviously I'm a newbie)

Is there a step-by-step rule I can follow to optimize this flash file?

Thanks...




FlashKit > Flash Help > Flash MX
Posted on: 01-19-2004, 04:08 AM


View Complete Forum Thread with Replies

Sponsored Links:

Optimization Help
I am designing my first flash site and I was in need of some tips for optimization (i.e. what to load first and how to do it) Under the bandwith profiler it says my preload is 89.8 seconds. Thanks.

View Replies !    View Related
Optimization
Greetings,

I am building a high school reunion site that requires a lot of pictures. I am having trouble with download times in my flash movies. I have optimized the jpegs as much as they can be without degrading the quality to the point of being ugly. I have divided the movie into about 35 scenes and I have have many more to go. I know there is another way to accomplish my goal, but I am stuck. Are there anysuggestions on loading the jpegs without comprimising quality and/or performance?

View Replies !    View Related
Optimization
What's the best way to go about optimizing my flash movie/website for the web? It has a lot of pictures and some of the pictures were much larger in size than they needed to be so I just scaled them down in flash itself. Should I use photoshop or something to make the pictures smaller in size or something? Or when I publish it, will flash automatically optimize the stuff? Right now when I debug and view streaming, the preloader takes forever because there's 2.4mb to load and I need to make it as small as possible without taking anything off of the site...

View Replies !    View Related
Need Some Help With Optimization
I have a site that I've been working on, someone else designed it and I've built the flash. It's kind of an unorthodox site and seems to be pushing some limitations in Flash - when it runs on my machine at home, it runs OK, but over the web, there is one part of the movie that i have not been able to get to run smooth.

I'd appreciate it a lot if some of the experienced flash developers could take a look and give some advice.

the site is at histrionics.org/index2.php

some notes about the main flash movie that make me wonder if i'm trying to do too much at one time:

1. it's 2880 pixels wide. I think this is the maximum that flash allows

2. there are two mp3s playing (the seagulls, and another that turns on/off when you mouseover the control) and 10 animated, clickable birds, plus a drawing tool, a scrolling marquee, and a filmstrip. all of these elements draw information from text files on the server to know what to play -- the mp3, the pictures to display, the text in the scroller, and the links on the birds.

3. the problem is with the filmstrip, which is the first thing on the left. it runs totally choppy. i've tried simplyfying it and haven't been able to get it to work smooth with all the other stuff going on. plus the marquee is jittery, but i think this is because of the images loading up in the filmstrip. when i take the filmstrip out, the rest of the movie runs smooth.

I've never built a flash movie like this before, so I'm not sure where to draw the line with what is too much for a movie. and, i've been to other flash sites that have had so much going on that they crash my browser, etc. i dont want this site to do that!!

can someone please take a look and let me know if you have any thoughts on how i might optimize it. i'm not looking for input on the design, etc but on the performance.

thanks!

Frizzo

View Replies !    View Related
Optimization
Yeah, so basically i am a newbie with flash, learning trial by error with reference to manuals (probably making it harder than it should be). Anyway, I created a little test movie and have it posted on my site. It runs kind of slow sometimes and is 1.38 MB's. How could i optimize it to run more consistently. Sometimes it runs smooth on loading and sometimes it runs slow or even freezes. The *.FLA is 50 frames consisting of about 40 photos (about 60KB a photo). Check it out and give me some suggestions. When i can get the whole thing flowing smoothly and bring the file size down i want to make this an interactive type of browsing feature.

All criticism is welcome here. Thanx, jeff

www.jeffhalbe.com/loop.htm

View Replies !    View Related
Optimization Help
Hello,

I'm working on a electric beam/lightning animation. It is working quite allright, but I was wondering if anybody would have some ideas for optimization of the drawing.
Here is the code that draws the beam. the movingPoints array is calculated in another method. p1 is the starting point and p2 is the end point.

code:
/**
* Draws this ElectricBeam. It calculates a random position for the points
* between the outer points based on their position.
*/
public function draw():Void {
// Clear the beam.
clip.clear();
// Calculate the random position of each moving point.
var points:Array = new Array();
var nOP:Number = movingPoints.length;
for (var i:Number = 0; i < nOP; i++) {
// Calculate the maximum amplitude for the point according to its position in the beam.
var a:Number = ampl * Math.sin(((i+1)/(nOP+1))*Math.PI);
// Calculate the direction of movement.
//var dir:Number = random(3) - 1;// (up, none or down)
var dir:Number = random(2)*2 - 1;// (up or down)
// Now calculate the how much the point will move (like if the beam was horizontal).
a = dir * Math.random()*a;
// Calculate the position of the point.
var x:Number = Math.round(movingPoints[i].x + (a * Math.sin(-angle)));
var y:Number = Math.round(movingPoints[i].y + (a * Math.cos(angle)));
var p:Point = new Point(x, y);
points.push(p);
}
// Draw the less visible layer.
clip.moveTo(p1.x, p1.y);
clip.lineStyle(10, color, 25);
for (var i:Number = 0; i < nOP; i++) {
clip.lineTo(points[i].x, points[i].y);
}
clip.lineTo(p2.x, p2.y);
// Draw the medium visible layer.
clip.moveTo(p1.x, p1.y);
clip.lineStyle(6, color, 50);
for (var i:Number = 0; i < nOP; i++) {
clip.lineTo(points[i].x, points[i].y);
}
clip.lineTo(p2.x, p2.y);
// Draw the full visible layer.
clip.moveTo(p1.x, p1.y);
clip.lineStyle(2, color, 100);
for (var i:Number = 0; i < nOP; i++) {
clip.lineTo(points[i].x, points[i].y);
}
clip.lineTo(p2.x, p2.y);
}

The main point is that in one method there are 4 for-loops, which becomes quite expensive when there are a lot of points in the beam. I use three different layers of alpha, since it gives a more realistic feel to it.
Is there an effective way of optimizing this bit of code?

Regards,
Jorrit

View Replies !    View Related
Optimization In AS2.0
Hi does anyone know about optimization method in the way you code in AS2.0 ?
if you have tips or tricks that'll make ur script run faster or resources on this, would you like to share it with me or us (hey it's a forum)

thanks guys

View Replies !    View Related
More Optimization Help...
Can someone please help me understand the following? I have a graphic (png) in my movie, I'm doing a basic tween on it that just makes it shrink. The longer, or more frames that this tween lasts, the larger my file size.

Why is this? Flash only needs to load the information from the png once. I can understand if it makes it more processor intensive but why file size?

Any advise on optimizing it for file size?

View Replies !    View Related
Optimization Help
hey,

ive been told theres not much i can do...but i ran my cpu meter on my flash site, and it maxes it out every time i run it. can anyone help me get this thing running smooth?

it doesnt use any vectors other than the menu (vectorized png's) and all other content is png with transparency.

thanks.

~keane

fla: http://www.qream.com/flashmainloader.fla

View Replies !    View Related
Optimization Help?
Hi everyone,

I'm working on a flash movie, but need serious help / advice on optimizing it properly... The main problem is that I'm using transparent .png files in it, and, although they're only a few k each, there are a lot of them!

Also, I'd really like one of the png files to flicker on and off in the background (see link), this looks great, but kills processors...

http://www.mysteriousal.com/newsite/index.html

I have very VERY little experience with actionscript, but I'm sure it could help me here.... any tips?

cheers for reading...

View Replies !    View Related
Optimization
What's up all! I'm an up and coming flash developer and seem to know just enough to get myself in trouble. I have 2 flash sites which take entirely to much time to load. The size of the .swf files aren't too bad, however they are both loading external files ie mp3's (via xml) and images (via java scripting). I need to get these movies loaded a lot faster than they are currently. I've trimmed them as much as i could cutting out frames and duplicate symbols. Any suggestions would be appreciated. The sites are:

www.stldrifters.com and www.elmossdesigns.com

the drifters site is the biggest problem so please take a look and let me know what i can do to optimize these big b@stards! Thanks!

View Replies !    View Related
SWF Optimization
I have a flash site that's approximately 7 mb. Does anybody know of any good methods, tools to optimize the swf file so that the site loads faster.

Much appreciated.

View Replies !    View Related
Optimization Help?
Hi everyone,

I'm working on a flash movie, but need serious help / advice on optimizing it properly... The main problem is that I'm using transparent .png files in it, and, although they're only a few k each, there are a lot of them!

Also, I'd really like one of the png files to flicker on and off in the background (see link), this looks great, but kills processors...

http://www.mysteriousal.com/newsite/index.html

I have very VERY little experience with actionscript, but I'm sure it could help me here.... any tips?

cheers for reading...

View Replies !    View Related
Psp Optimization
recently sony released firmware 2.7 for the psp, this release included a flash player. unfortanately most swf's run like crap. to try to improve this i have been trying to find ways to make the file's run smoother.
I changed to demensions of the stage to those of the psp, decreased the FPS, but it still runs poorly. Any other ideas on optimizing for the psp.
(note that the player supports files up to flas 6)

View Replies !    View Related
Optimization
Im just making things to keep learning new things, and i made a object menu that has potential in my mind at least. I'm attaching the file for those who feel like looking. Two things:

one: If you could, can you show how the actionscript can be optimized/shortened. Or just a better way to do what it does.

two: Stumped on how to have it so that the box in the middle move back to its originial location when another box is clicked on. I was going to use some kind of hitTest with an invisible movieclip to get the name of the box that was in the middle but couldnt figure out have the hitTest function by something along the lines of "If anythings hits this movieclip, save that movieclips name to a variable and perform these actions"

Thanks for prior and future help

View Replies !    View Related
Optimization Help
I am developing the homepage for a site ( dev.silverseal.net/index_main.htm ) which is made up of a shell site which loads 4 external .swfs an external text file. Whenever I have the page open in the browser my memory usage shoots up to 100% and stays there for as long as the flash page is on screen. There is not that much animation (and I've even removed it to test), and I am in the process of streamlining each of the .swfs (the biggest being 19k), but I don't really think that is the issue.

Does anyone have any ideas that I can try (or questions about info that I haven't provided)?

Thanks,
E.

View Replies !    View Related
Optimization Help
Hi everyone,

I'm working on a flash movie, but need serious help / advice on optimizing it properly... The main problem is that I'm using transparent .png files in it, and, although they're only a few k each, there are a lot of them!

Also, I'd really like one of the png files to flicker on and off in the background (see link), this looks great, but kills processors...

http://www.mysteriousal.com/newsite/index.html

I have very VERY little experience with actionscript, but I'm sure it could help me here.... any tips?

cheers for reading...

View Replies !    View Related
Flv Optimization
Hi all,

any one help me for

How i optimize the size of my flv file?????


Thanks in advance

View Replies !    View Related
FLV Optimization
Hey everyone,
I really just need a piece of advice. I am using a swf as an animated background for my web portfolio. Now, the way I had to set it up is, I converted a .mov file to FLV, imported the FLV into the timeline of a swf, and I'm using another swf as a preloader to load the animation onto the page. The preload is pretty small (file size wise), however the swf containing the FLV animation is about 2.5mb (I know that pretty big for web). At this point I'm guess you are asking yourself, "Why the heck would he do that", well, my host does not have a media server that will support steaming flvs and I dont want the movie to be download because of copyright restrictions.

What is really strange about all this is the progress bar rarely displays load pregress. It does sometimes but not other. So the swf just appears and plays once loaded, and it sometimes takes about 30secs to load.

Now, that I feel I have explained myself, My question is, how can I lower this load time without cutting too much quality of the video?

Things you most likely need to know.
My Preloader is similar to the AS3 preloader tutoral on gotoandlearn.
The FLV was compiled with high quality.
The FLV was imported into a seperatate swf as a movie clip and placed on the stage.

No additional code was created

www.jcnewhouse.com/Portfolio.aspx

View Replies !    View Related
Jpeg Optimization
Hi...I was wondering and I have never really figured out a really efficient way to optimize jpegs that I am importing into flash. Can anyone point me in the right direction or reveal any secrets to optimizing jpegs that I want to import to flash? I am looking to reduce as much file size as possible and keep picture clarity, Whether it be thumbnails or larger size pics.

Thanks everyone.

View Replies !    View Related
Code Optimization
I'm A little bit new to Actionscript programming and I am having trouble with code optimization. I have this multiple droptargets that have the same name and the practically the same code structure, that will follow below.

There's gotta be a way of simplifying this humongous amount of lines. The comments inside the code ar explaining my difficult.

Thanks a lot folks.

code:
on (press) {
if (_root.target1.ocupado == true) {
startDrag(this.who_occupies);
this.who_occupies.swapDepths(100);
_root.target1.ocupado = false;
}
}
on (release) {
stopDrag();
this.who_occupies._x = _root.target1._x;
this.who_occupies._y = _root.target1._y;
_root.target1.ocupado = true;
}
on (releaseOutside) {
stopDrag();

// Next line makes this button dissapears

_root.target1.gotoAndStop(1);

// The code bellow is the one that needs optimization

if (eval(this.who_occupies._droptarget) == _root.target1 && _root.target1.ocupado == false) {
this.who_occupies._x = _root.target1._x;
this.who_occupies._y = _root.target1._y;
_root.target1.ocupado = true;
_root.target1.who_occupies = this.who_occupies;
_root.target1.who_brought = this.who_brought;

// the line bellowe makes this button appear
// this button is inside all MovieClips target#
// and the code is pretty much the same in everyone.

_root.target1.gotoAndStop(2);

// Notice now that the code bellow is a exact copy of the code above
// The only difference is the Target Number.
// I wonder if there is a way of writing this just once.
// with some sort of a counter loop.

} else if (eval(this.who_occupies._droptarget) == _root.target2 && _root.target2.ocupado == false) {
this.who_occupies._x = _root.target2._x;
this.who_occupies._y = _root.target2._y;
_root.target2.ocupado = true;
_root.target2.who_occupies = this.who_occupies;
_root.target2.who_brought = this.who_brought;
_root.target2.gotoAndStop(2);
} else if (eval(this.who_occupies._droptarget) == _root.target3 && _root.target3.ocupado == false) {
this.who_occupies._x = _root.target3._x;
this.who_occupies._y = _root.target3._y;
_root.target3.ocupado = true;
_root.target3.who_occupies = this.who_occupies;
_root.target3.who_brought = this.who_brought;
_root.target3.gotoAndStop(2);
} else if (eval(this.who_occupies._droptarget) == _root.target4 && _root.target4.ocupado == false) {
this.who_occupies._x = _root.target4._x;
this.who_occupies._y = _root.target4._y;
_root.target4.ocupado = true;
_root.target4.who_occupies = this.who_occupies;
_root.target4.who_brought = this.who_brought;
_root.target4.gotoAndStop(2);
} else if (eval(this.who_occupies._droptarget) == _root.target5 && _root.target5.ocupado == false) {
this.who_occupies._x = _root.target5._x;
this.who_occupies._y = _root.target5._y;
_root.target5.ocupado = true;
_root.target5.who_occupies = this.who_occupies;
_root.target5.who_brought = this.who_brought;
_root.target5.gotoAndStop(2);

// this makes the MovieClip who_occupies go to its original position
// and the MovieClip who_brought go to its first frame
// that holds a button similar to this one
// that first held the MovieClip who_occupies under a differen name,
// like picture#

} else {
this.who_occupies._x = this.who_occupies.originalX;
this.who_occupies._y = this.who_occupies.originalY;
this.who_brought.gotoAndStop(1);
}
}

View Replies !    View Related
Graphic Optimization?
My games tend to lag horribly. Maybe if I knew a thing or two about optimizing graphics in Flash, my games would run a lot faster. Can anyone help me out? What should I know about graphic optimization in Flash so my games don't lag?

View Replies !    View Related
Vector Art Optimization
I am having trouble making my vector art weigh less in flash. I was using more vector art because I had understood it was obviously lighter than bitmaps. But this simple logo (attached in Freehand, you can import it into flash with no problem) weighs 1106 bytes just in itself. PLEASE someone help me out here!!!


thanks!


Ceci

View Replies !    View Related
Optimization Problems
i neeed my movie to be under 5 megabytes and it is 5.5, i have optimized the audi streamed it all, and optimized all the imaes but it is still large, can anyone help?

View Replies !    View Related
Scrolling Optimization
Hello,
What im doing is what they call "SuperTiles"?
Could this code be optimized any more?

Code:
_root.onEnterFrame = function() {
// RIGHT
if (key.isdown(key.right)&&gor) {
if (player._x>330&& page<=pagelimit) {
player.gotoAndStop(2);
player._xscale = 100;
bg1._x-=15;
bg2._x-=15;
if (bg2._x<0) {
page++;
page1++;
page2++;
bg1.gotoAndStop(page1);
bg2.gotoAndStop(page2);
bg1._x = 0;
bg2._x = 550;
}
} else {
if (player._x<550-player._width) {
player._x+=15;
player.gotoAndStop(2);
player._xscale = 100;
}
}
} else if (key.isdown(key.left)&&gol) {
// LEFT
if (player._x<220 && page>=1) {
player.gotoAndStop(2);
player._xscale = -100;
bg1._x+=15;
bg2._x+=15;
if (bg1._x>0) {
page++;
page1++;
page2++;
bg2.gotoAndStop(page2);
bg1.gotoAndStop(page1);
bg1._x = -540;
bg2._x = 10;
}
} else {
if (player._x>player._width) {
player._x -=15;
player.gotoAndStop(2);
player._xscale = -100;
}
}
} else {
player.gotoAndStop(1);
}
};

View Replies !    View Related
Actionscript Optimization
Hey, I'm just asking, does anyone know where the flash site where it shows a whole lot of different ways to optimize actionscript is?

I remembered seeing it somewhere on here but forgot where it was.

Part of the URL is I think "/speedupflash" or something.

Thanks.

View Replies !    View Related
LoadMovie AND Cpu Optimization
Hi all, I have a main .swf and then I have a button that loads an external .swf (80kb) into a movieclip using loadMovie. After my main movie loads (which is 150kb), the cpu is at around 2 or 3%. This seems accurate since nothing is moving any longer as it's waiting for a button to tell it what to load.

However, when I click a button to load my external file (80kb) and this file has loaded and come to what should be a stop as well, the cpu percentage sits at around 60-70%. My external is only 1 frame, with a stop on that frame and a few different graphics.

Any thoughts/suggestions on why this is? I'm really concentrating on optimization here and can't understand why the cpu is still relatively high(70%) after loading the external .swf stopping everything in this movie at the first frame.

View Replies !    View Related
Optimization For Different Resolution
i have problem with dysplaying images on lower resolution

see Galerie->POS, etc

low res.

the images are not so nice like on default setting like here

high res.

what is the best way to optimize the SWF for lower and higher resolution?

View Replies !    View Related
Flash SWF Optimization?
I have a flash project and it is about 100% complete. My swf file is just under 1mb and I have a preloader, but was wondering if there is a way to optimize the swf file even further so it's smaller in size. Everything in my project is in my ibrary. Other than optimizing vector artwork I'm not sure how to optimize the flash project when it's all done before I ftp it.
Any ideas?
Thanks.

View Replies !    View Related
Optimization Tips
I need some tips on optimizing file size...I have some pretty grungy looking fonts in my movie (read lots of anchor points) is it better to set all the type in PS and make png's out of everything or just type in flash? I really need to keep my file size to it's smallest possible.

Also any other tips for keeping file sizes down?

Thanks.

View Replies !    View Related
Help With Optimization And Preloader
Anyone fancy helping me finish this project??

http://towardsutopia.com/Killahertz/killahertz.htm

It's a whopping 13Mb at the moment - and that's after I've trimmed it down and lowered the resolution as much as possible! Is there any way I can get it to play as it does from my hard disc.

And it also needs a preloader

thanks in advance

Killahertz

View Replies !    View Related
Another Method Of Optimization?
Link
In that it talks about how throwing in random numbers improves programs for some odd reason. Can anyone give an explanation and tell how it could be used?

View Replies !    View Related
Jpg Saturation / Optimization
hi, when you import jpgs into flash you lose color intensity. to rectify this problem i increase color saturation by 25 in photoshop before i import. this helps but the color can still be degraded.

does anyone have any other techniques that help maintain jpg quality when importing into flash?

thanks
mark

View Replies !    View Related
Flash Optimization
hi there people, i know flash compress the files well enough. but i wondering if theres anything else you can do to reduce the size of a flash file.

the reason is ive have desinged a header for this website and only a section of it cotains flash but i created the whole thing in flash.

you can see what i mean by visiting it here http://www.tweedmill.co.uk/updateA/
(its the one where the tag swinging)

any help very much appreciated.

cheers guys

View Replies !    View Related
[F8] HitTest Optimization Q
hey,

Right i'm making a lemmings style game for university (some of you may have seen a demo in the games section)

My lemming will do anything up to... 4 hitTests. banging head, walking into something, checking on a platform1&2.


As you can imagine with 50+ lemmings * 4 = 200 calculations each frame! and at 30 fps = 6000 calculations a second!!!!!!!!!!!! WOW!

I have an idea to cut down this figure - only calculate things you need - eg. when falling only check the feet... etc...

Here's another idea - have the lemming work out the next time it'l hit something or fall off a platform (i was thinking do a for loop at 5 pixels infront and repeat until at the stage end or hit something) then get it to count down how many frames until it needs to check if it hits something again.


So basically when a lemming's walking it checks once when it next will do something, then just repeats whatever it is it's doing until that point when it checks if it needs to do something again. Repeating this process once it's done it.


Anyone else have any other ideas????


Thank you!

-Chris

View Replies !    View Related
Optimization Possibility?
I have a large navigation, which consists of mc's with buttons inside. These buttons of course have the actions onRollover, etc. Everything works great when I rollover everything and does as it should. When I move the mouse a little fast over parts of the navigation, some mc's stick in certain states. Rolling over something else eventually unsticks it. It is kind of like the code to execute can only go so fast as the mouse and sometimes gets left behind. Is there a way to optimize the AS with True statements? or something to prevent these issues? It isn't a huge problem, but a bit annoying and seems a bit sloppy and I just wondered if anybody knows a method in which I can prevent this or get the AS to run smoother.

View Replies !    View Related
Optimization For Firefox And IE
Hey guys, I just started to upload and test a website I am making on the internet and I am having problems... mostly with speed. The framerate drops substantially when playing this in FIREFOX and IE but works great in OPERA. Im just curious if there is a way to run things a bit smoother. Thanks!

View Replies !    View Related
Optimization Issues
Anyone know of a way to optimize Flash sites like mine for Google? Some people say that adding Meta tags helps, while others claim that they don't.

Since I'm just a freelance Flash designer, I don't have the budget for large-scale advertising, and I can't get ranked for my all Flash site... HELP!

Thanks,
Brian
www.BirdInTheCity.com

View Replies !    View Related
Optimization Techniques
Hi!

I´m doing a research on RIA´s optimization techniques and I plan to implement such in my app´s next version as its getting bigger and bigger so it became a necessity to optimize it.

Currently, I´m using shared fonts, shared symbols and shared classes (the so called "dll" swf) that are all loaded once in the application lifetime, avoiding the download redundancy and optimizing the size of the subsequent swfs. However, my application is still not fast as I would like it to be, the main reason is obvious, it uses too many classes (and v2 framework adds a great deal to the class inventory). The second reason is becouse of the nature of my app: Its an online picture album. The images are stored in 1MP at the server and each time the client requests the image, its converted (scaled down) at runtime using GD. It´s very flexible as I can make many different size images without worring about saving them, however, and I would like the oppinion of more experienced web developers, I think it would bring me problems when my site gets a very high trafic AND it is slower than if I would just load the image without pre-processing it (already saved in the disk. Currently, only the 1MP "source" image is stored, the other "flavors" are generated at runtime using GD).

Also, I´ve not implemented controls such as to prevent the client to redownload the picture if it is already downloaded - how could I do that? Something that came into my mind is to use SharedObjects to cache data and some logic to implement such thing.

You can view a beta of the app here: http://www.chapeco-online.com.br/website/

Some of the client and server code has been based on Sephiroth´s ImageGallery3 (www.sephiroth.it).

Any suggestions would be very much appreaciated!

Thanks,

- Marcelo.

View Replies !    View Related
Site Optimization In MX
Hi guys,

Can anyone help me with some advice about optimizng a Flash web site, created in MX?

Thanks.

View Replies !    View Related
Basic Optimization
I've been developing flash games for a while but I've always wondered the answers to these 2 following questions, and I hope someone will be able to answer them as they're fairly basic:

Case:
Imagine I have a box, and inside that box there are lots of Circles (100 or so). I have a seperate "Player" movieclip coming towards the Box and Circles which needs to check for collisions.

I've always assumed this cannot be done easily without checking every enter frame. There are 2 primary ways of detecting those collisions:

I could put a loop in the Player class to cycle through every single Circle checking whether or not it is colliding with the Player.
OR
I could put a single statement block in each Circle class, checking whether or not it hits the Player.

Question 1:
Is there actually much of an efficiency difference between each method? Or are they more or less the same?

Question 2:
If I was to make an if statement which first checked to see whether the player was within the Box boundaries, and only then ran the rest of the function to check for collisions, would that improve efficiency at times when the player wasn't in the box?

Thankyou for any help or information you can give.

View Replies !    View Related
Any Advice On AS3 Optimization.
Hey I'm working on a big project that visually represents a database.

so lots of calls to database with json and lots of classes with graphics and text being added and removed on screen.

what do i need to learn about Optimization?

View Replies !    View Related
Optimization Techniques
I've been doing work for intranets forever, now I'm doing some stuff for the web, what are the best techniques to shrink my movie size?

View Replies !    View Related
Fla Memory Optimization
Hi!
not excatly a AS related problem, but maybe it can be solved by using it.
here is the main fla content:
-embedded bmp (originally PNG) sequences 10objets*30frames (1sequence size ~200KB)
-12fps (if it matters)

problem: running out of memory (flash CS3,8 crashes when reaching memory usage of 2.6GB), to edit swf it takes about 1.5G of RAM and when running swf it takes ~300MB

how to optimize this? the swf itself takes not more than 10MB of diskspace, fla not more than 20MB;

my pc's RAM - 3GB

View Replies !    View Related
Optimization Software
Hi all, I found, okay I read about a software called Optimaze. Itis a software to apparently optimize and shrink the file size of your SWF files.
Has anyone else heard about this or anyting like it, or have I just completely gone over the edge on this one.

View Replies !    View Related
Optimization, Need Some Ideas Please.
I built a quite large flash application. There are several full programs within the main application and i cannot load independent swf files (for security, it will be installed on the user's machine and is executed via flash studio pro). So each page was converted to a compiled movieclip and each clip is on the stage, just made visible/invisible as needed.

The problem is, having all these fully running applications on the stage (visible or not) slows down performance as the application is being initially loaded.

I experimented with attaching the clips to the stage as needed, but this requires exporting the compiled clips in the first frame, which causes plenty of other problems. (fonts and other stuff).

I am also trying to come up with a way to structure the execution of my program (so its not all running on one frame and at the same time), I don't really have much experience with this.. so if somebody could give me some ideas/pointers.. that would be great.

My Email is info@digisoftstudios.com

View Replies !    View Related
Site Optimization
I am in the process of creating a site and I was wondering when one should use runtime bitmap caching. I heard one should use it when moving a static image around, or in a movie clip where there is alot of movement, yet these two ideas seem to be opposite of one another. Can anyone clear up what the 'rules' for runtime bit map caching are?

Also, does anyone have some good tips for cutting down size in general?

Thanks!

View Replies !    View Related
Help In Code Optimization?
Hi there.
Almost embarrassing question, but it will help me with make my code MUCH more efficient.
I am a newbie, but writing a pretty complex piece in which the code repeats itself many times with a minor change.
Basically at this part I am telling many different Movie Clips to pop up in different X and Y's.
I know my code (see example attached) is the long way to do it.
The 2 paragraphs below are repeating 12(!) more times in my code and they are exactly the same (but the X and Y's)
I am hoping to find a way to concise the 14 blocks of code (2 here on the example) to one block with +1, and for the different X and Y's add an if statement for each different situation.
but i am heaving trouble executing it.

Any thought?
Will appreciate any help!
Thanks










Attach Code

/-------------------------------------------------/*/Make MC 1 (out of 14)
function makeTile1s() {
var TileFHolders:Array;
TileFHolders = new Array();

Tile1Holder = _root.createEmptyMovieClip("Tile1Holder", this.getNextHighestDepth());

for (var i = 0; i<1; i++) {
var Tile1:MovieClip = TileFHolder.attachMovie("Tile1", "Tile1_"+i, Tile1Holder.getNextHighestDepth());
Tile1Array[i] = Tile1;
Tile1._x = 114 //FIX
Tile1._y = 69
Tile1.pop = pop;

};
}
//-------------------------------------------------/*/Make MC 2 (out of 14)
function makeTile2s() {
var Tile2Holders:Array;
Tile2Holders = new Array();

Tile2Holder = _root.createEmptyMovieClip("Tile2Holder", this.getNextHighestDepth());

for (var i = 0; i<1; i++) {
var Tile2:MovieClip = Tile2Holder.attachMovie("Tile2", "Tile2_"+i, Tile2Holder.getNextHighestDepth());
Tile2Array[i] = Tile2;
Tile2._x = 185
Tile2._y = 69
Tile2.pop = pop;

};
}

























Edited: 03/20/2007 at 05:04:10 PM by adamlewen

View Replies !    View Related
LoadMovie Optimization...
First time on this forum, have a question that I hope someone can help me with.

I have a site that I am building that is utilizing the LoadMovie command extensively. What I am finding is that some of the swf's that I am loading at different intervals are a little bigger (ie 400k, more graphics).

My question is, is there a way to pre-load all of the swf's and then only call them when needed, thereby only having to create one actual pre-loader at the beginning?? I have seen other sites that use pre-loaders all throughout the site, such as to load sounds, graphics, etc. I am using different swf's on different levels as well as using hte unloadMovie command.

I hope this question is not too confusing.

Thank you in advance you any help, or pointing me to any tutorials that may offer some insight.

View Replies !    View Related
Optimization For Flash
I was wondering. . .
Do you guys have any tips for making a flash movie run more smoothly on pretty much any machine (within the standard range). I know when I built a flash site it ran like crap on computers other than mine, but other flash sites that are far more complex run smoothy on just about any machine that I run it on. For instance sixtailer.com. Is it a difference of animating things in frames or making something move or animate using complex action scripting? I figure there is NO difference as the computer still has to render the effects just the same. However I could be wrong. So my question is, is there a way of optimizing flash so it runs really smoothly?

Does it have to do with animating using actionscript vs frames?

Does it have to do with the way a flash file is published?

Answers to these questions plus any tips that you could give me would be a of great help to me and possibly many others who are wondering about this same general concept.

Thanks a lot!

Cheers

View Replies !    View Related
Optimization Of AS2.0 Tips
Does anyone have any tips on how to optimize Actionscript 2.0 coding ?

I am aware that the flash 7 compiler does things a little differently than mx , so what are the specific optimisation tricks for AS2.0 ?

thanks,
steve

View Replies !    View Related
Copyright © 2005-08 www.BigResource.com, All rights reserved