Disable 'Fast Forward' during movies?

AdamSakuru

[Null_Value]
Veteran
Joined
Mar 14, 2014
Messages
314
Reaction score
171
First Language
English
Primarily Uses
N/A
A couple of days ago I discovered the 'fast forward' feature that would speed up the game/events if you held down the space-bar/'accept' key (even during move routes/etc. without messages)

But there is a problem. If you play a movie file and set the appropriate wait time in frames, you can still hold space to fast forward through the wait frames. I don't want to disable the feature entirely, but is there a way to disable it while a movie is playing? Holding down the space key allows the player to throw the wait time off and continue through the post movie events while the movie is still playing.
 

Kyo Panda

Veteran
Veteran
Joined
May 16, 2017
Messages
34
Reaction score
24
First Language
Portuguese
Primarily Uses
RMMV
Looks like the internal Game_Interpreter's wait count gets messed up with the double update per tick of Scene_Map's fast forward. This causes the wait to end twice as fast as it should, prematurely progressing with Game_Interpreter's command list.

That being said, the problem isn't only with videos, but with anything that sets a wait timer on Interpreter, like transitions or the wait command.

Code:
/*:
 * @plugindesc
 * Fix the Game_Interpreter's internal wait count when the map is in
 * fast forward mode.
 *
 * @help
 *
 * MIT License
 *
 * Copyright (c) 2017 Kyo Panda
 *
 * Permission is hereby granted, free of charge, to any person obtaining
 * a copy of this software and associated documentation files (the
 * "Software"), to deal in the Software without restriction, including
 * without limitation the rights to use, copy, modify, merge, publish,
 * distribute, sublicense, and/or sell copies of the Software, and to
 * permit persons to whom the Software is furnished to do so, subject to
 * the following conditions:
 *
 * The above copyright notice and this permission notice shall be
 * included in all copies or substantial portions of the Software.
 *
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
 * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
 * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
 * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
 * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
 * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 */

/*:pt
 * @plugindesc
 * Corrige o contador interno do Game_Interpreter quando o mapa está em
 * modo de velocidade rápida.
 *
 * @author Kyo Panda
 *
 * @help
 *
 * MIT License
 *
 * Copyright (c) 2017 Kyo Panda
 *
 * Permission is hereby granted, free of charge, to any person obtaining
 * a copy of this software and associated documentation files (the
 * "Software"), to deal in the Software without restriction, including
 * without limitation the rights to use, copy, modify, merge, publish,
 * distribute, sublicense, and/or sell copies of the Software, and to
 * permit persons to whom the Software is furnished to do so, subject to
 * the following conditions:
 *
 * The above copyright notice and this permission notice shall be
 * included in all copies or substantial portions of the Software.
 *
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
 * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
 * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
 * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
 * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
 * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 */

(function() {
    'use strict';
  
    Game_Map.prototype.updateFastForward = function() {
        this._interpreter.incrementWaitCount();
    };

    Game_Interpreter.prototype.incrementWaitCount = function() {
        if (this._waitCount > 0) {
            this._waitCount++;
        }
    };

    var _Scene_Map_updateMainMultiply = Scene_Map.prototype.updateMainMultiply;

    Scene_Map.prototype.updateMainMultiply = function() {
        if (this.isFastForward()) {
            $gameMap.updateFastForward();
        };
      
        _Scene_Map_updateMainMultiply.apply(this, arguments);
    };
}());
Here is tiny fix.
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

OcRam demo project is now available at https://ocram-codes.net !!!
mzBaseBody.png added!

Ami
--- Mushroom ---

F.Knight: We runs out the food!
Hero: Anything could eat in this place?
F.Archer: It's a bunch of Mushroom over there. I wonder it's safe to eat.
F.Knight: No worries,we have to fill our inside no matter what it is.
(Hero & F.Knight Eat The Mushroom,After 10 Seconds They Collapse With Foam)
I hope I'm not the only one super excited about the Minecraft Live broadcast on Friday! (At least, Friday for me) I'm planning to catch it because I need to get my vote in there and add a mob to the game! I hope I'll see some of you there!
Hyptosis wrote on Sharm's profile.
Whoa, was browsing the forum and stumbled onto you account! Big fan of your work!

Forum statistics

Threads
103,442
Messages
999,329
Members
134,976
Latest member
Ulrick-Deamon
Top