forked from OpenNeo/impress
jquery data fn stopped working in infinite closet with campaign progress. fixed
This commit is contained in:
parent
7640369332
commit
06302336c5
1 changed files with 23 additions and 22 deletions
|
@ -107,7 +107,7 @@ function PetType() {
|
|||
}
|
||||
}
|
||||
|
||||
PetType.all = [];
|
||||
PetType.all = {};
|
||||
|
||||
PetType.LOAD_ERROR = new LoadError("$color_article $color $species");
|
||||
PetType.DASH_REGEX = /-/g;
|
||||
|
@ -120,7 +120,7 @@ PetType.createFromLink = function (link) {
|
|||
}
|
||||
});
|
||||
pet_type.link = link;
|
||||
PetType.all.push(pet_type);
|
||||
PetType.all[pet_type.id] = pet_type;
|
||||
return pet_type;
|
||||
}
|
||||
|
||||
|
@ -248,10 +248,10 @@ PetType.createFromLink(speciesList.eq(Math.floor(Math.random()*speciesList.lengt
|
|||
|
||||
speciesList.each(function () {
|
||||
var el = $(this);
|
||||
el.data('pet_type', PetType.createFromLink(el));
|
||||
PetType.createFromLink(el);
|
||||
}).live('click', function (e) {
|
||||
e.preventDefault();
|
||||
$(this).data('pet_type').setAsCurrent();
|
||||
PetType.all[$(this).data('id')].setAsCurrent();
|
||||
});
|
||||
|
||||
setTimeout($.proxy(Item.current, 'loadAllStandard'), 5000);
|
||||
|
@ -259,3 +259,4 @@ setTimeout($.proxy(Item.current, 'loadAllStandard'), 5000);
|
|||
window.MainWardrobe = {View: {Outfit: {setFlashIsReady: previewSWFIsReady}}}
|
||||
|
||||
var SWFLog = $.noop;
|
||||
|
||||
|
|
Loading…
Reference in a new issue