刚才用了一个纯色白底的远景地图
然后就看不出来抖了
看来不是事件在抖而是远景图滚动的时候在抖。。。
看默认的js,远景的滚动是跟着地图走的
rpg_object.js
Game_Map.prototype.setDisplayPos = function(x, y) { if (this.isLoopHorizontal()) { this._displayX = x.mod(this.width()); this._parallaxX = x; } else { var endX = this.width() - this.screenTileX(); this._displayX = endX < 0 ? endX / 2 : x.clamp(0, endX); this._parallaxX = this._displayX; } if (this.isLoopVertical()) { this._displayY = y.mod(this.height()); this._parallaxY = y; } else { var endY = this.height() - this.screenTileY(); this._displayY = endY < 0 ? endY / 2 : y.clamp(0, endY); this._parallaxY = this._displayY; } };
Game_Map.prototype.setDisplayPos = function(x, y) {
if (this.isLoopHorizontal()) {
this._displayX = x.mod(this.width());
this._parallaxX = x;
} else {
var endX = this.width() - this.screenTileX();
this._displayX = endX < 0 ? endX / 2 : x.clamp(0, endX);
this._parallaxX = this._displayX;
}
if (this.isLoopVertical()) {
this._displayY = y.mod(this.height());
this._parallaxY = y;
} else {
var endY = this.height() - this.screenTileY();
this._displayY = endY < 0 ? endY / 2 : y.clamp(0, endY);
this._parallaxY = this._displayY;
}
};
不知道是哪个地方抽了,analog move里面地图没有抖,远景图倒是抖了。搜了下也没看到parallax的相关代码 |