Share Posted July 28, 2010 Hi ! i'm using you're old as2 class "preload assets manager" for a website but i got a problem when preloading. i have to wait for a few seconds before preload (no bandwich used during this time). is there a delay function or anything ?? preview of the site : http://salesudvideo.free.fr/4cast here is the AS code import gs.dataTransfer.PreloadAssetManager; var repertoire = "datas/"+_root.langue+"/"; //var preloader_obj = new PreloadAssetManager(["datas/css/forcast.css"], onFinish); var preloader_obj = new PreloadAssetManager(["portfolio.swf","datas/css/forcast.css","datas/portfolio.xml","datas/fly.flv","datas/flyout.flv",repertoire+"xml/forcast.xml",repertoire+"flv/acceuil.flv",repertoire+"flv/broadcast.flv",repertoire+"flv/contact.flv",repertoire+"flv/events.flv",repertoire+"flv/moyens.flv",repertoire+"flv/plasma.flv",repertoire+"flv/portfolio.flv",repertoire+"flv/solutions.flv",repertoire+"img/broadcast.jpg",repertoire+"img/contact.jpg",repertoire+"img/events.jpg",repertoire+"img/moyens.jpg",repertoire+"img/plasma.jpg",repertoire+"img/solutions.jpg",repertoire+"img/portfolio.jpg"], onFinish); this.onEnterFrame = function() { preload.pourc.text = Math.round(preloader_obj.percentLoaded_num) ; } function onFinish(pl_obj:PreloadAssetManager):Void { //Gets called when all the assets are preloaded. root.onEnterFrame = null; trace("ok"); getcss(); TweenMax.to(preload, .3, {_alpha:0,onComplete:function(){preload._visible=false}}); } thanks for helping !! alex Link to comment Share on other sites More sharing options...
Share Posted July 28, 2010 Not sure - maybe you have other stuff going on in your file or maybe it's auditing the size of the files (PreloadAssetManager does that by default). Very difficult to troubleshoot blind. Sorry, that AS2 class is ancient and I don't actively support it anymore Link to comment Share on other sites More sharing options...
Author Share Posted July 28, 2010 i tried by uploading your exemple file with my files and i looks like the same ! do you know if i can remove some part of code for making it faster ? is there some kind of timeout or delayed function ? i do not need to get informations of size of the files preloaded... http://salesudvideo.free.fr/4cast/Preload_Sample.swf Link to comment Share on other sites More sharing options...
Share Posted July 28, 2010 Did you set trackProgress_boolean to false? And are you positive that you don't have a bad URL in there that is stalling things? Link to comment Share on other sites More sharing options...
Author Share Posted July 30, 2010 i did not set trackProgress_boolean to false and when i do it is still the same. i removed the variable so code is now var preloader_obj = new PreloadAssetManager(["portfolio.swf","datas/css/forcast.css","datas/portfolio.xml","datas/fly.flv","datas/flyout.flv","datas/fr/xml/forcast.xml","datas/fr/flv/accueil.flv","datas/fr/flv/broadcast.flv","datas/fr/flv/contact.flv","datas/fr/flv/events.flv","datas/fr/flv/moyens.flv","datas/fr/flv/plasma.flv","datas/fr/flv/portfolio.flv","datas/fr/flv/solutions.flv","datas/fr/img/broadcast.jpg","datas/fr/img/contact.jpg","datas/fr/img/events.jpg","datas/fr/img/moyens.jpg","datas/fr/img/plasma.jpg","datas/fr/img/solutions.jpg","datas/fr/img/portfolio.jpg"], onFinish); all url's are ok even if i choose only one file to preload i still have a "waiting time" before loading. moreover, preloading appears also when i publish the swf within select a bandwich test (ctrl+enter x2) Link to comment Share on other sites More sharing options...
Share Posted July 30, 2010 Like I said, PreloadAssetManager isn't actively supported anymore, and it's virtually impossible for me to troubleshoot for you without seeing your FLA and being able to publish it and see precisely what you're talking about. Sorry, I wish I could give you a quick answer. Link to comment Share on other sites More sharing options...
Author Share Posted July 30, 2010 thanks for all, i join the fla file if you have a minute to look. thanks aso for tween engine and xml parser wich are very helpfull to me !! Link to comment Share on other sites More sharing options...
Share Posted July 31, 2010 I don't have time to look through all that code in your production files - you didn't even include the files you're loading, etc. If you want help troubleshooting, please post a simplified FLA that ONLY includes the absolute necessary code to reproduce the issue. Include all necessary files so that I can simply publish the FLA and immediately see the issue. Link to comment Share on other sites More sharing options...
Author Share Posted August 9, 2010 hi, i found out the problem !!!!!! after a long brain washing i tried to remove css and xml files from assets list and it works normally ! thanks for helping ! ciao !! Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now