RPG Maker MV

RPG Maker MV

Pausing Picture Movement
This is going to be a unique problem to solve, if anyone is interested. I've got a sport's simulation style RPG going in the battle system, and a picture of a ball shows on the screen and it moves according to the action.

Now, using the ATB system from Yanfly, this works well as long as all parties are in auto-battle mode, but one of the characters cannot be in autobattle, so the game has to open up to player menu so the player can choose their abilities. Ideally, I would like it if when the player menu pops up, the ball image pauses moving too as the rest of the action pauses (the ATB bars) it just looks better if the ball also paused (its movement and rotation). If it paused while the player chooses a skill and then resumes to the location it was moving towards before that would look really great.

So to summarize, I have an event that moves the ball throughout a battle. I would like the ball to pause moving and rotating upon player turn in which they choose a skill and for the ball to resume its original movement and rotation after the player finished selecting their skill.

I'm not expecting much, but if someone would just give me their thoughts as to whether this is even possible or not, it would be much appreciated.
< >
Showing 1-6 of 6 comments
Dusk_Army Oct 1, 2021 @ 2:21pm 
So, fair warning: I don't know if what you're looking for is possible or not. I think it probably is, but I don't really know how to do it. The best I can give you is to try looking at script calls and (maybe) writing a custom plugin for this, because your situation is a bit out of the normal scope of the engine.

But logic dictates that what you want should still be possible; after all, you can start the animation in the first place, and obviously it stops at some point, too. You just need to call some kind of function at the beginning of the player's turn to make it stop, then resume at the end of their turn.
Caethyril Oct 2, 2021 @ 11:43am 
I think this would skip all picture updates while switch 1 is on (untested):
/*: * @plugindesc Freeze all pictures when switch 1 is on. * @help Free to use and/or modify for any project. */ (function(alias) { Game_Picture.prototype.update = function() { if (!$gameSwitches.value(1)) alias.apply(this, arguments); }; })(Game_Picture.prototype.update);
Plaintext to plugin instructions:
  1. Copy + paste the code into a text editor (e.g. Notepad).
  2. File > Save As:
    • File Type: All Files
    • Filename: whatever.js
    (This works because .js files are plaintext.)
  3. Import that file as a plugin.
  4. Save your project to apply Plugin Manager changes.
  5. Test!
Soul Love Base Oct 2, 2021 @ 6:25pm 
Originally posted by Caethyril:
I think this would skip all picture updates while switch 1 is on (untested):

Hi again and thanks for helping me out once more. I tested the script by turning on a switch during the battle and the images did stop moving and resumed after the switch turned back off. However, I am not sure how to have the switch turn on right at the beginning of a player's turn once the Window_Battleskill opens up once the player's ATB gauge (Using Yanfly's ATB battle script) has filled up. Do you have any idea how that could be done?
Caethyril Oct 3, 2021 @ 4:38am 
Oh, whoops. Try replacing this part:
if (!$gameSwitches.value(1))
...with this:
if (BattleManager._phase !== 'input')
I.e. update pictures iff it's not the battle input phase (selecting actions).
Soul Love Base Oct 3, 2021 @ 5:12am 
Fantastic! Turns out I needed the switch version too so that I could also pause the movement during the common events used in the abilities! This seemingly small difference actually makes the game look and feel a lot better. Thanks a lot!
Last edited by Soul Love Base; Oct 3, 2021 @ 5:13am
Caethyril Oct 3, 2021 @ 5:46am 
Great! Happy RPG Making~ ^_^
< >
Showing 1-6 of 6 comments
Per page: 1530 50

Date Posted: Sep 30, 2021 @ 2:13am
Posts: 6