Page 1 of 1

flash

Posted: Tue Feb 13, 2007 2:14 pm
by techker
feyd | Please use

Code: Select all

,

Code: Select all

and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read:  [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]


any body here good in action scripts?


hey guys i was watching a video tutorial on how to make a loader

(when a page loads)
but the image of his action script is fuzzy or juste wrong..

i get error on this



[syntax="actionscript"]stop() ;
mask_mc._height = 1;
this.onEnterFrame = function():void (
    var loadedData:Number = this.getBytesLoaded();
    var allData:Number = this.getBytesTotal();
    var percent:Number = Math.round(loadedData/allData*100);
    mask_mc._yscale = percent;
    if (loadedData>=allData) {
         gotoAndStop(10);
         delete this.onEnterFrame;
    }
);

Edit/Delete Message


feyd | Please use[/syntax]

Code: Select all

,

Code: Select all

and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read:  [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]

[quote="[url=http://forums.devnetwork.net/viewtopic.php?t=30037]Forum Rules[/url] Section 1.1"][b]1.[/b] Select the correct board for your query. Take some time to read the guidelines in the sticky topic.[/quote]

Posted: Tue Feb 13, 2007 2:16 pm
by daedalus__
This belongs under Miscellaneous.

Posted: Tue Feb 13, 2007 3:00 pm
by jyhm
You can make a pre loader with out any action script.

1) Make a scene containing hidden elements on each frame . All the elements that are bandwidth intensive like graphics, sounds, video....

2) Just change the state of the progress bar at each successive frame

3) At the end all elements are loaded into cache.