all groups > macromedia flash sitedesign > october 2004 >
You're in the

macromedia flash sitedesign

group:

Cloud effect gone array



Cloud effect gone array ekora
10/5/2004 11:33:07 PM
macromedia flash sitedesign: Need some help with something. I made a cloud effect on a site I'm
designing...but it seems to shift the fps to aroun5.0 when I have it set to
24.0....I tried doign a motion tween at first, that's when I first noticed how
sluggish it was...then I used the following script that I found:

onClipEvent (enterFrame) {this._x = this._x-1;}
onClipEvent (enterFrame) {this._x -= 1; if (this._x<=-600) {this._x = 0;} }

I really need to make this look super smooth. Any suggestions would be
greatly appreciated.

Here is the test site for the file:
http://www.ekorastudios.com/tests/tusseymountain/
Re: Cloud effect gone array Pete Hughes
10/6/2004 1:28:41 PM
Re: Cloud effect gone array ekora
10/6/2004 1:36:14 PM
Too large? The entire site is only 300k.

Re: Cloud effect gone array Pete Hughes
10/6/2004 5:47:06 PM
Re: Cloud effect gone array tralfaz
10/6/2004 10:37:00 PM
I took a look at your file. That link you posted is to your motion tween
version. Your actionscripted one should be a much smaller file.

Suggestions..
You can save CPU power by using setInterval instead of onEnterFrame so that
you can process different things at different rates. For instance, you are
updating a timeclock 24 times per second. Once per second is better, but it
looks like you don't display the time anyway, so why load the CPU with that
process?

The actionscript you listed has two onEnterFrames that do the same thing.
You only need the 2nd one (but I suggest you use setInterval instead anyway)

Moving large bitmaps is very cpu demanding. Since your clouds aren't
photo-realistic looking anyway, you would get better performance drawing the
clouds as vector drawings in Flash instead of using bitmaps. Even if you
get the clouds to move smoothly on your computer, check it also with a
slower computer. You may want to reduce the effect to a smaller area after
you see how jumpy it is on the slower machines.
I hope these suggestions will be helpful.

Good luck,
tralfaz

[quoted text, click to view]

Re: Cloud effect gone array Bill
10/7/2004 8:43:05 PM
Me too... Sorry dude


[quoted text, click to view]

Re: Cloud effect gone array ekora
10/11/2004 4:39:02 AM
Okey dokey...thanks for the input.

I will definitely look into using setInterval...and possibly recreating these images as vectors.

AddThis Social Bookmark Button