修改数字跳转bug

This commit is contained in:
高国正 2023-09-06 11:39:45 +08:00
parent 14a5f6129d
commit 3ac8efce54
5 changed files with 31 additions and 16 deletions

View File

@ -274143,6 +274143,18 @@ MonoBehaviour:
onValueChanged: onValueChanged:
m_PersistentCalls: m_PersistentCalls:
m_Calls: m_Calls:
- m_Target: {fileID: 4362348815729331935}
m_TargetAssemblyTypeName: UnityEngine.GameObject, UnityEngine
m_MethodName: SetActive
m_Mode: 6
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
m_IntArgument: 0
m_FloatArgument: 0
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
- m_Target: {fileID: 4362348816464134982} - m_Target: {fileID: 4362348816464134982}
m_TargetAssemblyTypeName: UnityEngine.GameObject, UnityEngine m_TargetAssemblyTypeName: UnityEngine.GameObject, UnityEngine
m_MethodName: SetActive m_MethodName: SetActive

View File

@ -78,13 +78,13 @@ public class CameraRT : MonoBehaviour
private static void BoolMonitor_ValueChanged(object sender, EventArgs e) private static void BoolMonitor_ValueChanged(object sender, EventArgs e)
{ {
//Debug.Log("当前是否不动" + BoolMonitor.Value); //Debug.Log("当前是否不动" + BoolMonitor.Value);
if (!BoolMonitor.Value) //if (!BoolMonitor.Value)
{ //{
if (!string.IsNullOrEmpty(WebInteraction.Inst.current_videoNumber) && WebInteraction.Inst.isVideoPlay) // if (!string.IsNullOrEmpty(WebInteraction.Inst.current_videoNumber) && WebInteraction.Inst.isVideoPlay)
{ // {
WebInteraction.Inst.CloseVideo(WebInteraction.Inst.current_videoNumber); // WebInteraction.Inst.CloseVideo(WebInteraction.Inst.current_videoNumber);
} // }
} //}
} }
private void Start() private void Start()

View File

@ -59,8 +59,10 @@ public class UIToCabinet : MonoBehaviour
for (int i = 0; i < toggles.Count; i++) for (int i = 0; i < toggles.Count; i++)
{ {
var index = i; var index = i;
toggles[i].onValueChanged.AddListener((ison) => toggles[index].onValueChanged.AddListener((ison) =>
{ {
if (!toggles[index].gameObject.activeInHierarchy)
return;
if (ison) if (ison)
{ {
CreateLine createLine = PatternChoose.Inst.transform.Find("»­Ïß").GetComponent<CreateLine>(); CreateLine createLine = PatternChoose.Inst.transform.Find("»­Ïß").GetComponent<CreateLine>();
@ -291,6 +293,7 @@ public class UIToCabinet : MonoBehaviour
/// </summary> /// </summary>
public void UI_init() public void UI_init()
{ {
WebInteraction.Inst.CloseVideo(WebInteraction.Inst.current_videoNumber);
GameManager.Inst.power_close(); GameManager.Inst.power_close();
if (GameManager.Inst.objectToShow_add.activeSelf) if (GameManager.Inst.objectToShow_add.activeSelf)

View File

@ -22,7 +22,7 @@ public class LensUI : CabinetUIBase
button.onClick.AddListener(() => button.onClick.AddListener(() =>
{ {
var t = text.text.Replace("ÉãÏñ", ""); var t = text.text.Replace("ÉãÏñ", "");
if (BoolMonitor.Value) //if (BoolMonitor.Value)
{ {
WebInteraction.Inst.current_videoNumber = t; WebInteraction.Inst.current_videoNumber = t;
WebInteraction.Inst.isVideoPlay = true; WebInteraction.Inst.isVideoPlay = true;

View File

@ -67,13 +67,13 @@ public class ExtendedFlycam : MonoBehaviour
private static void BoolMonitor_ValueChanged(object sender, EventArgs e) private static void BoolMonitor_ValueChanged(object sender, EventArgs e)
{ {
//Debug.Log("当前是否不动" + BoolMonitor.Value); //Debug.Log("当前是否不动" + BoolMonitor.Value);
if (!BoolMonitor.Value) //if (!BoolMonitor.Value)
{ //{
if (!string.IsNullOrEmpty(WebInteraction.Inst.current_videoNumber) && WebInteraction.Inst.isVideoPlay) // if (!string.IsNullOrEmpty(WebInteraction.Inst.current_videoNumber) && WebInteraction.Inst.isVideoPlay)
{ // {
WebInteraction.Inst.CloseVideo(WebInteraction.Inst.current_videoNumber); // WebInteraction.Inst.CloseVideo(WebInteraction.Inst.current_videoNumber);
} // }
} //}
} }
private Transform cameraTransform; private Transform cameraTransform;