tale

Volunteer
Veteran
Joined
Dec 16, 2016
Messages
828
Reaction score
1,444
First Language
English
Primarily Uses
N/A
SaveBGS - 2018/06/19 (Ver.1.0)

Creator name: kido0617

Overview
Able to save or resume BGS with a plugin command

Features
- It's possible to save/ replay BGS
- Short code

Plugin Command-
To save BGS
Code:
SaveBGS

Resume BGS
Code:
ReplayBGS

Plugin preview-
Code:
/*---------------------------------------------------------------------------*
 * 2018/06/19 kido0617
 * http://kido0617.github.io/
 * Public Domain
 * Please use freely, credit not necessary
 * Ver.1.0
 *---------------------------------------------------------------------------*/

/*:
 * @plugindesc Able to save or resume BGS with a plugin command
 * @author kido0617
 * @help
 * Plugin Command
 *  ・To save BGS
 *     SaveBGS
 *  ・Resume BGS
 *     ReplayBGS
 *
*/


(function(){

  var _Game_Interpreter_pluginCommand = Game_Interpreter.prototype.pluginCommand;
  Game_Interpreter.prototype.pluginCommand = function(command, args) {
    _Game_Interpreter_pluginCommand.call(this, command, args);
    if (command === 'SaveBGS') {
      $gameSystem.saveBgs();
    }else if(command === 'ReplayBGS'){
      $gameSystem.replayBgs();
    }
  };

  Game_System.prototype.saveBgs = function() {
    this._savedBgs = AudioManager.saveBgs();
  };

  Game_System.prototype.replayBgs = function() {
    if (this._savedBgs) {
      AudioManager.replayBgs(this._savedBgs);
    }
  };

})();

Credit and Thanks: kido0617

Terms of Use- Free for commercial and non-commercial use.

License - Public Domain

You can download js file from the thread attachment or Dropbox link: https://www.dropbox.com/s/ycgwv73nb9o4pgr/SaveBGS.js?dl=1
 

Attachments

  • SaveBGS.js
    1.1 KB · Views: 14
Last edited:

ScorchedGround

Blizzards most disappointed fan (More than ever)
Veteran
Joined
Apr 12, 2020
Messages
576
Reaction score
794
First Language
German
Primarily Uses
RMMV
Thank you for this.

I was astonished to see that this was not a feature by default.
 

Latest Threads

Latest Posts

Latest Profile Posts

Made a Mapping Tutorial on Adding Lighting/Shadows using Tileset

Currently working on a playlist of songs that have inspired my work on revamping Battle Castle, and making sure they flow decently from one to the next. I will be posting it whenever I upload my next demo.
This is the first song in the playlist.
Artists out there, is there something RPG maker related you wish your graphics software had but doesn't? (Something like automatically transform a wall tile into a cylindrical tower). I want to give a boost to WecTools, but I'm dry of ideas right now...

Forum statistics

Threads
113,911
Messages
1,078,352
Members
148,014
Latest member
Kenu
Top