keyUp in replay

This commit is contained in:
oc 2018-12-10 01:50:24 +08:00
parent 52a04029b7
commit f891cb1f3b
3 changed files with 6 additions and 6 deletions

View File

@ -192,12 +192,12 @@ actions.prototype.keyDown = function(keyCode) {
}
////// 根据放开键的code来执行一系列操作 //////
actions.prototype.keyUp = function(keyCode, altKey) {
if (core.isset(core.status.replay)&&core.status.replay.replaying
actions.prototype.keyUp = function(keyCode, altKey, fromReplay) {
if (!fromReplay && core.isset(core.status.replay)&&core.status.replay.replaying
&&core.status.event.id!='save'&&(core.status.event.id||"").indexOf('book')!=0&&core.status.event.id!='viewMaps') return;
if (core.status.lockControl) {
core.status.holdingKeys = [];
core.status.holdingKeys = [];g
// 全键盘操作部分
if (core.status.event.id == 'text' && (keyCode==13 || keyCode==32 || keyCode==67)) {
core.drawText();

View File

@ -2130,7 +2130,7 @@ control.prototype.replay = function () {
}
}
else if (action.indexOf('key:')==0) {
core.actions.keyUp(parseInt(action.substring(4)), true);
core.actions.keyUp(parseInt(action.substring(4)), false, true);
core.replay();
return;
}

View File

@ -428,8 +428,8 @@ core.prototype.keyDown = function(keyCode) {
}
////// 根据放开键的code来执行一系列操作 //////
core.prototype.keyUp = function(keyCode, altKey) {
return core.actions.keyUp(keyCode, altKey);
core.prototype.keyUp = function(keyCode, altKey, fromReplay) {
return core.actions.keyUp(keyCode, altKey, fromReplay);
}
////// 点击(触摸)事件按下时 //////