ActionScript 2.0 :: Processor Speed Detection And Optimization?
May 3, 2005
i have heard that there are ways to detect how fast the processor is or something like that, and then set certain settings or something within flash, that will basically optimize the performance of the movie so that it works better with the computer it is being viewed on...i really dont know how to describe what im trying to find exactly, i was just wondering if anyone had any thoughts on this, or knew where to find more information about this task.basically, i am starting to design stuff that is really intense, and i need to figure out how i can optimize it better.
I have heard that there are ways to detect how fast the processor is or something like that, and then set certain settings or something within flash, that will basically optimize the performance of the movie so that it works better with the computer it is being viewed on. Basically, I am starting to design stuff that is really intense, how I can optimize it better.
I have a script as follows attached to an MC that is pretty processor intensive (well, that is when the MC is duplicated 30 times). I'm looking for some input from people on how to possibly optimize this to cut back on how badly it lags the rest of the movie. My computer is quite powerful but it still shows performance issues with this script:
[AS] onClipEvent(load) { //size of purpleCloud's active area
how to work out the direction of the mouse on stage and say from this:
"if the mouse goes from the left to right (visa-versa) once, add score +1" and "if the mouse speed which is player controlled - slows down - to then display an error graphic"
Is there any as3 based source code that accomplishes pitch detection or beat detection accurately? Doesn't have to be both, if you know of at least one of those,
I want to add an animated .gif file to my movie. So I created a new symbol and then imported the .gif file to the stage. This created the symbol containing the animated .gif.I dragged the symbol onto the scene where I want it. However, the animation seems to play at a different speed (fps) than normal. So I changed the fps of the symbol (at bottom of Timeline where it says "fps"). But for some reason this changes the fps of the rest of the entire movie.
I'm tweening a movieclip from startX to finishX. The value of startX varies but finishX is a constant. But as the startX increases in value the animation appears to be quicker. How do I adjust the speed of the tween to ensure a consistant speed regardless of the value of startX?
I have a movie clip on my scene which has a speed applied to it making it move across the screen. This is duplicated when it reaches the other end of the screen.On my scene I have some action script which is acting as a timer. After a set time I want it to increase the speed of the movie clips, making the game become "harder". I seem to be able to manipulate the alpha of my movie clips but can't seem to trigger the speed increase.If i use a setInterval it seems to trigger the speed increase but it does it each time the movie clip is duplicated (so the delay resets, it does not change once and apply throughout)However, where I am changing the alpha I cannot seem to change the speed.
How can i detect mouse speed with AS 3.0, and then put speed limit? Also can i use speed var for anything else? *sorry for my bad English, i live in non-english-speaking country*
I am trying to get 50 rectangular MC's to scale larger and fade to another color on rollover and rollouts. However, with the code I am using my processor can't handle it after about 8-10 MC's have been rollovered. Can anyone offer a better way to do this? Here is my code:
Not having a movie clip on the stage until needed (attachMovie when it's time, and then kill it as soon as it's temporarily of no use).visible = false^ Is there a difference in processor demand? When setting visible to false, it seems to me that a few extra variables would need to be stored for the movie clip..._x, _y, _width, _height, _alpha, etc., etc., etc...but I wasn't sure how Flash goes about handling these things or which was better practice?
Has anyone found a script in AS2 for a nice snow effect that it doesn't make the computer go crazy with so much processor calculations?I tried almost every script around and makes my website completely crash most systems.my flash file is about 600k with quite a few menus and 930 x 630...so its a bigger res than most
I am trying to get 50 rectangular MC's to scale larger and fade to another color on rollover and rollouts. However, with the code I am using my processor can't handle it after about 8-10 MC's have been rollovered.[code]
i have a swf with several processor intensive subroutines within a main init() routine at start up (about a 5 secs startup wait). it needs a preloader not due to asset loads but to the processor intensive routines.i'm trying to create a preloader that will display progress as the routines complete but when i try to write text to text field as each subroutine completes either the textField.text is not updated or the text field display is not updated after each subroutine finishes.this prevents me from tracking the progress of the start up.
is there a way to force an update to the display list in the middle of a processor intensive routine? i believe flash is supposed to update after each frame but i'm not seeing this.also, the text field i'm displaying *before* this processor intensive routine *does* display when running locally but *does not* display before the routine when running online.not sure why.
I am creating an interactive word prosessor. I would like to be able to format my text (font, size, style, aligning, etc) but I am unsure of the syntax envolved. my code is:
i have a recorded dvr stream, using the dvrcast sample application. of course, i couldn't play it or use it in video post processing tools so i tried the f4v post processor fms tool.unfortunately, both f4v post processor and flvcheck tools throw error and exit immediately
i've got a pretty small (in my opinion) usage of motion tween on the following site: [URL]
the circles are moving around and rotating.. not that big of a deal compared to many much more flash intensive websites that i've seen.
on a few computers i've viewed the website on, this page slows down the rest of the computer, the circles move real choppy, etc so it's very taxing on the computer/processor. making this a less intense flash tween? is it something that i'm overlooking or is what my flash file is doing truly that difficult for a computer/browser to process?
Let's say that I have a line being dynamically generated by an enter frame function (see script below). As long as the movie is playing, the line's width is increasing.
1) At what point (if ever) does its always-incresing width have a negative effect on the processor?
2) Is there any way to test the processor in such a situation to make sure that things aren't undermining performance?[code]...
Note: The Math functions acos, asin, atan, atan2, cos, exp, log, pow, sin, and sqrt may result in slightly different values depending on the algorithms used by the CPU or operating system. Flash runtimes call on the CPU (or operating system if the CPU doesn't support floating point calculations) when performing the calculations for the listed functions, and results have shown slight variations depending upon the CPU or operating system in use.
My web application works with very large and small numbers that I suspect may see a difference depending on which machine is running it (especially with mobile devices whose processors aren't as powerful as desktop machines'). My question is, is this behavior a function of the language?
That is, I assume some languages implement their own algorithms for the above functions, and so may be more consistent (except for differences in round-off errors introduced by the choice of processor/CPU that would exist for all languages).
Anyone know if Javascript has it's own algorithms, or does it outsource them to the CPU/processor like ActionScript?
making a flash game that has a lot of rather complex illustrator graphics. In the game you walk down a street, so all the graphics has to be moved every frame. In some levels where there are a lot of objects in the street the game starts to lag. after importing it to flash and making a mc of it, break it apart to save flash from drawing all the shapes that aren visible anyway?
just uploaded my first flash website..and I'm having difficulty working out how to get google to 'see' it. I've registered the site with google and have a very specific phrase in the <title> tag of the html code but the more I investigate, the more complicated it seems..Can anyone point me towards a step by step tutorial or something to get my site in the top 10 results?
Is there any program or setting for "pointing" flash programs at my graphics card rather than leaving it to the processor and RAM alone? I am running a specific frontend software that is a flash executable- unfortunately it lags heavily on execution despite the fact that I have a very nice video card installed.
I have read all the documentation and more on optimizations. My question is that if you have to resize sfws for different mobiles is it best to have a res thats the biggest mobile and the rest we can use fullscreen. Or is it best to make a smaller swf and have it size up to full screen. Obviously we are not going to create an swf in 20 sizes. By the way, is it MORE processor hogging for a mobile to size down a 800 by 600 standard swf than to downsize an swf thats only a little larger than the mobile screen.
I'm itching to find the most effective way of importing my illustrator vectors into flash but keeping the file size as small as possible. At the moment i'm literally copying my vectors in illustrator and pasting them in Flash, it clearly works but the file sizes seem really high and its hindering the performance of my fla. Is there a more effective way of exporting? or optimizing the imported vectors once they're inside flash?
I have a simple air app that is deployed on a server. All it does is that it makes a httpService request to a webpage every 5 mins. For some reason, it starts out at out at 25MB memory utilization (Task manager), and every day, it adds about 1MB on top of that. I can't figure out why its sucking up memory. I have an eventlistener for the timer in the initialize of the app.I have read a few articles about memory optimization and best practices for air app development. They say you should remove the event listeners after they have fired. But if I do that, the timer will not fire any functions after it fires once.[code]
I have a client that I built a wonderful flashed site for (html page embedd). It isn't getting any attention on google compared to other completely html based sites. How can I tweak this situation for more google searchability?