Application.isLoadingLevel 正在加载关卡?

static var isLoadingLevel : bool

Description描述

Is some level being loaded? (Read Only)

是否有一些场景正在读取(只读)

另译:是否正在加载某些关卡。

LoadLevel and LoadLevelAdditive don't happen immediately - a new level is loaded after the current game frame finishes. isLoadingLevel returns true if a level load was requested this frame already.

方法 LoadLevel LoadLevelAdditive 不会立即生效-一个新的场景在当前游戏帧完成之后被加载。如果一个被请求加载场景的帧已经完成了,那么isLoadingLevel返回值为true。

参见: LoadLevel , LoadLevelAdditive .

using UnityEngine;
using System.Collections;

public class example : MonoBehaviour {
	public void Awake() {
		print(Application.isLoadingLevel);
	}
}
print(Application.isLoadingLevel);
Page last updated: 2010-12-14