Fix 273 bugs
This commit is contained in:
parent
72ebfbf3d6
commit
e761eb63cc
@ -875,13 +875,21 @@ editor_file = function (editor, callback) {
|
||||
}
|
||||
|
||||
var saveSetting = function (file, actionList, callback) {
|
||||
var _update = function (name, value) {
|
||||
if (value[2] === undefined) {
|
||||
eval("delete " + name + value[1]);
|
||||
} else {
|
||||
eval(name + value[1] + "=" + JSON.stringify(value[2]));
|
||||
}
|
||||
}
|
||||
|
||||
//console.log(file);
|
||||
//console.log(actionList);
|
||||
editor.file.alertWhenCompress();
|
||||
|
||||
if (file == 'icons') {
|
||||
actionList.forEach(function (value) {
|
||||
eval("icons_4665ee12_3a1f_44a4_bea3_0fccba634dc1" + value[1] + '=' + JSON.stringify(value[2]));
|
||||
_update("icons_4665ee12_3a1f_44a4_bea3_0fccba634dc1", value);
|
||||
});
|
||||
var datastr = 'var icons_4665ee12_3a1f_44a4_bea3_0fccba634dc1 = \n';
|
||||
datastr += JSON.stringify(icons_4665ee12_3a1f_44a4_bea3_0fccba634dc1, null, '\t');
|
||||
@ -892,7 +900,7 @@ editor_file = function (editor, callback) {
|
||||
}
|
||||
if (file == 'maps') {
|
||||
actionList.forEach(function (value) {
|
||||
eval("maps_90f36752_8815_4be8_b32b_d7fad1d0542e" + value[1] + '=' + JSON.stringify(value[2]));
|
||||
_update("maps_90f36752_8815_4be8_b32b_d7fad1d0542e", value);
|
||||
});
|
||||
var datastr = 'var maps_90f36752_8815_4be8_b32b_d7fad1d0542e = \n';
|
||||
//datastr+=JSON.stringify(maps_90f36752_8815_4be8_b32b_d7fad1d0542e,null,4);
|
||||
@ -917,7 +925,7 @@ editor_file = function (editor, callback) {
|
||||
}
|
||||
if (file == 'items') {
|
||||
actionList.forEach(function (value) {
|
||||
eval("items_296f5d02_12fd_4166_a7c1_b5e830c9ee3a" + value[1] + '=' + JSON.stringify(value[2]));
|
||||
_update("items_296f5d02_12fd_4166_a7c1_b5e830c9ee3a", value);
|
||||
});
|
||||
var datastr = 'var items_296f5d02_12fd_4166_a7c1_b5e830c9ee3a = \n';
|
||||
var items = core.clone(items_296f5d02_12fd_4166_a7c1_b5e830c9ee3a);
|
||||
@ -930,7 +938,7 @@ editor_file = function (editor, callback) {
|
||||
}
|
||||
if (file == 'enemys') {
|
||||
actionList.forEach(function (value) {
|
||||
eval("enemys_fcae963b_31c9_42b4_b48c_bb48d09f3f80" + value[1] + '=' + JSON.stringify(value[2]));
|
||||
_update("enemys_fcae963b_31c9_42b4_b48c_bb48d09f3f80", value);
|
||||
});
|
||||
var datastr = 'var enemys_fcae963b_31c9_42b4_b48c_bb48d09f3f80 = \n';
|
||||
var emap = {};
|
||||
@ -954,7 +962,7 @@ editor_file = function (editor, callback) {
|
||||
}
|
||||
if (file == 'data') {
|
||||
actionList.forEach(function (value) {
|
||||
eval("data_a1e2fb4a_e986_4524_b0da_9b7ba7c0874d" + value[1] + '=' + JSON.stringify(value[2]));
|
||||
_update("data_a1e2fb4a_e986_4524_b0da_9b7ba7c0874d", value);
|
||||
});
|
||||
if (data_a1e2fb4a_e986_4524_b0da_9b7ba7c0874d.main.floorIds.indexOf(data_a1e2fb4a_e986_4524_b0da_9b7ba7c0874d.firstData.floorId) < 0)
|
||||
data_a1e2fb4a_e986_4524_b0da_9b7ba7c0874d.firstData.floorId = data_a1e2fb4a_e986_4524_b0da_9b7ba7c0874d.main.floorIds[0];
|
||||
@ -1006,7 +1014,7 @@ editor_file = function (editor, callback) {
|
||||
}
|
||||
if (file == 'events') {
|
||||
actionList.forEach(function (value) {
|
||||
eval("events_c12a15a8_c380_4b28_8144_256cba95f760" + value[1] + '=' + JSON.stringify(value[2]));
|
||||
_update("events_c12a15a8_c380_4b28_8144_256cba95f760", value);
|
||||
});
|
||||
var datastr = 'var events_c12a15a8_c380_4b28_8144_256cba95f760 = \n';
|
||||
datastr += JSON.stringify(events_c12a15a8_c380_4b28_8144_256cba95f760, null, '\t');
|
||||
|
||||
@ -872,7 +872,6 @@ editor_ui_wrapper = function (editor) {
|
||||
if (span.style.display == 'none') {
|
||||
clearInterval(uievent.values.interval);
|
||||
uievent.values.interval = null;
|
||||
span.removeChild(uievent.values.dom);
|
||||
return;
|
||||
}
|
||||
core.clearMap(uievent.values.ctx);
|
||||
|
||||
@ -2167,7 +2167,7 @@ actions.prototype._clickSwitchs_display_enemyDamage = function () {
|
||||
actions.prototype._clickSwitchs_display_critical = function () {
|
||||
core.flags.displayCritical = !core.flags.displayCritical;
|
||||
core.updateDamage();
|
||||
core.setLocalStorage('critical', core.flags.displayExtraDamage);
|
||||
core.setLocalStorage('critical', core.flags.displayCritical);
|
||||
core.ui._drawSwitchs_display();
|
||||
}
|
||||
|
||||
|
||||
@ -351,8 +351,8 @@ core.prototype._init_platform = function () {
|
||||
}
|
||||
core.musicStatus.bgmStatus = core.getLocalStorage('bgmStatus', true);
|
||||
core.musicStatus.soundStatus = core.getLocalStorage('soundStatus', true);
|
||||
//新增 userVolume 默认值1.0
|
||||
core.musicStatus.userVolume = core.getLocalStorage('userVolume', 1.0);
|
||||
//新增 userVolume 默认值0.7
|
||||
core.musicStatus.userVolume = core.getLocalStorage('userVolume', 0.7);
|
||||
["Android", "iPhone", "SymbianOS", "Windows Phone", "iPad", "iPod"].forEach(function (t) {
|
||||
if (navigator.userAgent.indexOf(t) >= 0) {
|
||||
if (t == 'iPhone' || t == 'iPad' || t == 'iPod') core.platform.isIOS = true;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user