ページ 11

【解決済み】Atelier RGSS様「monogatari」とGalv様の「MagicShards」の競合について

Posted: 2017年10月16日(月) 14:25
by T.C.
いつもお世話になります。
トピック立てはこちらでよろしいでしょうか。

表題の通り、私はAtelier RGSS様の「monogatari」と、Galv様の「MagicShards」を
同時に導入しているのですが、「MagicShards」のシーンに遷移する際に、画像のような
エラーが発生してしまいます。

これは、何かが競合しているということなのでしょうか?
同時に使うためには、どうすればよろしいでしょうか。

ご回答、よろしくお願いいたします。

Re: Atelier RGSS様「monogatari」とGalv様の「MagicShards」の競合について

Posted: 2017年10月16日(月) 14:46
by ツミオ
こんにちは。
必要な設定が多そうなので実際に直るかどうか試していませんが、MOG_SceneEquip.jsの484行目あたりを以下のように置き換えてみてください。

コード: 全て選択

//==============================
// * update
//==============================
var _mog_scnEquipUpdate = Window_EquipStatus.prototype.update;
Window_EquipStatus.prototype.update = function() {
	_mog_scnEquipUpdate.call(this);
	if(this._faceSprite){
		this._faceSprite.opacity = this.contentsOpacity;
	}
};

Re: Atelier RGSS様「monogatari」とGalv様の「MagicShards」の競合について

Posted: 2017年10月16日(月) 15:55
by T.C.
>ツミオ様

迅速な対応ありがとうございます!

シーン自体には遷移しました!

ただ、パラメータの名称が表示されない状態になっています。

これはどうすればよろしいでしょうか。

よろしくお願いいたします。

Re: Atelier RGSS様「monogatari」とGalv様の「MagicShards」の競合について

Posted: 2017年10月16日(月) 16:25
by ツミオ
うーん、そうですね。
MOG系の方でWindow_EquipStatusを完全に上書きしてしまっているようなので、ちょっとややこしいです。
少し不細工になりますが、以下のように改変するのはいかがでしょうか。

まずGALV~.jsの1200行目あたりに移動します。
すると以下のようなコードが見つかると思います。

コード: 全て選択

//-----------------------------------------------------------------------------
// Windows
//-----------------------------------------------------------------------------
この直下に以下のコードを貼り付けます(ほぼコアスクリプトのコピペです)。

コード: 全て選択

//-----------------------------------------------------------------------------
// Window_EquipStatusForGALV
//

function Window_EquipStatusForGALV() {
    this.initialize.apply(this, arguments);
}

Window_EquipStatusForGALV.prototype = Object.create(Window_Base.prototype);
Window_EquipStatusForGALV.prototype.constructor = Window_EquipStatusForGALV;

Window_EquipStatusForGALV.prototype.initialize = function(x, y) {
    var width = this.windowWidth();
    var height = this.windowHeight();
    Window_Base.prototype.initialize.call(this, x, y, width, height);
    this._actor = null;
    this._tempActor = null;
    this.refresh();
};

Window_EquipStatusForGALV.prototype.windowWidth = function() {
    return 312;
};

Window_EquipStatusForGALV.prototype.windowHeight = function() {
    return this.fittingHeight(this.numVisibleRows());
};

Window_EquipStatusForGALV.prototype.numVisibleRows = function() {
    return 7;
};

Window_EquipStatusForGALV.prototype.setActor = function(actor) {
    if (this._actor !== actor) {
        this._actor = actor;
        this.refresh();
    }
};

Window_EquipStatusForGALV.prototype.refresh = function() {
    this.contents.clear();
    if (this._actor) {
        this.drawActorName(this._actor, this.textPadding(), 0);
        for (var i = 0; i < 6; i++) {
            this.drawItem(0, this.lineHeight() * (1 + i), 2 + i);
        }
    }
};

Window_EquipStatusForGALV.prototype.setTempActor = function(tempActor) {
    if (this._tempActor !== tempActor) {
        this._tempActor = tempActor;
        this.refresh();
    }
};

Window_EquipStatusForGALV.prototype.drawItem = function(x, y, paramId) {
    this.drawParamName(x + this.textPadding(), y, paramId);
    if (this._actor) {
        this.drawCurrentParam(x + 140, y, paramId);
    }
    this.drawRightArrow(x + 188, y);
    if (this._tempActor) {
        this.drawNewParam(x + 222, y, paramId);
    }
};

Window_EquipStatusForGALV.prototype.drawParamName = function(x, y, paramId) {
    this.changeTextColor(this.systemColor());
    this.drawText(TextManager.param(paramId), x, y, 120);
};

Window_EquipStatusForGALV.prototype.drawCurrentParam = function(x, y, paramId) {
    this.resetTextColor();
    this.drawText(this._actor.param(paramId), x, y, 48, 'right');
};

Window_EquipStatusForGALV.prototype.drawRightArrow = function(x, y) {
    this.changeTextColor(this.systemColor());
    this.drawText('\u2192', x, y, 32, 'center');
};

Window_EquipStatusForGALV.prototype.drawNewParam = function(x, y, paramId) {
    var newValue = this._tempActor.param(paramId);
    var diffvalue = newValue - this._actor.param(paramId);
    this.changeTextColor(this.paramchangeTextColor(diffvalue));
    this.drawText(newValue, x, y, 48, 'right');
};
その後、GALV~.jsに書かれてある以下のようなコードを見つけてください(コピペしたすぐ下にあります)。

コード: 全て選択

Window_ShardStatus.prototype = Object.create(Window_EquipStatus.prototype);
このコードを以下のように置き換えます。

コード: 全て選択

Window_ShardStatus.prototype = Object.create(Window_EquipStatusForGALV.prototype);
これで完了ですが、他にも変更しなければならない箇所があるかもしれません。
実際に導入してテストをやっているわけではないので、うまくいかなかったらすみません。

追記:ライセンスについて調べていないので、改変可能なのかどうかの確認をお願いします。

Re: Atelier RGSS様「monogatari」とGalv様の「MagicShards」の競合について

Posted: 2017年10月16日(月) 16:58
by T.C.
>ツミオ様

迅速な対応、何度も申し訳ございません。

導入したところ、しっかりと反映されておりました!

ありがとうございました! :D

Re: Atelier RGSS様「monogatari」とGalv様の「MagicShards」の競合について

Posted: 2017年10月16日(月) 17:10
by T.C.
何度も申し訳ありません

追加での質問なのですが、
MagicShard において、スロット数を6に設定しているのですが、
なぜかスロット数が0のままになっています。

これも、競合による影響でしょうか?

Re: Atelier RGSS様「monogatari」とGalv様の「MagicShards」の競合について

Posted: 2017年10月16日(月) 17:30
by ツミオ
競合かどうかを確かめるための最も簡単な方法は、他のプラグインを全てOFFにすることです。
OFFにしても同様の現象が発生している場合、設定が間違っているかプラグインがおかしいかのどちらかです。
ご確認ください。

Re: Atelier RGSS様「monogatari」とGalv様の「MagicShards」の競合について

Posted: 2017年10月16日(月) 17:42
by T.C.
>ツミオ様

解決いたしました、設定を間違えていたようです。

ありがとうございました。