PGUP change floor

This commit is contained in:
oc 2018-05-18 09:48:41 +08:00
parent c0fb3621ca
commit d6b217730b
2 changed files with 26 additions and 5 deletions

View File

@ -542,6 +542,29 @@ editor.prototype.listen = function () {
currDrawData = JSON.parse(JSON.stringify(reDo));
reDo = null;
}
// PGUP和PGDOWN切换楼层
if (e.keyCode==33) {
e.preventDefault();
var index=editor.core.floorIds.indexOf(editor.currentFloorId);
if (index>0) {
var toId = editor.core.floorIds[index-1];
editor_mode.onmode('nextChange');
editor_mode.onmode('floor');
document.getElementById('selectFloor').value = toId;
editor.changeFloor(toId);
}
}
if (e.keyCode==34) {
e.preventDefault();
var index=editor.core.floorIds.indexOf(editor.currentFloorId);
if (index<editor.core.floorIds.length-1) {
var toId = editor.core.floorIds[index+1];
editor_mode.onmode('nextChange');
editor_mode.onmode('floor');
document.getElementById('selectFloor').value = toId;
editor.changeFloor(toId);
}
}
}
var dataSelection = document.getElementById('dataSelection');

View File

@ -3,19 +3,17 @@
地图编辑器可以右键复制或移动图块 √
事件while循环处理 √
事件:等待用户操作并获得按键或点击信息 √
衰弱减少攻防的比例 √
衰弱可以减少攻防的比例 √
地图数据统计
支持 status:x 获得当前坐标 √
最大存档个数提到main处理 √
新建地图可以保留楼层属性 √
地图编辑器可用PageUp和PageDown切换楼层 √
道具描述过长时可以自动换行 √
除Autotile外均可自动注册 √
重写大部分教程,新增大量拓展描述 √
部分素材进行了替换 √
便捷PS工具偶尔的闪退问题
修复转向触发事件的朝向Bug √
修复flyRange的顺序问题 √
部分细节优化 √
大量细节进行优化所有已知的bug进行了修复 √
-----------------------------------------------------------------------