hi i got a multilanguage flash site. All my text is loaded by a xml file. But this is freesing my movie in my server. I want to preload the xml file.
here i create my xml object in a include .as file:
private function loadXMLFile(): Void {
var _this:LanguageManager = this;
_xmlDoc = new XML();
_xmlDoc.ignoreWhite = true;
_xmlDoc.onLoad = function(success:Boolean): Void {
if (success) {
_this.xml2Array();
}
}
_xmlDoc.load(_xmlPath);
}
here is my loader movieclip, in the first frame i put this
stop();
onEnterFrame = function () {
//here i m trying to preload my xml object
totalBytes = _parent.getBytesTotal() + _xmlDoc.getBytesTotal();
loadedBytes = _parent.getBytesLoaded() + _xmlDoc.getBytesLoaded()
percent = Math.ceil((loadedBytes/totalBytes)*100);
gotoAndStop(percent);
info_txt.text = percent+" %";
if (percent>=100) {
_parent.gotoAndPlay("Go");
}
};
somenting is wrong??
tks a lot for any advice!
regards!