Advertisement
Guest User

Anima_OpenSceneCommand.js

a guest
Nov 25th, 2015
90
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. /*=============================================================================
  2.  * Anima - Open Scene Command
  3.  * By Liquidize - www.mintkit.lol
  4.  * Anima_OpenSceneCommand.js
  5.  * Version: 1.0
  6.  * Free for commercial/non-commercial use, Credit Liquidize or the
  7.  * "Anima Framework".
  8.  *=============================================================================*/
  9. /*:
  10.  * @plugindesc Plugin Description <Anima_OpenSceneCommand>
  11.  * @author Liquidize
  12.  * @help
  13.  *
  14.  * Use the following plugin commands to open their respective scenes.
  15.  *
  16.  * SceneSkill = Skill Scene
  17.  * SceneItem = Item Scene
  18.  * SceneEquip = Equipment Scene
  19.  * SceneOptions = Options Scene
  20.  * SceneEnd = Game End Scene
  21.  * SceneStatus = Status Scene
  22.  * SceneSave = Save Scene
  23.  *
  24.  * ============================================================================
  25.  * The Anima Framework
  26.  * ============================================================================
  27.  * What is it? It's a series of plugins, a 'framework' if you will, developed by
  28.  * as a part of my contribution to the RPG Maker MV community. The
  29.  * plugin contained within this framework are plugins that are derived
  30.  * from the plugin request forums at RPGMakerWeb. They are requests that have been
  31.  * found interesting/unique or potentially fun to make so I went ahead and made them.
  32.  * Anyone is free to use these in any project provided that credit is given.
  33.  * You are free to suggest improvements, features, suggestions, or whole plugins.
  34.  * If I like them, or its a popular request, I will add them to my list.
  35.  *
  36.  * Check out my website:
  37.  * http://mintkit.lol
  38.  *
  39.  * ============================================================================
  40.  * Change Log
  41.  * ============================================================================
  42.  *
  43.  *
  44.  * Version 1.0:
  45.  *            - Finished Script!
  46.  *
  47.  *=============================================================================*/
  48. var Imported = Imported || {};
  49. var Anima = Anima || {};
  50. Anima.OpenSceneCommand = Anima.OpenSceneCommand || {};
  51.  
  52. (function ($) {
  53.     "use strict";
  54.  
  55.     var parameters = $plugins.filter(function (plugin) {
  56.         return plugin.description.contains('<Anima_OpenSceneCommand>');
  57.     });
  58.     if (parameters.length === 0) {
  59.         throw new Error("Couldn't find Liquidize's Anima_OpenSceneCommand parameters.");
  60.     }
  61.     $.Parameters = parameters[0].parameters;
  62.     $.Param = {};
  63.  
  64.     var openSceneCommandGameInterpreter_pluginCommand = Game_Interpreter.prototype.pluginCommand;
  65.     Game_Interpreter.prototype.pluginCommand = function(command, args) {
  66.  
  67.         if (command === "SkillScene"){
  68.          SceneManager.push(Scene_Skill);
  69.         } else if (command === "SceneItem") {
  70.           SceneManager.push(Scene_Item);
  71.         } else if (command === "SceneEquip"){
  72.             SceneManager.push(Scene_Equip);
  73.         } else if (command === "SceneStatus"){
  74.             SceneManager.push(Scene_Status);
  75.         } else if (command === "SceneOptions"){
  76.             SceneManager.push(Scene_Options)
  77.         } else if(command === "SceneSave"){
  78.             SceneManager.push(Scene_Save);
  79.         } else if (command === "SceneEnd"){
  80.             SceneManager.push(Scene_GameEnd);
  81.         }else
  82.          {
  83.             openSceneCommandGameInterpreter_pluginCommand.call(this, command, args);
  84.         }
  85.     };
  86.  
  87.  
  88. })(Anima.OpenSceneCommand);
  89.  
  90. OpenSceneCommand = Anima.OpenSceneCommand;
  91. Imported["Anima_OpenSceneCommand"] = 1.0;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement