言語: 日本語
  • C#
  • JS
  • Boo

スクリプト言語

お好みのスクリプト言語を選択すると、サンプルコードがその言語で表示されます。

AudioSource.priority

Switch to Manual
public var priority: int;

Description

AudioSourceオブジェクトの優先順位を設定する。

Unity is virtualizing AudioSources, when there's more AudioSources playing than available hardware channels. The AudioSources with lowest priority (and audibility) is virtualized first. Priority is an integer between 0 and 255. 0=highest priority, 255=lowest priority.

	// occlude this sound if we dont have hardware resources to virtualize it

	audio.priority = 255;