Compare commits
No commits in common. "6d89f365d37b5c0003b5e23e7ae923a0462acb7b" and "27b17a8f6ed9932186786a48365ff2cb38842acd" have entirely different histories.
6d89f365d3
...
27b17a8f6e
|
@ -833,8 +833,6 @@ MonoBehaviour:
|
||||||
toggle5: {fileID: 5382943705491709219}
|
toggle5: {fileID: 5382943705491709219}
|
||||||
toggle6: {fileID: 6251437642903478223}
|
toggle6: {fileID: 6251437642903478223}
|
||||||
toggle7: {fileID: 117463751223528660}
|
toggle7: {fileID: 117463751223528660}
|
||||||
Frequency:
|
|
||||||
camera: {fileID: 480111845}
|
|
||||||
--- !u!65 &1537869982341012852
|
--- !u!65 &1537869982341012852
|
||||||
BoxCollider:
|
BoxCollider:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
|
|
|
@ -81,10 +81,7 @@ public class Spectrumdetection : MonoBehaviour
|
||||||
/// 最终的波段
|
/// 最终的波段
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string Frequency;
|
public string Frequency;
|
||||||
/// <summary>
|
|
||||||
/// 摄像机显示层数
|
|
||||||
/// </summary>
|
|
||||||
public Camera camera;
|
|
||||||
void Start()
|
void Start()
|
||||||
{
|
{
|
||||||
equipmentCommon = GetComponent<EquipmentCommon>();
|
equipmentCommon = GetComponent<EquipmentCommon>();
|
||||||
|
@ -105,7 +102,6 @@ public class Spectrumdetection : MonoBehaviour
|
||||||
if (ison)
|
if (ison)
|
||||||
{
|
{
|
||||||
Frequency = "HUF";
|
Frequency = "HUF";
|
||||||
camera.cullingMask = 1 << 16;
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
toggle2.onValueChanged.AddListener((ison) =>
|
toggle2.onValueChanged.AddListener((ison) =>
|
||||||
|
@ -113,7 +109,6 @@ public class Spectrumdetection : MonoBehaviour
|
||||||
if (ison)
|
if (ison)
|
||||||
{
|
{
|
||||||
Frequency = "L";
|
Frequency = "L";
|
||||||
camera.cullingMask = 1 << 17;
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
toggle3.onValueChanged.AddListener((ison) =>
|
toggle3.onValueChanged.AddListener((ison) =>
|
||||||
|
@ -121,7 +116,6 @@ public class Spectrumdetection : MonoBehaviour
|
||||||
if (ison)
|
if (ison)
|
||||||
{
|
{
|
||||||
Frequency = "S";
|
Frequency = "S";
|
||||||
camera.cullingMask = 1 << 18;
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
toggle4.onValueChanged.AddListener((ison) =>
|
toggle4.onValueChanged.AddListener((ison) =>
|
||||||
|
@ -129,7 +123,6 @@ public class Spectrumdetection : MonoBehaviour
|
||||||
if (ison)
|
if (ison)
|
||||||
{
|
{
|
||||||
Frequency = "C";
|
Frequency = "C";
|
||||||
camera.cullingMask = 1 << 19;
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
toggle5.onValueChanged.AddListener((ison) =>
|
toggle5.onValueChanged.AddListener((ison) =>
|
||||||
|
@ -137,7 +130,6 @@ public class Spectrumdetection : MonoBehaviour
|
||||||
if (ison)
|
if (ison)
|
||||||
{
|
{
|
||||||
Frequency = "X";
|
Frequency = "X";
|
||||||
camera.cullingMask = 1 << 20;
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
toggle6.onValueChanged.AddListener((ison) =>
|
toggle6.onValueChanged.AddListener((ison) =>
|
||||||
|
@ -145,7 +137,6 @@ public class Spectrumdetection : MonoBehaviour
|
||||||
if (ison)
|
if (ison)
|
||||||
{
|
{
|
||||||
Frequency = "Ku";
|
Frequency = "Ku";
|
||||||
camera.cullingMask = 1 << 21;
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
toggle7.onValueChanged.AddListener((ison) =>
|
toggle7.onValueChanged.AddListener((ison) =>
|
||||||
|
@ -153,7 +144,6 @@ public class Spectrumdetection : MonoBehaviour
|
||||||
if (ison)
|
if (ison)
|
||||||
{
|
{
|
||||||
Frequency = "Ka";
|
Frequency = "Ka";
|
||||||
camera.cullingMask = (1 << 22);
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -245,7 +235,7 @@ public class Spectrumdetection : MonoBehaviour
|
||||||
|
|
||||||
private void Microwavefrequency()
|
private void Microwavefrequency()
|
||||||
{
|
{
|
||||||
if (frequency.Length > 0)
|
if (frequency.Length>0)
|
||||||
{
|
{
|
||||||
string[] str = frequency.Split(',');
|
string[] str = frequency.Split(',');
|
||||||
for (int i = 0; i < str.Length; i++)
|
for (int i = 0; i < str.Length; i++)
|
||||||
|
@ -257,7 +247,7 @@ public class Spectrumdetection : MonoBehaviour
|
||||||
break;
|
break;
|
||||||
case "L":
|
case "L":
|
||||||
toggle2.gameObject.SetActive(true);
|
toggle2.gameObject.SetActive(true);
|
||||||
break;
|
break ;
|
||||||
case "S":
|
case "S":
|
||||||
toggle3.gameObject.SetActive(true);
|
toggle3.gameObject.SetActive(true);
|
||||||
break;
|
break;
|
||||||
|
@ -291,7 +281,7 @@ public class Spectrumdetection : MonoBehaviour
|
||||||
/// <exception cref="NotImplementedException"></exception>
|
/// <exception cref="NotImplementedException"></exception>
|
||||||
private void Emittedray()
|
private void Emittedray()
|
||||||
{
|
{
|
||||||
if (Input.GetMouseButtonDown(0) && UIBootstrap.Instance.GetRoleByIDPracticeId(GlobalFlag.practiceSeatId) != "0")
|
if (Input.GetMouseButtonDown(0)&& UIBootstrap.Instance.GetRoleByIDPracticeId(GlobalFlag.practiceSeatId) != "0")
|
||||||
{
|
{
|
||||||
Ray ray = Camera.main.ScreenPointToRay(Input.mousePosition);
|
Ray ray = Camera.main.ScreenPointToRay(Input.mousePosition);
|
||||||
RaycastHit hit;
|
RaycastHit hit;
|
||||||
|
@ -299,7 +289,7 @@ public class Spectrumdetection : MonoBehaviour
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (Physics.Raycast(ray, out hit, 1000))
|
if (Physics.Raycast(ray,out hit,1000))
|
||||||
{
|
{
|
||||||
if (hit.collider.GetComponent<EquipmentCommon>())
|
if (hit.collider.GetComponent<EquipmentCommon>())
|
||||||
{
|
{
|
||||||
|
@ -322,14 +312,14 @@ public class Spectrumdetection : MonoBehaviour
|
||||||
Collider[] colliders = Physics.OverlapSphere(transform.position, float.Parse(Detectionrange) * 100);
|
Collider[] colliders = Physics.OverlapSphere(transform.position, float.Parse(Detectionrange) * 100);
|
||||||
for (int i = 0; i < colliders.Length; i++)
|
for (int i = 0; i < colliders.Length; i++)
|
||||||
{
|
{
|
||||||
if (colliders[i].transform.gameObject.tag == "WRJ")
|
if (colliders[i].transform.gameObject.tag=="WRJ")
|
||||||
{
|
{
|
||||||
Debug.LogError("进来了");
|
Debug.LogError("进来了");
|
||||||
UnmannedAerialVehicle unmannedAerialVehicle = null;
|
UnmannedAerialVehicle unmannedAerialVehicle = null;
|
||||||
if (colliders[i].GetComponent<UnmannedAerialVehicle>())
|
if (colliders[i].GetComponent<UnmannedAerialVehicle>())
|
||||||
{
|
{
|
||||||
unmannedAerialVehicle = colliders[i].GetComponent<UnmannedAerialVehicle>();
|
unmannedAerialVehicle = colliders[i].GetComponent<UnmannedAerialVehicle>();
|
||||||
if (unmannedAerialVehicle != null)
|
if (unmannedAerialVehicle !=null)
|
||||||
{
|
{
|
||||||
Microwaveweapon microwaveweapon = Microwaveweapon.MicrowaveweaponList.Find(x => (x != null && x.ismicow == false));
|
Microwaveweapon microwaveweapon = Microwaveweapon.MicrowaveweaponList.Find(x => (x != null && x.ismicow == false));
|
||||||
if (microwaveweapon)
|
if (microwaveweapon)
|
||||||
|
|
|
@ -140,7 +140,6 @@ public class TerrestrialRadioInterferenceManger : MonoBehaviour
|
||||||
if (ison)
|
if (ison)
|
||||||
{
|
{
|
||||||
disturb = "HUF";
|
disturb = "HUF";
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
toggle2.onValueChanged.AddListener((ison) =>
|
toggle2.onValueChanged.AddListener((ison) =>
|
||||||
|
|
Loading…
Reference in New Issue