File tree Expand file tree Collapse file tree 2 files changed +28
-1
lines changed Expand file tree Collapse file tree 2 files changed +28
-1
lines changed Original file line number Diff line number Diff line change @@ -57,6 +57,8 @@ Window_Message.prototype.clearFlags = function() {
5757 this . _showFast = false ;
5858 this . _lineShowFast = false ;
5959 this . _pauseSkip = false ;
60+ this . _textSpeed = 0 ;
61+ this . _textSpeedCount = 0 ;
6062} ;
6163
6264Window_Message . prototype . numVisibleRows = function ( ) {
@@ -176,8 +178,13 @@ Window_Message.prototype.updateMessage = function() {
176178 this . newPage ( this . _textState ) ;
177179 }
178180 this . updateShowFast ( ) ;
181+ if ( ! this . _showFast && ! this . _lineShowFast && this . _textSpeedCount < this . _textSpeed ) {
182+ this . _textSpeedCount ++ ;
183+ break ;
184+ }
185+ this . _textSpeedCount = 0 ;
179186 this . processCharacter ( this . _textState ) ;
180- if ( ! this . _showFast && ! this . _lineShowFast ) {
187+ if ( ! this . _showFast && ! this . _lineShowFast && this . _textSpeed !== - 1 ) {
181188 break ;
182189 }
183190 if ( this . pause || this . _waitCount > 0 ) {
@@ -313,6 +320,9 @@ Window_Message.prototype.processEscapeCharacter = function(code, textState) {
313320 case '^' :
314321 this . _pauseSkip = true ;
315322 break ;
323+ case 'S' :
324+ this . _textSpeed = this . obtainEscapeParam ( textState ) - 1 ;
325+ break ;
316326 default :
317327 Window_Base . prototype . processEscapeCharacter . call ( this , code , textState ) ;
318328 break ;
Original file line number Diff line number Diff line change 4242 * @desc The initial value whether the player always dashes (on/off)
4343 * @default false
4444 *
45+ * @param textSpeed
46+ * @type number
47+ * @desc The text speed on "Show Text". The larger this parameter is, the slower text speed. (0: show all texts at once)
48+ * @default 1
49+ *
4550 * @param autoSaveFileId
4651 * @type number
4752 * @desc The file number to auto save when "Transfer Player" (0: off)
97102 * @desc プレイヤーが常時ダッシュするかどうかの初期値 (on/off)
98103 * @default false
99104 *
105+ * @param textSpeed
106+ * @type number
107+ * @text 「文章の表示」のスピード
108+ * @desc 数字が大きいほど文章の表示スピードが遅くなります (0を指定した場合は一度に全文を表示します)
109+ * @default 1
110+ *
100111 * @param autoSaveFileId
101112 * @type number
102113 * @desc 「場所移動」の際にオートセーブするファイル番号 (0でoff)
124135 var screenHeight = toNumber ( parameters [ 'screenHeight' ] , 624 ) ;
125136 var renderingMode = parameters [ 'renderingMode' ] . toLowerCase ( ) ;
126137 var alwaysDash = parameters [ 'alwaysDash' ] . toLowerCase ( ) === 'true' ;
138+ var textSpeed = toNumber ( parameters [ 'textSpeed' ] , 1 ) ;
127139 var windowWidthTo = toNumber ( parameters [ 'changeWindowWidthTo' ] , 0 ) ;
128140 var windowHeightTo = toNumber ( parameters [ 'changeWindowHeightTo' ] , 0 ) ;
129141 var autoSaveFileId = toNumber ( parameters [ 'autoSaveFileId' ] , 0 ) ;
173185 }
174186 } ;
175187
188+ var _Window_Message_clearFlags = Window_Message . prototype . clearFlags ;
189+ Window_Message . prototype . clearFlags = function ( textState ) {
190+ _Window_Message_clearFlags . apply ( this , arguments ) ;
191+ this . _textSpeed = textSpeed - 1 ;
192+ } ;
176193
177194 var _SceneManager_initNwjs = SceneManager . initNwjs ;
178195 SceneManager . initNwjs = function ( ) {
You can’t perform that action at this time.
0 commit comments