お好みのスクリプト言語を選択すると、サンプルコードがその言語で表示されます。
Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable.
Closeレベルを加算的にロードします。
LoadLevel とは異なり、LoadLevelAdditiveは現在のレベルのゲームオブジェクトを破棄することはありません。 新しいレベルからロードしたオブジェクトは現在のシーンに追加されます。これは連続的な仮想世界を作成するのに便利です。 例えばシーン内を歩きまわるようなコンテンツをロードする時です。
// Loads the level with index 1 Application.LoadLevel (1); // Add items from the level named "MoreStuff". Application.LoadLevelAdditive ("MoreStuff");
using UnityEngine; using System.Collections; public class ExampleClass : MonoBehaviour { void Example() { Application.LoadLevel(1); Application.LoadLevelAdditive("MoreStuff"); } }
import UnityEngine import System.Collections public class ExampleClass(MonoBehaviour): def Example() as void: Application.LoadLevel(1) Application.LoadLevelAdditive('MoreStuff')