Compare commits

..

No commits in common. "658c7f664fd8f6c5e1ef887c087a0c9e86daf87f" and "96a090910f7156bf3c3a611524cb73183554f6d4" have entirely different histories.

4 changed files with 12 additions and 7339 deletions

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -1,10 +1,6 @@
using AdamSync; using AdamSync;
using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.Security.Permissions;
using UnityEngine; using UnityEngine;
using UnityEngine.EventSystems;
using UnityEngine.UI;
/// <summary> /// <summary>
/// 重点保护目标 /// 重点保护目标
@ -48,91 +44,11 @@ public class HighPriorityTarget : MonoBehaviour
/// 损坏模型 /// 损坏模型
/// </summary> /// </summary>
public GameObject ModerDamage; public GameObject ModerDamage;
/// <summary>
/// 调节频率面板
/// </summary>
public Image regulate;
/// <summary>
/// 关闭频率面板
/// </summary>
public Button buttonreg;
/// <summary>
/// 频率选择
/// </summary>
public Toggle toggle1;
public Toggle toggle2;
public Toggle toggle3;
public Toggle toggle4;
public Toggle toggle5;
public Toggle toggle6;
public Toggle toggle7;
/// <summary>
/// 接收的字段
/// </summary>
public string frequency;
// Start is called before the first frame update // Start is called before the first frame update
void Start() void Start()
{ {
HighPriorityTargets.Add(this); HighPriorityTargets.Add(this);
Number = HighPriorityTargets.Count.ToString(); Number = HighPriorityTargets.Count.ToString();
buttonreg.onClick.AddListener(() =>
{
regulate.gameObject.SetActive(false);
});
Interferencefrequency();
}
private void Interferencefrequency()
{
toggle1.onValueChanged.AddListener((ison) =>
{
if (ison)
{
frequency = "HUF";
}
});
toggle2.onValueChanged.AddListener((ison) =>
{
if (ison)
{
frequency = "L";
}
});
toggle3.onValueChanged.AddListener((ison) =>
{
if (ison)
{
frequency = "S";
}
});
toggle4.onValueChanged.AddListener((ison) =>
{
if (ison)
{
frequency = "C";
}
});
toggle5.onValueChanged.AddListener((ison) =>
{
if (ison)
{
frequency = "X";
}
});
toggle6.onValueChanged.AddListener((ison) =>
{
if (ison)
{
frequency = "Ku";
}
});
toggle7.onValueChanged.AddListener((ison) =>
{
if (ison)
{
frequency = "Ka";
}
});
} }
// Update is called once per frame // Update is called once per frame
@ -140,22 +56,6 @@ public class HighPriorityTarget : MonoBehaviour
{ {
if (Camera.main) if (Camera.main)
KeyObjectiveUI.transform.LookAt(Camera.main.transform); KeyObjectiveUI.transform.LookAt(Camera.main.transform);
if (UIBootstrap.Instance.GetRoleByIDPracticeId(GlobalFlag.practiceSeatId) != "0"&&Input.GetMouseButtonDown(0))
{
Ray ray = Camera.main.ScreenPointToRay(Input.mousePosition);
RaycastHit hit;
if (EventSystem.current.IsPointerOverGameObject())
{
return;
}
if (Physics.Raycast(ray,out hit,1000))
{
if (hit.collider.gameObject.tag== "AttackTarget" &&hit.transform.GetComponent<HighPriorityTarget>())
{
regulate.gameObject.SetActive(true);
}
}
}
} }
/// <summary> /// <summary>