silver-bullet/js/plugins/Vertical_Swinging.js
2024-07-02 14:17:45 -05:00

16 lines
476 B
JavaScript
Raw Permalink Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

//rpg_sprites.js より抜粋
/*:
* @plugindesc シェイクを縦にするよ。
* @author ゆわか
*/
Spriteset_Base.prototype.updatePosition = function () {
var screen = $gameScreen;
var scale = screen.zoomScale();
this.scale.x = scale;
this.scale.y = scale;
this.x = Math.round(-screen.zoomX() * (scale - 1));
this.y = Math.round(-screen.zoomY() * (scale - 1));
this.y += Math.round(screen.shake()); //ここのyをxに戻せば横揺れになる
};