117 lines
No EOL
28 KiB
JavaScript
117 lines
No EOL
28 KiB
JavaScript
/*:
|
|
* @plugindesc スクロールバープラグイン
|
|
* @author Tennana
|
|
*
|
|
* @help 指定の変数を操作するスクロールバーを作成、表示します
|
|
*
|
|
*【プラグインコマンド】
|
|
* スクロールバー生成 [バー番号] [バー左上X座標] [バー左上Y座標] [バーの横幅ピクセル] [変数番号] [最小値] [最大値] [変更時のコモンイベント番号]
|
|
* 指定した番号でスクロールバーを生成します。パラメーターは省略できません。
|
|
*
|
|
* スクロールバー表示 [バー番号] [TRUE:表示 or FALSE:非表示]
|
|
* 指定した番号のバーの表示状態を変更します。
|
|
*
|
|
* スクロールバー選択 [バー番号]
|
|
* 指定した番号のバーを選択状態にします。選択中のバーは表示を変更できる他、キーボード・ゲームパッドの左・右入力を受け付けるようになります。
|
|
*
|
|
* スクロールバー全消去
|
|
* 生成されたすべてのスクロールバーを消去します。再度表示するためには生成から行う必要があります。
|
|
* 「場所の移動」で他のマップへ移動した場合、自動的に実行されます。
|
|
*
|
|
* スクロールバーテキスト [バー番号] [位置指定文字] [テキスト]
|
|
* 指定した番号のバーに一行テキスト表示を追加します。「文章の表示」コマンドの制御文字が使用可能です。
|
|
* 位置指定文字は以下の通りです。
|
|
* 左 or l: バーの左
|
|
* 右 or r: バーの右
|
|
* 左上 or lt: バーの左上
|
|
* 右上 or rt: バーの右上
|
|
*
|
|
* スクロールバー目盛り設定 [バー番号] [間隔]
|
|
* 指定した番号のバーに目盛り表示を設定します。間隔が1以上であれば、指定間隔で縦線を表示します。0で非表示となります。
|
|
*
|
|
* @param Bar Height
|
|
* @text バーの高さ
|
|
* @default 30
|
|
* @type number
|
|
* @min 10
|
|
* @decimals 0
|
|
* @desc バーの高さをピクセル単位で指定します。
|
|
*
|
|
* @param Normal Bar Style
|
|
* @default
|
|
* @type string
|
|
* @desc 非選択時のバーの表示を設定します。
|
|
*
|
|
* @param Normal Bar Color
|
|
* @text バーの色(非選択時)
|
|
* @type number
|
|
* @default 5
|
|
* @min 0
|
|
* @max 31
|
|
* @decimals 0
|
|
* @parent Normal Bar Style
|
|
* @desc 非選択時のバーの色をツクールの色番号で指定します。
|
|
*
|
|
* @param Normal Pinch Image
|
|
* @text つまみ画像(非選択時)
|
|
* @type file
|
|
* @dir img/
|
|
* @default white
|
|
* @parent Normal Bar Style
|
|
* @desc 非選択時のつまみ画像を指定します。縦横サイズがバーの高さと同じである必要があります。
|
|
* または、テキストタブでHTMLカラーコードを指定すると、正丸のつまみを生成します。
|
|
*
|
|
* @param Normal Scale Color
|
|
* @text 目盛りの色(非選択時)
|
|
* @type number
|
|
* @default 1
|
|
* @min 0
|
|
* @max 31
|
|
* @decimals 0
|
|
* @parent Normal Bar Style
|
|
* @desc 非選択時のバーの目盛り線の色をツクールの色番号で指定します。
|
|
*
|
|
* @param Selected Bar Style
|
|
* @default
|
|
* @type string
|
|
* @desc 選択時のバーの表示を設定します。
|
|
*
|
|
* @param Selected Bar Color
|
|
* @text バーの色(選択時)
|
|
* @type number
|
|
* @default 3
|
|
* @min 0
|
|
* @max 31
|
|
* @decimals 0
|
|
* @parent Selected Bar Style
|
|
* @desc 選択時のバーの色をツクールの色番号で指定します。
|
|
*
|
|
* @param Selected Pinch Image
|
|
* @text つまみ画像(選択時)
|
|
* @type file
|
|
* @dir img/
|
|
* @default magenta
|
|
* @parent Selected Bar Style
|
|
* @desc 選択時のつまみ画像を指定します。縦横サイズがバーの高さと同じである必要があります。
|
|
* または、テキストタブでHTMLカラーコードを指定すると、正丸のつまみを生成します。
|
|
*
|
|
* @param Selected Scale Color
|
|
* @text 目盛りの色(選択時)
|
|
* @type number
|
|
* @default 1
|
|
* @min 0
|
|
* @max 31
|
|
* @decimals 0
|
|
* @parent Selected Bar Style
|
|
* @desc 選択時のバーの目盛り線の色をツクールの色番号で指定します。
|
|
*
|
|
* @param Long Input Threshold
|
|
* @text 長押し判定閾値
|
|
* @type number
|
|
* @default 5
|
|
* @min 1
|
|
* @max 30
|
|
* @decimals 0
|
|
* @desc キーボード、ゲームパッドの入力を長押しと判定する閾値です。長押しによる加速のタイミングを調整したい場合に変更して下さい。
|
|
*/
|
|
function a0_0x1587() { const _0x52472e = ['maxX', 'align', '_interval', 'make', '_barText', 'round', '_range', 'isReleased', '_value', 'refresh', 'getColor', '7553861upPjbj', 'min', '_scene', 'スクロールバーテキスト', '_enabled', 'createSpriteset', '_repeatCount', '$gameScrollBar', 'Selected\x20Bar\x20Color', '_currentStyle', 'addChildAt', 'xAnchor', '_max', '_lastKeyName', '10400khdjQM', '_updateText', 'updateTextBar', 'interval', '_text', 'forEach', 'isRepeated', '_position', 'toPosition', 'prototype', 'toNumber', 'Container', 'pinch', 'findIndex', 'スクロールバー生成', 'screenHeight', 'isTouchPosInRect', 'スクロールバー選択', '_lastTriggerdValue', 'isLongPressed', 'select', 'anchor', '_barWidth', 'convertEscapeCharacters', 'contains', 'Normal\x20Bar\x20Color', 'removeChild', 'textColor', '_min', 'height', 'isPressed', '_commonEventNumber', 'setDirty', '9149970UyBLMZ', '123vXsqEd', '_pinch', 'allRemoveScene', 'moveTo', 'initialize', 'right', 'touchEvent', 'clear', 'まだ生成されていないスクロールバーが選択されました', '_transfer', '_visible', '975470igjulR', '_scrollScale', 'img/', '_scaleColor', 'isNextScene', 'minY', 'SBUI_Scrollbar_ui', '_textSprite', 'startsWith', 'update', 'apply', 'beginFill', 'Normal\x20Scale\x20Color', 'scale', 'width', 'addChild', 'minX', 'scaleColor', 'Window', '1447772JnvqQt', 'parameters', '_updateBarStyle', 'drawRoundedRect', 'yPos', '381192OBzjGk', 'string', 'white', 'values', 'onChange', '_isSelected', 'bitmap', '63374oanAwv', 'スクロールバー目盛り設定', 'setValue', 'parent', 'max', '8010nrRSsm', 'barColor', 'allAddScene', 'opacity', 'setVisible', '_createSprite', 'loadSystem', '_pinchSprite', 'substr', 'loadBitmap', 'setSelected', '_scrollBar', 'number', 'toUpperCase', 'スクロールバー全消去', 'start', '_spriteset', '_barColor', 'createBar', '_graphics', 'isTriggered', 'magenta', 'terminate', 'createDisplayObjects', 'drawCircle', '_triggerCommonEvent', 'pluginCommand', 'children', 'maxY', '24gjrVlE', 'get', 'find', 'isMoved', 'endFill', 'addScene', '_variableNumber', '_windowLayer', 'updateChildren', '_createTextSprite', 'Long\x20Input\x20Threshold', 'call', '_keyEvent', 'Graphics', 'スクロールバー表示', 'visible', 'toPositionX', 'entries', 'screenY', 'drawText', 'lineStyle', 'value', 'screenX', 'screenWidth', 'left']; a0_0x1587 = function () { return _0x52472e; }; return a0_0x1587(); } function a0_0x1ce6(_0x19893a, _0x5cd9e6) { const _0x15875b = a0_0x1587(); return a0_0x1ce6 = function (_0x1ce61e, _0x597a51) { _0x1ce61e = _0x1ce61e - 0x108; let _0x5e3a7c = _0x15875b[_0x1ce61e]; return _0x5e3a7c; }, a0_0x1ce6(_0x19893a, _0x5cd9e6); } (function (_0xa5d561, _0x9b0747) { const _0x584cf8 = a0_0x1ce6, _0x394514 = _0xa5d561(); while (!![]) { try { const _0x59099a = -parseInt(_0x584cf8(0x1a1)) / 0x1 + parseInt(_0x584cf8(0x108)) / 0x2 * (parseInt(_0x584cf8(0x17e)) / 0x3) + parseInt(_0x584cf8(0x19c)) / 0x4 + parseInt(_0x584cf8(0x189)) / 0x5 * (parseInt(_0x584cf8(0x12a)) / 0x6) + -parseInt(_0x584cf8(0x14e)) / 0x7 + parseInt(_0x584cf8(0x15c)) / 0x8 * (-parseInt(_0x584cf8(0x10d)) / 0x9) + parseInt(_0x584cf8(0x17d)) / 0xa; if (_0x59099a === _0x9b0747) break; else _0x394514['push'](_0x394514['shift']()); } catch (_0x460010) { _0x394514['push'](_0x394514['shift']()); } } }(a0_0x1587, 0xb4760), (function () { const _0x13b2ca = a0_0x1ce6, _0x595324 = PluginManager[_0x13b2ca(0x19d)](_0x13b2ca(0x18f)), _0x3cf492 = _0x49436c(_0x595324['Bar\x20Height'], 0x1e), _0x186fba = _0x49436c(_0x595324[_0x13b2ca(0x134)], 0x5); function _0x381ab8(_0x1b1245, _0x186c3e) { const _0x372751 = _0x13b2ca; if (typeof _0x1b1245 === _0x372751(0x1a2) && _0x1b1245[_0x372751(0x191)]('#')) return _0x1b1245; return _0x49436c(_0x1b1245, _0x186c3e); } function _0x49436c(_0x556853, _0x52c2a8) { if (_0x556853 === null || _0x556853 === undefined || _0x556853 === '') return _0x52c2a8; return parseInt(_0x556853); } function _0x4f745c(_0x2aadee) { const _0x3933d0 = _0x13b2ca; return _0x2aadee && (_0x2aadee[_0x3933d0(0x11a)]() === 'TRUE' || _0x2aadee === '1'); } let _0x36ffce = Game_Interpreter['prototype']['pluginCommand']; Game_Interpreter[_0x13b2ca(0x165)][_0x13b2ca(0x127)] = function (_0x30bee1, _0x1472a1) { const _0x39d49b = _0x13b2ca; _0x36ffce[_0x39d49b(0x135)](this, _0x30bee1, _0x1472a1); let _0x2f749b; switch ((_0x30bee1 || '')['toUpperCase']()) { case _0x39d49b(0x16a): $gameScrollBar[_0x39d49b(0x11f)](_0x1472a1); break; case _0x39d49b(0x138): _0x2f749b = $gameScrollBar[_0x39d49b(0x12b)](_0x1472a1[0x0]), _0x2f749b[_0x39d49b(0x111)](_0x4f745c(_0x1472a1[0x1])); break; case _0x39d49b(0x16d): $gameScrollBar[_0x39d49b(0x170)](_0x1472a1[0x0]); break; case _0x39d49b(0x11b): $gameScrollBar[_0x39d49b(0x185)](); break; case _0x39d49b(0x151): _0x2f749b = $gameScrollBar[_0x39d49b(0x12b)](_0x1472a1[0x0]), _0x2f749b[_0x39d49b(0x15e)]['apply'](_0x2f749b, _0x1472a1); case _0x39d49b(0x109): _0x2f749b = $gameScrollBar[_0x39d49b(0x12b)](_0x1472a1[0x0]), _0x2f749b[_0x39d49b(0x18a)][_0x39d49b(0x15f)] = Number(_0x1472a1[0x1]), _0x2f749b[_0x39d49b(0x17c)](!![]); default: break; } }; class _0x51cc2c { constructor(_0x5c8196, _0x51425e, _0x4f53ad) { const _0x3add8f = _0x13b2ca; this[_0x3add8f(0x17f)] = _0x5c8196, this[_0x3add8f(0x11e)] = _0x51425e, this[_0x3add8f(0x18c)] = _0x4f53ad; } get [_0x13b2ca(0x168)]() { const _0x32a43d = _0x13b2ca; if (this[_0x32a43d(0x17f)] && this[_0x32a43d(0x17f)][_0x32a43d(0x174)]('/')) { const _0x82c70f = this['_pinch']['split']('/', 0x2); return ImageManager[_0x32a43d(0x116)](_0x32a43d(0x18b) + _0x82c70f[0x0] + '/', _0x82c70f[0x1], null, !![]); } const _0x5bf140 = this['_pinch'] || _0x32a43d(0x1a3), _0x29d1e9 = new Bitmap(_0x3cf492, _0x3cf492); return _0x29d1e9[_0x32a43d(0x125)](_0x3cf492 / 0x2, _0x3cf492 / 0x2, _0x3cf492 / 0x2, _0x5bf140), _0x29d1e9; } get ['barColor']() { const _0x397f3b = _0x13b2ca; return typeof this[_0x397f3b(0x11e)] === _0x397f3b(0x119) && (this[_0x397f3b(0x11e)] = $gameScrollBar[_0x397f3b(0x14d)](this[_0x397f3b(0x11e)])), parseInt(this[_0x397f3b(0x11e)][_0x397f3b(0x115)](0x1), 0x10); } get ['scaleColor']() { const _0x38afc3 = _0x13b2ca; return typeof this['_scaleColor'] === 'number' && (this['_scaleColor'] = $gameScrollBar[_0x38afc3(0x14d)](this['_scaleColor'])), parseInt(this[_0x38afc3(0x18c)][_0x38afc3(0x115)](0x1), 0x10); } } const _0x55526f = new _0x51cc2c(_0x595324['Normal\x20Pinch\x20Image'] || _0x13b2ca(0x1a3), _0x381ab8(_0x595324[_0x13b2ca(0x175)], 0x5), _0x381ab8(_0x595324[_0x13b2ca(0x195)], 0x1)), _0x52fbed = new _0x51cc2c(_0x595324['Selected\x20Pinch\x20Image'] || _0x13b2ca(0x122), _0x381ab8(_0x595324[_0x13b2ca(0x156)], 0x3), _0x381ab8(_0x595324['Selected\x20Scale\x20Color'], 0x1b)); class _0x5abc29 { constructor() { const _0x51dfe6 = _0x13b2ca; this[_0x51dfe6(0x118)] = {}, this['windowskin'] = ImageManager[_0x51dfe6(0x113)](_0x51dfe6(0x19b)); } [_0x13b2ca(0x14d)](_0x3e07ed) { const _0x185f0a = _0x13b2ca; return Window_Base[_0x185f0a(0x165)][_0x185f0a(0x177)][_0x185f0a(0x135)](this, _0x3e07ed); } ['update']() { const _0x679661 = _0x13b2ca; Object[_0x679661(0x1a4)](this[_0x679661(0x118)])[_0x679661(0x161)](_0xad93fe => _0xad93fe[_0x679661(0x192)]()); } [_0x13b2ca(0x139)](_0x39a342) { const _0x317774 = _0x13b2ca; Object['values'](this['_scrollBar'])['forEach'](_0x2b3e56 => _0x2b3e56[_0x317774(0x111)](_0x39a342)); } [_0x13b2ca(0x170)](_0x2e46e4) { const _0x2de113 = _0x13b2ca; Object[_0x2de113(0x1a4)](this[_0x2de113(0x118)])[_0x2de113(0x161)](_0x4f7c08 => _0x4f7c08[_0x2de113(0x117)](![])); if (_0x2e46e4) { if (typeof _0x2e46e4 === 'object') { _0x2e46e4[_0x2de113(0x117)](!![]); return; } this[_0x2de113(0x12b)](_0x2e46e4)['setSelected'](!![]); } } ['initialize']() { } [_0x13b2ca(0x11f)](_0x2d30ef) { const _0x4277c3 = _0x13b2ca, _0x31a8b2 = new _0xc60c3b(); this[_0x4277c3(0x118)]['' + _0x2d30ef[0x0]] = _0x31a8b2, this[_0x4277c3(0x12f)](_0x31a8b2[_0x4277c3(0x182)][_0x4277c3(0x193)](_0x31a8b2, _0x2d30ef)); } [_0x13b2ca(0x12b)](_0x259506) { const _0x2e574f = _0x13b2ca; let _0x1d0ea6 = this[_0x2e574f(0x118)]['' + _0x259506]; if (!_0x1d0ea6) { const _0x13c610 = SceneManager['_scene'][_0x2e574f(0x131)]['children'][0x0], _0x11e45d = _0x13c610 ? _0x13c610[_0x2e574f(0x173)](_0x259506) : _0x259506; _0x1d0ea6 = this[_0x2e574f(0x118)]['' + _0x11e45d], !_0x1d0ea6 && console['warn'](_0x2e574f(0x186)); } return _0x1d0ea6; } ['getSelectedNumber']() { const _0x2b7ead = _0x13b2ca, _0xb2d855 = Object[_0x2b7ead(0x13b)](this[_0x2b7ead(0x118)])[_0x2b7ead(0x12c)](_0x8ec6ed => { const _0x5566e8 = _0x2b7ead; return _0x8ec6ed[0x1][_0x5566e8(0x1a6)]; }); if (_0xb2d855) return _0xb2d855[0x0]; return -0x1; } [_0x13b2ca(0x185)]() { const _0x103773 = _0x13b2ca; Object[_0x103773(0x1a4)](this['_scrollBar'])['forEach'](_0x10956d => _0x10956d[_0x103773(0x185)]()), this[_0x103773(0x118)] = {}; } ['addScene'](_0x5ead6f) { const _0x10a38a = _0x13b2ca; let _0x4edf1c = SceneManager['_scene'][_0x10a38a(0x11d)]; const _0x570ab6 = _0x4edf1c[_0x10a38a(0x128)][_0x10a38a(0x169)](function (_0x43b62e) { return _0x43b62e instanceof Sprite_Timer; }); _0x4edf1c[_0x10a38a(0x158)](_0x5ead6f, _0x570ab6); } ['allAddScene']() { const _0x15ecb6 = _0x13b2ca, _0x3ae130 = SceneManager['_scene']; Object['values'](this['_scrollBar'])[_0x15ecb6(0x161)](_0x4f6284 => this[_0x15ecb6(0x12f)](_0x4f6284)); } [_0x13b2ca(0x180)]() { const _0x45fb2d = _0x13b2ca, _0x37c736 = SceneManager[_0x45fb2d(0x150)][_0x45fb2d(0x11d)]; Object[_0x45fb2d(0x1a4)](this[_0x45fb2d(0x118)])['forEach'](_0x16fcbd => _0x37c736[_0x45fb2d(0x176)](_0x16fcbd)); } } class _0xc60c3b extends PIXI[_0x13b2ca(0x167)]{ [_0x13b2ca(0x182)](_0x42dd72, _0x35da93, _0x36dd50, _0x44056, _0x21cefd, _0x54eaca, _0xf6adc8, _0x3ca43a) { const _0x276ae4 = _0x13b2ca; return this[_0x276ae4(0x178)] = Number(_0x54eaca), this['_max'] = Number(_0xf6adc8), this[_0x276ae4(0x172)] = Number(_0x44056), !this[_0x276ae4(0x152)] && (this[_0x276ae4(0x147)] = {}, this[_0x276ae4(0x112)](this['_barWidth'], _0x35da93, _0x36dd50), this[_0x276ae4(0x18a)] = _0x52c2d5[_0x276ae4(0x146)](this[_0x276ae4(0x172)], this[_0x276ae4(0x149)](), 0x0)), this['_enabled'] = !![], this[_0x276ae4(0x15b)] = null, this[_0x276ae4(0x154)] = 0x0, this[_0x276ae4(0x130)] = Number(_0x21cefd), this[_0x276ae4(0x17b)] = Number(_0x3ca43a), this['_value'] = $gameVariables[_0x276ae4(0x13f)](this[_0x276ae4(0x130)]), this[_0x276ae4(0x114)]['x'] = this[_0x276ae4(0x13a)](this[_0x276ae4(0x14b)]), this['_isSelected'] = ![], this[_0x276ae4(0x19e)](_0x55526f), this[_0x276ae4(0x111)](!![]), this['update'](), this; } ['_createSprite'](_0x1929b2, _0x5cd95e, _0x37f573) { const _0x103135 = _0x13b2ca; PIXI[_0x103135(0x167)][_0x103135(0x135)](this), this['_graphics'] = new PIXI[(_0x103135(0x137))](), this[_0x103135(0x120)][_0x103135(0x197)] = _0x1929b2, this['_graphics'][_0x103135(0x179)] = _0x3cf492, this['x'] = Number(_0x5cd95e), this['y'] = Number(_0x37f573), this[_0x103135(0x198)](this[_0x103135(0x120)]), this[_0x103135(0x110)] = 0x0, this[_0x103135(0x114)] = new _0x530207(), this[_0x103135(0x114)]['x'] = 0x0, this[_0x103135(0x114)]['y'] = 0x0, this[_0x103135(0x114)][_0x103135(0x171)] = { 'x': 0.5, 'y': 0x0 }, this['addChild'](this[_0x103135(0x114)]); } [_0x13b2ca(0x19e)](_0x4fe292) { const _0x5638ce = _0x13b2ca; if (this[_0x5638ce(0x157)] === _0x4fe292 || !_0x4fe292) return; this[_0x5638ce(0x120)][_0x5638ce(0x185)](), this[_0x5638ce(0x120)][_0x5638ce(0x194)](_0x4fe292[_0x5638ce(0x10e)]), this[_0x5638ce(0x120)][_0x5638ce(0x19f)](0x0, 0x0, this[_0x5638ce(0x172)], _0x3cf492, _0x3cf492 / 0x2), this[_0x5638ce(0x120)][_0x5638ce(0x12e)](), this[_0x5638ce(0x18a)][_0x5638ce(0x192)](this[_0x5638ce(0x120)], _0x4fe292), this[_0x5638ce(0x114)][_0x5638ce(0x1a7)] = _0x4fe292['pinch'], this[_0x5638ce(0x157)] = _0x4fe292; } [_0x13b2ca(0x149)]() { const _0x2b9421 = _0x13b2ca; return this[_0x2b9421(0x15a)] - this[_0x2b9421(0x178)]; } [_0x13b2ca(0x13a)](_0x509efc) { const _0x116108 = _0x13b2ca; return Math[_0x116108(0x10c)](0x0, Math[_0x116108(0x14f)](Math[_0x116108(0x148)](this[_0x116108(0x172)] / this[_0x116108(0x149)]() * _0x509efc), this['_barWidth'])); } [_0x13b2ca(0x166)]() { const _0x606a4 = _0x13b2ca; return Math[_0x606a4(0x148)](this['_pinchSprite']['x'] / (this[_0x606a4(0x172)] / this[_0x606a4(0x149)]())); } [_0x13b2ca(0x136)](_0x40e2c1, _0x2b55b2) { const _0x2e5c10 = _0x13b2ca; if (!Input[_0x2e5c10(0x17a)](_0x40e2c1)) { this[_0x2e5c10(0x15b)] === _0x40e2c1 && (this[_0x2e5c10(0x154)] = 0x0); return; } let _0x4cf2a2 = Input[_0x2e5c10(0x121)](_0x40e2c1); if (!_0x4cf2a2 && !Input[_0x2e5c10(0x162)](_0x40e2c1)) return; (_0x4cf2a2 || this['_lastKeyName'] !== _0x40e2c1) && (this[_0x2e5c10(0x154)] = 0x0); this[_0x2e5c10(0x15b)] = _0x40e2c1; const _0x1f32a5 = this[_0x2e5c10(0x14b)]; this[_0x2e5c10(0x14b)] = Math['max'](Math[_0x2e5c10(0x14f)](this['_max'], this[_0x2e5c10(0x14b)] + _0x2b55b2 * (this['_repeatCount'] > _0x186fba ? 0x5 : 0x1)), this[_0x2e5c10(0x178)]); if (_0x1f32a5 === this[_0x2e5c10(0x14b)]) return; $gameVariables['setValue'](this[_0x2e5c10(0x130)], this[_0x2e5c10(0x14b)]), this['_triggerCommonEvent'](this[_0x2e5c10(0x14b)]), this[_0x2e5c10(0x154)]++; } [_0x13b2ca(0x192)]() { const _0x12b634 = _0x13b2ca; if (!this['_visible'] || !this[_0x12b634(0x152)]) return; const _0x3d9d8c = this['_value']; this[_0x12b634(0x14b)] = $gameVariables[_0x12b634(0x13f)](this['_variableNumber']), this['_updateBarStyle'](this['_isSelected'] ? _0x52fbed : _0x55526f); if (this['_pinchSprite'][_0x12b634(0x121)]()) { if (this[_0x12b634(0x1a6)]) { } else { if (TouchInput[_0x12b634(0x121)]()) $gameScrollBar[_0x12b634(0x170)](this); else return; } this[_0x12b634(0x184)](), this[_0x12b634(0x132)](); return; } if (TouchInput[_0x12b634(0x121)]() && this[_0x12b634(0x16c)]()) this['_isSelected'] ? this['touchEvent']() : $gameScrollBar[_0x12b634(0x170)](this); else this[_0x12b634(0x1a6)] && !$gameMap['isEventRunning']() && (this[_0x12b634(0x136)](_0x12b634(0x142), -0x1), this[_0x12b634(0x136)](_0x12b634(0x183), 0x1)); _0x3d9d8c !== this[_0x12b634(0x14b)] && (this[_0x12b634(0x114)]['x'] = this[_0x12b634(0x13a)](this['_value'])), this['updateChildren'](); } [_0x13b2ca(0x132)]() { const _0x1b6917 = _0x13b2ca; Object[_0x1b6917(0x1a4)](this[_0x1b6917(0x147)])['forEach'](_0x883b81 => { const _0x1b91c2 = _0x1b6917; _0x883b81[_0x1b91c2(0x192)](this[_0x1b91c2(0x14b)]); }); } ['touchEvent']() { const _0x317953 = _0x13b2ca; TouchInput[_0x317953(0x14a)]() ? this['_pinchSprite']['x'] = this[_0x317953(0x13a)](this['_value']) : this[_0x317953(0x114)]['x'] = Math['min'](Math[_0x317953(0x10c)](0x0, TouchInput['x'] - this['x']), this[_0x317953(0x172)]); const _0x553929 = this['toNumber'](); this[_0x317953(0x16e)] !== _0x553929 && (TouchInput[_0x317953(0x14a)]() || TouchInput['isRepeated']()) && this['_triggerCommonEvent'](_0x553929); if (this[_0x317953(0x14b)] === _0x553929) return; $gameVariables[_0x317953(0x10a)](this[_0x317953(0x130)], _0x553929), this[_0x317953(0x14b)] = _0x553929; } [_0x13b2ca(0x126)](_0x29f602) { const _0x37c9cc = _0x13b2ca; this[_0x37c9cc(0x17b)] && ($gameTemp['reserveCommonEvent'](this['_commonEventNumber']), this[_0x37c9cc(0x16e)] = _0x29f602); } [_0x13b2ca(0x111)](_0x3845d4) { const _0x1f69bc = _0x13b2ca; if (!this['_enabled']) return; this[_0x1f69bc(0x188)] = _0x3845d4, this[_0x1f69bc(0x139)] = _0x3845d4, _0x3845d4 === !![] && this[_0x1f69bc(0x192)](); } [_0x13b2ca(0x117)](_0x231f74) { this['_isSelected'] = _0x231f74; } [_0x13b2ca(0x17c)](_0x26427d) { const _0x24da4a = _0x13b2ca; _0x26427d && (this[_0x24da4a(0x157)] = null); } [_0x13b2ca(0x185)]() { const _0x5e5e84 = _0x13b2ca; this[_0x5e5e84(0x152)] = ![]; if (!this['_graphics']) return; this[_0x5e5e84(0x188)] = ![], this[_0x5e5e84(0x139)] = ![], this['destroy']({ 'children': !![] }), this[_0x5e5e84(0x120)] = null, this[_0x5e5e84(0x114)] = null, this['_barText'] = {}; } ['updateTextBar'](_0x2ad730, _0x1e9912, _0x28ccda) { const _0x52a239 = _0x13b2ca; let _0x5030bd = this[_0x52a239(0x147)][_0x1e9912]; const _0x25b375 = _0x56d26c['make'](_0x1e9912, this['_barWidth'], _0x3cf492); if (_0x5030bd) { _0x5030bd[_0x52a239(0x182)](_0x28ccda, _0x25b375, this[_0x52a239(0x172)]); return; } _0x5030bd = new _0x1e7250(), this['_barText'][_0x1e9912] = _0x5030bd, this[_0x52a239(0x198)](_0x5030bd[_0x52a239(0x182)](_0x28ccda, _0x25b375, this['_barWidth'])); } [_0x13b2ca(0x16c)]() { const _0x32a70f = _0x13b2ca, _0x32fe92 = TouchInput['x'], _0x26492c = TouchInput['y']; return _0x32fe92 >= this['x'] && _0x32fe92 <= this['x'] + this[_0x32a70f(0x172)] && _0x26492c >= this['y'] && _0x26492c <= this['y'] + _0x3cf492; } } class _0x52c2d5 { constructor(_0x416ac2, _0x559495, _0x4b68fa) { const _0x107464 = _0x13b2ca; this[_0x107464(0x172)] = _0x416ac2, this[_0x107464(0x149)] = _0x559495, this['_interval'] = Number(_0x4b68fa) || 0x0; } set [_0x13b2ca(0x15f)](_0x11ab5c) { const _0x4d2590 = _0x13b2ca; this[_0x4d2590(0x145)] = Math[_0x4d2590(0x10c)](0x0, _0x11ab5c); } [_0x13b2ca(0x192)](_0x4361f9, _0x48813a) { const _0x376e89 = _0x13b2ca; if (!this[_0x376e89(0x145)]) return; const _0x315c39 = _0x48813a[_0x376e89(0x19a)]; for (let _0xd05723 = this[_0x376e89(0x145)]; _0xd05723 < this[_0x376e89(0x149)]; _0xd05723 += this['_interval']) { const _0x241827 = Math[_0x376e89(0x148)](this[_0x376e89(0x172)] / this[_0x376e89(0x149)] * _0xd05723); _0x4361f9[_0x376e89(0x181)](_0x241827, 0x0), _0x4361f9[_0x376e89(0x13e)](0x1, _0x315c39), _0x4361f9['lineTo'](_0x241827, _0x3cf492); } _0x4361f9[_0x376e89(0x13e)](); } static ['make'](_0x222f05, _0x5e41da) { return new _0x52c2d5(_0x222f05, _0x5e41da); } } class _0x56d26c { constructor(_0x58efbf, _0x36021c, _0x479328) { const _0x381819 = _0x13b2ca; this[_0x381819(0x1a0)] = _0x58efbf, this[_0x381819(0x159)] = _0x36021c, this[_0x381819(0x144)] = _0x479328; } ['toPosition'](_0x5dd5ee, _0x565075) { const _0x1ddee0 = _0x13b2ca; return { 'x': _0x5dd5ee * this[_0x1ddee0(0x159)], 'y': _0x565075 * this[_0x1ddee0(0x1a0)] }; } static ['make'](_0x43b060, _0x106d3f, _0x2ae609) { const _0x360a20 = _0x13b2ca; switch (_0x43b060) { case 'lt': return new _0x56d26c(-1.3, 0x0, 'left'); case 'rt': return new _0x56d26c(-1.3, 0x0, _0x360a20(0x183)); case 'r': return new _0x56d26c(0x0, 0x1 + _0x2ae609 / _0x106d3f, _0x360a20(0x142)); case 'l': return new _0x56d26c(0x0, -0x1 - _0x2ae609 / _0x106d3f, _0x360a20(0x183)); default: break; } } } class _0x1d705c { constructor(_0x599cbe, _0x4773df) { this['_x'] = _0x599cbe, this['_y'] = _0x4773df; } [_0x13b2ca(0x164)]() { return { 'x': this['_x'], 'y': this['_y'] }; } } class _0x1e7250 { ['initialize'](_0x29e18b, _0x3dc23a, _0x16234e) { const _0x2a1b0e = _0x13b2ca; this[_0x2a1b0e(0x163)] = _0x3dc23a, this[_0x2a1b0e(0x160)] = _0x29e18b; if (this[_0x2a1b0e(0x190)]) { const _0xbde6f1 = _0x3dc23a[_0x2a1b0e(0x164)](_0x16234e, 0x18); return this[_0x2a1b0e(0x190)]['y'] = _0xbde6f1['y'], this[_0x2a1b0e(0x190)]['x'] = _0xbde6f1['x'], this[_0x2a1b0e(0x190)]; } return this[_0x2a1b0e(0x133)](_0x16234e, _0x3dc23a); } [_0x13b2ca(0x133)](_0x150843, _0x580a50) { const _0x2bbdb3 = _0x13b2ca, _0x5dc894 = new Sprite(new Bitmap(_0x150843, 0x20)); _0x5dc894[_0x2bbdb3(0x1a7)]['fontSize'] = 0x18; const _0x4a1b5a = _0x580a50[_0x2bbdb3(0x164)](_0x150843, 0x18); return _0x5dc894['y'] = _0x4a1b5a['y'], _0x5dc894['x'] = _0x4a1b5a['x'], this['_textSprite'] = _0x5dc894, _0x5dc894; } [_0x13b2ca(0x192)]() { const _0x329128 = _0x13b2ca; this[_0x329128(0x15d)](this[_0x329128(0x160)]); } [_0x13b2ca(0x15d)](_0x5e653b) { const _0x33a118 = _0x13b2ca; this[_0x33a118(0x190)]['bitmap'][_0x33a118(0x185)](); if (_0x5e653b == null || _0x5e653b === '') return; const _0x1b319c = SceneManager['_scene'][_0x33a118(0x131)][_0x33a118(0x128)][0x0], _0x222918 = _0x1b319c ? _0x1b319c[_0x33a118(0x173)](_0x5e653b) : _0x5e653b; this[_0x33a118(0x190)][_0x33a118(0x1a7)][_0x33a118(0x13d)](_0x222918, 0x0, 0x0, this[_0x33a118(0x190)][_0x33a118(0x1a7)][_0x33a118(0x197)], 0x20, this['_position']['align']); } } let _0x1f4dd9 = Game_Temp['prototype']['initialize']; Game_Temp[_0x13b2ca(0x165)][_0x13b2ca(0x182)] = function () { const _0x8b4e2c = _0x13b2ca; _0x1f4dd9[_0x8b4e2c(0x135)](this), window['$gameScrollBar'] = new _0x5abc29(); }; let _0x4bcfab = Game_Variables[_0x13b2ca(0x165)][_0x13b2ca(0x1a5)]; Game_Variables[_0x13b2ca(0x165)][_0x13b2ca(0x1a5)] = function () { const _0x44d344 = _0x13b2ca; _0x4bcfab[_0x44d344(0x135)](this), $gameParty['inBattle']() && window[_0x44d344(0x155)]['update'](); }; let _0x59a115 = Game_Map[_0x13b2ca(0x165)][_0x13b2ca(0x14c)]; Game_Map[_0x13b2ca(0x165)]['refresh'] = function () { const _0x438a5c = _0x13b2ca; _0x59a115['call'](this), window[_0x438a5c(0x155)][_0x438a5c(0x192)](); }; let _0xfcbfad = Scene_Map[_0x13b2ca(0x165)][_0x13b2ca(0x123)]; Scene_Map[_0x13b2ca(0x165)][_0x13b2ca(0x123)] = function () { const _0x215007 = _0x13b2ca; if (!SceneManager[_0x215007(0x18d)](Scene_Battle)) $gameScrollBar['allRemoveScene'](); _0xfcbfad[_0x215007(0x135)](this); }; let _0x507e3c = Scene_Map[_0x13b2ca(0x165)][_0x13b2ca(0x11c)]; Scene_Map[_0x13b2ca(0x165)][_0x13b2ca(0x11c)] = function () { const _0x14222d = _0x13b2ca; _0x507e3c[_0x14222d(0x135)](this), !this[_0x14222d(0x187)] && $gameScrollBar[_0x14222d(0x10f)](); }; function _0x29a4f7(_0x2be2f0) { return function () { const _0x46085e = a0_0x1ce6; _0x2be2f0['apply'](this, arguments), $gameScrollBar[_0x46085e(0x182)](); }; } Scene_Map[_0x13b2ca(0x165)]['createDisplayObjects'] = _0x29a4f7(Scene_Map[_0x13b2ca(0x165)][_0x13b2ca(0x124)]), Scene_Battle[_0x13b2ca(0x165)]['createSpriteset'] = _0x29a4f7(Scene_Battle[_0x13b2ca(0x165)][_0x13b2ca(0x153)]), Scene_Menu[_0x13b2ca(0x165)]['start'] = _0x29a4f7(Scene_Menu['prototype']['start']); class _0x530207 extends Sprite { [_0x13b2ca(0x141)]() { const _0x14ba21 = _0x13b2ca; return (this[_0x14ba21(0x197)] || 0x0) * this[_0x14ba21(0x196)]['x']; } [_0x13b2ca(0x16b)]() { const _0x5c6350 = _0x13b2ca; return (this[_0x5c6350(0x179)] || 0x0) * this[_0x5c6350(0x196)]['y']; } ['screenX']() { const _0x179d41 = _0x13b2ca; return (this[_0x179d41(0x10b)]['x'] + this['x'] || 0x0) - this[_0x179d41(0x171)]['x'] * this[_0x179d41(0x141)](); } [_0x13b2ca(0x13c)]() { const _0x5dee28 = _0x13b2ca; return (this['parent']['y'] + this['y'] || 0x0) - this[_0x5dee28(0x171)]['y'] * this[_0x5dee28(0x16b)](); } [_0x13b2ca(0x199)](_0x3e334b) { const _0x2bbb9a = _0x13b2ca, _0x50c5dd = this['screenWidth']() * (_0x3e334b ? 0xa : 0x1), _0x179c95 = this[_0x2bbb9a(0x140)](); return Math[_0x2bbb9a(0x14f)](_0x179c95, _0x179c95 - _0x50c5dd); } ['minY'](_0x532857) { const _0xd7fb4 = _0x13b2ca, _0x5210a4 = this['screenHeight']() * (_0x532857 ? 0x3 : 0x1), _0x1a3c99 = this[_0xd7fb4(0x13c)](); return Math[_0xd7fb4(0x14f)](_0x1a3c99, _0x1a3c99 - _0x5210a4); } [_0x13b2ca(0x143)](_0x451739) { const _0x104b5d = _0x13b2ca, _0x49169f = this[_0x104b5d(0x141)]() * (_0x451739 ? 0xa : 0x1), _0x198a9d = this[_0x104b5d(0x140)](); return Math[_0x104b5d(0x10c)](_0x198a9d, _0x198a9d + _0x49169f); } [_0x13b2ca(0x129)](_0x50fd95) { const _0xf6f85a = _0x13b2ca, _0x114d9c = this[_0xf6f85a(0x16b)]() * (_0x50fd95 ? 0x3 : 0x1), _0x49890e = this['screenY'](); return Math[_0xf6f85a(0x10c)](_0x49890e, _0x49890e + _0x114d9c); } [_0x13b2ca(0x16c)](_0x526382) { const _0x11ee72 = _0x13b2ca, _0x198d45 = TouchInput['x'], _0x111c84 = TouchInput['y']; return _0x198d45 >= this[_0x11ee72(0x199)](_0x526382) && _0x198d45 <= this['maxX'](_0x526382) && _0x111c84 >= this[_0x11ee72(0x18e)](_0x526382) && _0x111c84 <= this['maxY'](_0x526382); } [_0x13b2ca(0x121)]() { const _0xfd901d = _0x13b2ca; let _0xdf699 = TouchInput[_0xfd901d(0x121)](), _0x498fb0 = TouchInput[_0xfd901d(0x12d)](), _0xeeeb3b = TouchInput[_0xfd901d(0x14a)](), _0x32db66 = TouchInput[_0xfd901d(0x16f)](); return (_0xdf699 || _0x498fb0 || _0xeeeb3b || _0x32db66) && this[_0xfd901d(0x16c)](_0x498fb0 || _0xeeeb3b || _0x32db66); } } }())); |