Compare commits
No commits in common. "c4ae42efed424f1b02f861cb36a628d8ebb068cd" and "2a482696488754f2fb967f63a9bcc078c143b9d7" have entirely different histories.
c4ae42efed
...
2a48269648
|
|
@ -192,7 +192,29 @@ public class RadarManger : MonoBehaviour
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 雷达盲区让目标消失在地图上
|
||||||
|
/// </summary>
|
||||||
|
private void Deadzone()
|
||||||
|
{
|
||||||
|
if (float.Parse(NearBlindArea) > 0)
|
||||||
|
{
|
||||||
|
Collider[] colliders = Physics.OverlapSphere(transform.position, float.Parse(NearBlindArea));
|
||||||
|
for (int i = 0; i < colliders.Length; i++)
|
||||||
|
{
|
||||||
|
if (colliders[i].transform.gameObject.tag == "WRJ")
|
||||||
|
{
|
||||||
|
//Debug.Log("进来了" + Vector3.Distance(transform.position, colliders[i].transform.position));
|
||||||
|
UnmannedAerialVehicleManage unmannedAerialVehicle = colliders[i].GetComponent<UnmannedAerialVehicleManage>();
|
||||||
|
if (unmannedAerialVehicle)
|
||||||
|
{
|
||||||
|
GameObject game = unmannedAerialVehicle.gamemap;
|
||||||
|
Destroy(game);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
#region 启动暂停
|
#region 启动暂停
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 导条变化调用
|
/// 导条变化调用
|
||||||
|
|
@ -220,7 +242,6 @@ public class RadarManger : MonoBehaviour
|
||||||
//Debug.Log("Timer fired at: " + Time.time);
|
//Debug.Log("Timer fired at: " + Time.time);
|
||||||
yield return new WaitForSeconds(5); // 等待一段时间后继续执行
|
yield return new WaitForSeconds(5); // 等待一段时间后继续执行
|
||||||
RetrievalUAV();
|
RetrievalUAV();
|
||||||
//Deadzone();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -392,28 +413,7 @@ public class RadarManger : MonoBehaviour
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/// <summary>
|
|
||||||
/// 雷达盲区让目标消失在地图上
|
|
||||||
/// </summary>
|
|
||||||
private void Deadzone()
|
|
||||||
{
|
|
||||||
if (float.Parse(NearBlindArea) > 0)
|
|
||||||
{
|
|
||||||
Collider[] colliders = Physics.OverlapSphere(transform.position, float.Parse(NearBlindArea));
|
|
||||||
for (int i = 0; i < colliders.Length; i++)
|
|
||||||
{
|
|
||||||
if (colliders[i].transform.gameObject.tag == "WRJ")
|
|
||||||
{
|
|
||||||
//Debug.Log("进来了" + Vector3.Distance(transform.position, colliders[i].transform.position));
|
|
||||||
UnmannedAerialVehicleManage unmannedAerialVehicle = colliders[i].GetComponent<UnmannedAerialVehicleManage>();
|
|
||||||
if (unmannedAerialVehicle)
|
|
||||||
{
|
|
||||||
unmannedAerialVehicle.gamemap.SetActive(false);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 检测鼠标点击的方法
|
/// 检测鼠标点击的方法
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue