mirror of
https://github.com/doublespeakgames/adarkroom.git
synced 2026-05-28 00:01:54 +08:00
reorder enable god mode code to prevent duplicate area tabs
This commit is contained in:
+21
-21
@@ -835,19 +835,6 @@
|
||||
},
|
||||
|
||||
enableGodMode: function() {
|
||||
// open up all section
|
||||
if(!Outside.tab) {
|
||||
Outside.init();
|
||||
}
|
||||
|
||||
if(!Path.tab) {
|
||||
Path.init();
|
||||
}
|
||||
|
||||
if(!Ship.tab) {
|
||||
Ship.init();
|
||||
}
|
||||
|
||||
// add all remaining craftables and goods
|
||||
var buildSection = $('#buildBtns');
|
||||
if (buildSection.length === 0) {
|
||||
@@ -909,14 +896,6 @@
|
||||
}
|
||||
}
|
||||
|
||||
// remove all cooldowns
|
||||
$('.button').each(function (i, el) {
|
||||
$(el).off('click');
|
||||
$(el).click(function() {
|
||||
$(this).data("handler")($(this));
|
||||
})
|
||||
});
|
||||
|
||||
// set water/health
|
||||
Path.DEFAULT_BAG_SPACE = 1000;
|
||||
World.BASE_WATER = 1000;
|
||||
@@ -943,6 +922,27 @@
|
||||
}
|
||||
}
|
||||
|
||||
// open up all section
|
||||
if(!Outside.tab) {
|
||||
Outside.init();
|
||||
}
|
||||
|
||||
if(!Path.tab) {
|
||||
Path.init();
|
||||
}
|
||||
|
||||
if(!Ship.tab) {
|
||||
Ship.init();
|
||||
}
|
||||
|
||||
// remove all cooldowns
|
||||
$('.button').each(function (i, el) {
|
||||
$(el).off('click');
|
||||
$(el).click(function() {
|
||||
$(this).data("handler")($(this));
|
||||
})
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user