浏览代码
Adding the automatic en/disabling of the volume controls based on whether the player is actually able to send voice (i.e. do they have a device available, are they connected to the channel). Adding logic to display a mic icon for the local user instead of the volume control, so they just have the mute toggle. It still needs a mic icon.
/main/staging/vivox_package_integration
Adding the automatic en/disabling of the volume controls based on whether the player is actually able to send voice (i.e. do they have a device available, are they connected to the channel). Adding logic to display a mic icon for the local user instead of the volume control, so they just have the mute toggle. It still needs a mic icon.
/main/staging/vivox_package_integration
nathaniel.buck@unity3d.com
3 年前
当前提交
fb9919c6
共有 6 个文件被更改,包括 221 次插入 和 70 次删除
-
103Assets/Prefabs/UI/UserCardPanel.prefab
-
48Assets/Scripts/UI/LobbyUserVolumeUI.cs
-
1Assets/Scripts/Vivox/VivoxSetup.cs
-
97Assets/Scripts/Vivox/VivoxUserHandler.cs
-
11Assets/Scripts/UI/MuteUI.cs.meta
-
31Assets/Scripts/UI/MuteUI.cs
|
|||
fileFormatVersion: 2 |
|||
guid: f722d3f4131ab52469d430cc5855ee83 |
|||
MonoImporter: |
|||
externalObjects: {} |
|||
serializedVersion: 2 |
|||
defaultReferences: [] |
|||
executionOrder: 0 |
|||
icon: {instanceID: 0} |
|||
userData: |
|||
assetBundleName: |
|||
assetBundleVariant: |
|
|||
using UnityEngine; |
|||
|
|||
namespace LobbyRelaySample.UI |
|||
{ |
|||
public class MuteUI : UIPanelBase |
|||
{ |
|||
[SerializeField] |
|||
CanvasGroup m_voiceRings; |
|||
|
|||
public void EnableVoice() |
|||
{ |
|||
Show(); |
|||
} |
|||
|
|||
public void DisableVoice() |
|||
{ |
|||
Hide(0.4f); |
|||
} |
|||
|
|||
/* TODO : If we can hook in the volume from a user, we can plug it in here. |
|||
/// <summary>
|
|||
/// Controls the visibility of the volume rings to show activity levels of the voice channel on this user.
|
|||
/// </summary>
|
|||
/// <param name="normalizedVolume"></param>
|
|||
public void OnSoundDetected(float normalizedVolume) |
|||
{ |
|||
m_voiceRings.alpha = normalizedVolume; |
|||
} |
|||
*/ |
|||
} |
|||
} |
撰写
预览
正在加载...
取消
保存
Reference in new issue