查看: 5027|回复: 2

[有事请教] 求问可否在开始游戏时判断是否使用某个插件

[复制链接]
梦石
3
星屑
363
在线时间
217 小时
注册时间
2015-2-4
回帖
81
发表于 2018-2-21 14:48:11 | 显示全部楼层 |阅读模式
悬赏20星屑已解决
想请教一下各位dalao……想在打开游戏的时候根据是否有存档来判断一个插件使不使用……
实际效果是在使用yami_skiptitle的时候,想一开始打开游戏时跳过标题画面的直接显示序幕,在序幕过了以后并且有存档过,下次打开游戏的时候进入正常标题界面……
十分感谢

以下是插件本身的代码

点击展开/收起
/*:
* @plugindesc Skip the title scene for testing purpose.
* @version 1.0
*/

(function() {

    Scene_Boot.prototype.start = function() {
        Scene_Base.prototype.start.call(this);
        SoundManager.preloadImportantSounds();
        if (DataManager.isBattleTest()) {
            DataManager.setupBattleTest();
            SceneManager.goto(Scene_Battle);
        } else {
            this.checkPlayerLocation();
            DataManager.setupNewGame();
            SceneManager.goto(Scene_Map);
        }
        this.updateDocumentTitle();
    };

})();

最佳答案

梦石
0
星屑
34462
在线时间
5096 小时
注册时间
2012-11-19
回帖
4715

开拓者

发表于 2018-2-21 14:48:12 | 显示全部楼层
这样?

  1. /*:
  2. * @plugindesc Skip the title scene for testing purpose.
  3. * @version 1.0
  4. */

  5. (function() {

  6.     Scene_Boot.prototype.start = function() {
  7.         Scene_Base.prototype.start.call(this);
  8.         SoundManager.preloadImportantSounds();
  9.         if (DataManager.isBattleTest()) {
  10.             DataManager.setupBattleTest();
  11.             SceneManager.goto(Scene_Battle);
  12.         } else {
  13.             this.checkPlayerLocation();
  14.             DataManager.setupNewGame();
  15.             SceneManager.goto(DataManager.isAnySavefileExists() ? Scene_Title : Scene_Map);
  16.         }
  17.         this.updateDocumentTitle();
  18.     };

  19. })();
复制代码
xp vx va mv  va mz 各类型脚本/插件定制
回复

使用道具 举报

梦石
3
星屑
363
在线时间
217 小时
注册时间
2015-2-4
回帖
81
 楼主| 发表于 2018-2-21 20:30:28 | 显示全部楼层

十分感谢!
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册会员

本版积分规则

Powered by Discuz! X5.0 © 2001-2026 Discuz! Team.

在本版发帖返回顶部