Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #initclip 28
- if (!dofus.utils.LoadConfigModulesList)
- {
- if (!dofus)
- {
- _global.dofus = new Object();
- }
- // end if
- if (!dofus.utils)
- {
- _global.dofus.utils = new Object();
- }
- // end if
- var _loc1 = (_global.dofus.utils.LoadConfigModulesList = function ()
- {
- super();
- }).prototype;
- _loc1.createChildren = function()
- {
- this.addToQueue({object:this, method:this.loadModules});
- };
- _loc1.loadModulesXML = function()
- {
- this.api.kernel.showMessage(undefined,"load","ERROR_CHAT");
- var modulesXML = new XML();
- modulesXML.ignoreWhite = true;
- modulesXML.onLoad = function(bSuccess)
- {
- _loc1.onModulesListLoaded(bSuccess,this);
- };
- modulesXML.load("modules/list.xml");
- };
- _loc1.onModulesListLoaded = function(bSuccess, xDoc)
- {
- if (bSuccess)
- {
- var modules = xDoc.firstChild.childNodes;
- if (modules.childNodes.length == 0 || modules == null || modules == undefined)
- {
- this.criticalError("CORRUPT_CONFIG_FILE",this.TABULATION,false);
- return;
- }
- for (var module in modules)
- {
- var attributes = modules[module].attributes;
- var mod = {id:attributes.id, name:attributes.name, path:attributes.path};
- createEmptyMovieClip(mod.name,mod.id);
- loadMovie(mod.path, mod.name);
- this.api.kernel.showMessage(undefined,mod.name + " - " + mod.path,"ERROR_CHAT");
- }
- }
- };
- ASSetPropFlags(_loc1,null,1);
- }
- // end if
- #endinitclip
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement