【解決済】取得できない情報の処理
Posted: 2017年8月25日(金) 11:12
バトルシーンにおいてコモンイベントを呼び出し、条件分岐にスクリプトを使い、アクターのメモ欄から判断して条件分岐を行うという処理を作ろうとしているのですが、アクターに欠番(パーティーが3人以下しかいない)がある場合、いないアクターのメモ欄を取得しようとしてエラーが発生してしまいます。
これをどうにか改善したいのですが、いい方法をご存知でしたら教えていただけないでしょうか?
これをどうにか改善したいのですが、いい方法をご存知でしたら教えていただけないでしょうか?
コード: 全て選択
◆条件分岐:スクリプト:$dataActors[$gameVariables.value(11)].note.match(/<(?:male)>/i)
◆条件分岐:スクリプト:$dataActors[$gameVariables.value(12)].note.match(/<(?:female)>/i)
◆スクリプト:this._params[0] = 1;
: :this._params[1] = ($gameVariables.value(12));
: :this._params[2] = 35;
: :this._params[3] = -2;
: :this.command339();
◆条件分岐:スクリプト:$dataActors[$gameVariables.value(13)].note.match(/<(?:male)>/i)
◆スクリプト:this._params[0] = 1;
: :this._params[1] = ($gameVariables.value(13));
: :this._params[2] = 35;
: :this._params[3] = -2;
: :this.command339();
◆条件分岐:スクリプト:$dataActors[$gameVariables.value(14)].note.match(/<(?:female)>/i)
◆スクリプト:this._params[0] = 1;
: :this._params[1] = ($gameVariables.value(14));
: :this._params[2] = 35;
: :this._params[3] = -2;
: :this.command339();
◆
:分岐終了
◆
:分岐終了
◆
:分岐終了
◆
:それ以外のとき
◆条件分岐:スクリプト:$dataActors[$gameVariables.value(12)].note.match(/<(?:male)>/i)
◆スクリプト:this._params[0] = 1;
: :this._params[1] = ($gameVariables.value(12));
: :this._params[2] = 35;
: :this._params[3] = -2;
: :this.command339();
◆条件分岐:スクリプト:$dataActors[$gameVariables.value(13)].note.match(/<(?:female)>/i)
◆スクリプト:this._params[0] = 1;
: :this._params[1] = ($gameVariables.value(13));
: :this._params[2] = 35;
: :this._params[3] = -2;
: :this.command339();
◆条件分岐:スクリプト:$dataActors[$gameVariables.value(14)].note.match(/<(?:male)>/i)
◆スクリプト:this._params[0] = 1;
: :this._params[1] = ($gameVariables.value(14));
: :this._params[2] = 35;
: :this._params[3] = -2;
: :this.command339();
◆
:分岐終了
◆
:分岐終了
◆
:分岐終了
◆
:分岐終了