修改多窗口 打开 逻辑

This commit is contained in:
YangHua 2024-02-06 17:54:56 +08:00
parent 31c8629b05
commit d06b7f36a6
19 changed files with 109 additions and 59 deletions

View File

@ -3586,6 +3586,11 @@ PrefabInstance:
propertyPath: m_IsActive propertyPath: m_IsActive
value: 0 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 1649737328956898976, guid: 38fb1def99b2cd147a96842efe5a355b,
type: 3}
propertyPath: m_TagString
value: Importance
objectReference: {fileID: 0}
- target: {fileID: 1649737328956898977, guid: 38fb1def99b2cd147a96842efe5a355b, - target: {fileID: 1649737328956898977, guid: 38fb1def99b2cd147a96842efe5a355b,
type: 3} type: 3}
propertyPath: m_LocalPosition.x propertyPath: m_LocalPosition.x

View File

@ -19623,7 +19623,7 @@ GameObject:
- component: {fileID: 2807491000924113457} - component: {fileID: 2807491000924113457}
m_Layer: 12 m_Layer: 12
m_Name: Image m_Name: Image
m_TagString: Untagged m_TagString: Radar
m_Icon: {fileID: 0} m_Icon: {fileID: 0}
m_NavMeshLayer: 0 m_NavMeshLayer: 0
m_StaticEditorFlags: 0 m_StaticEditorFlags: 0

View File

@ -2122,6 +2122,11 @@ PrefabInstance:
propertyPath: m_IsActive propertyPath: m_IsActive
value: 0 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 1649737328956898976, guid: 38fb1def99b2cd147a96842efe5a355b,
type: 3}
propertyPath: m_TagString
value: WRJParameter
objectReference: {fileID: 0}
- target: {fileID: 1649737328956898977, guid: 38fb1def99b2cd147a96842efe5a355b, - target: {fileID: 1649737328956898977, guid: 38fb1def99b2cd147a96842efe5a355b,
type: 3} type: 3}
propertyPath: m_LocalPosition.x propertyPath: m_LocalPosition.x
@ -2791,6 +2796,11 @@ PrefabInstance:
propertyPath: m_IsActive propertyPath: m_IsActive
value: 0 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 1649737328956898976, guid: 38fb1def99b2cd147a96842efe5a355b,
type: 3}
propertyPath: m_TagString
value: WRJParameter
objectReference: {fileID: 0}
- target: {fileID: 1649737328956898977, guid: 38fb1def99b2cd147a96842efe5a355b, - target: {fileID: 1649737328956898977, guid: 38fb1def99b2cd147a96842efe5a355b,
type: 3} type: 3}
propertyPath: m_LocalPosition.x propertyPath: m_LocalPosition.x

View File

@ -12822,6 +12822,11 @@ PrefabInstance:
propertyPath: m_IsActive propertyPath: m_IsActive
value: 0 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 6102700022742998670, guid: b2cb817bb62743a4194cd9d89f07e27d,
type: 3}
propertyPath: m_TagString
value: Importance
objectReference: {fileID: 0}
m_RemovedComponents: m_RemovedComponents:
- {fileID: 1076142016709017099, guid: b2cb817bb62743a4194cd9d89f07e27d, type: 3} - {fileID: 1076142016709017099, guid: b2cb817bb62743a4194cd9d89f07e27d, type: 3}
m_SourcePrefab: {fileID: 100100000, guid: b2cb817bb62743a4194cd9d89f07e27d, type: 3} m_SourcePrefab: {fileID: 100100000, guid: b2cb817bb62743a4194cd9d89f07e27d, type: 3}

View File

@ -248,7 +248,7 @@ GameObject:
- component: {fileID: 1578225509420461004} - component: {fileID: 1578225509420461004}
m_Layer: 12 m_Layer: 12
m_Name: Image m_Name: Image
m_TagString: Untagged m_TagString: Radar
m_Icon: {fileID: 0} m_Icon: {fileID: 0}
m_NavMeshLayer: 0 m_NavMeshLayer: 0
m_StaticEditorFlags: 0 m_StaticEditorFlags: 0
@ -944,6 +944,11 @@ PrefabInstance:
propertyPath: m_IsActive propertyPath: m_IsActive
value: 0 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 1649737328956898976, guid: 38fb1def99b2cd147a96842efe5a355b,
type: 3}
propertyPath: m_TagString
value: Importance
objectReference: {fileID: 0}
- target: {fileID: 1649737328956898977, guid: 38fb1def99b2cd147a96842efe5a355b, - target: {fileID: 1649737328956898977, guid: 38fb1def99b2cd147a96842efe5a355b,
type: 3} type: 3}
propertyPath: m_LocalPosition.x propertyPath: m_LocalPosition.x

View File

@ -1090,7 +1090,7 @@ GameObject:
- component: {fileID: 8686255655278623726} - component: {fileID: 8686255655278623726}
m_Layer: 5 m_Layer: 5
m_Name: importance m_Name: importance
m_TagString: Untagged m_TagString: Importance
m_Icon: {fileID: 0} m_Icon: {fileID: 0}
m_NavMeshLayer: 0 m_NavMeshLayer: 0
m_StaticEditorFlags: 0 m_StaticEditorFlags: 0
@ -2653,13 +2653,6 @@ MonoBehaviour:
ModerDamage: {fileID: 2840960697985760213} ModerDamage: {fileID: 2840960697985760213}
regulate: {fileID: 4820533728664913016} regulate: {fileID: 4820533728664913016}
buttonreg: {fileID: 7363043795831063353} buttonreg: {fileID: 7363043795831063353}
toggle1: {fileID: 78723881495536872}
toggle2: {fileID: 3463523368336500832}
toggle3: {fileID: 3619221509897912575}
toggle4: {fileID: 28412645170237004}
toggle5: {fileID: 8932471483062020681}
toggle6: {fileID: 64890494959671527}
toggle7: {fileID: 4401106011680143311}
togFrequencyBands: togFrequencyBands:
- {fileID: 78723881495536872} - {fileID: 78723881495536872}
- {fileID: 3463523368336500832} - {fileID: 3463523368336500832}
@ -2726,7 +2719,7 @@ GameObject:
- component: {fileID: 1014353712495964052} - component: {fileID: 1014353712495964052}
m_Layer: 5 m_Layer: 5
m_Name: Canvas m_Name: Canvas
m_TagString: Importance m_TagString: Untagged
m_Icon: {fileID: 0} m_Icon: {fileID: 0}
m_NavMeshLayer: 0 m_NavMeshLayer: 0
m_StaticEditorFlags: 0 m_StaticEditorFlags: 0

View File

@ -281,7 +281,7 @@ GameObject:
- component: {fileID: 1422880735768166433} - component: {fileID: 1422880735768166433}
m_Layer: 5 m_Layer: 5
m_Name: Canvas m_Name: Canvas
m_TagString: Importance m_TagString: Untagged
m_Icon: {fileID: 0} m_Icon: {fileID: 0}
m_NavMeshLayer: 0 m_NavMeshLayer: 0
m_StaticEditorFlags: 0 m_StaticEditorFlags: 0
@ -770,7 +770,7 @@ GameObject:
- component: {fileID: 1747500451976562533} - component: {fileID: 1747500451976562533}
m_Layer: 5 m_Layer: 5
m_Name: importance m_Name: importance
m_TagString: Untagged m_TagString: Importance
m_Icon: {fileID: 0} m_Icon: {fileID: 0}
m_NavMeshLayer: 0 m_NavMeshLayer: 0
m_StaticEditorFlags: 0 m_StaticEditorFlags: 0
@ -2826,13 +2826,6 @@ MonoBehaviour:
ModerDamage: {fileID: 1467464424326605954} ModerDamage: {fileID: 1467464424326605954}
regulate: {fileID: 2445121072340223621} regulate: {fileID: 2445121072340223621}
buttonreg: {fileID: 1893370117554305087} buttonreg: {fileID: 1893370117554305087}
toggle1: {fileID: 6760580611336481383}
toggle2: {fileID: 2327747177229680297}
toggle3: {fileID: 6205561511136672778}
toggle4: {fileID: 4866093980683021871}
toggle5: {fileID: 1595232079232995888}
toggle6: {fileID: 848134281435870856}
toggle7: {fileID: 6994627430635325071}
togFrequencyBands: togFrequencyBands:
- {fileID: 6760580611336481383} - {fileID: 6760580611336481383}
- {fileID: 2327747177229680297} - {fileID: 2327747177229680297}

View File

@ -1558,7 +1558,7 @@ GameObject:
- component: {fileID: 5969528349560588974} - component: {fileID: 5969528349560588974}
m_Layer: 5 m_Layer: 5
m_Name: importance m_Name: importance
m_TagString: Untagged m_TagString: Importance
m_Icon: {fileID: 0} m_Icon: {fileID: 0}
m_NavMeshLayer: 0 m_NavMeshLayer: 0
m_StaticEditorFlags: 0 m_StaticEditorFlags: 0
@ -2513,7 +2513,7 @@ GameObject:
- component: {fileID: 4013790001393954177} - component: {fileID: 4013790001393954177}
m_Layer: 5 m_Layer: 5
m_Name: Canvas m_Name: Canvas
m_TagString: Importance m_TagString: Untagged
m_Icon: {fileID: 0} m_Icon: {fileID: 0}
m_NavMeshLayer: 0 m_NavMeshLayer: 0
m_StaticEditorFlags: 0 m_StaticEditorFlags: 0
@ -2826,13 +2826,6 @@ MonoBehaviour:
ModerDamage: {fileID: 7378831111228137673} ModerDamage: {fileID: 7378831111228137673}
regulate: {fileID: 5625621529173534083} regulate: {fileID: 5625621529173534083}
buttonreg: {fileID: 2359957618957220921} buttonreg: {fileID: 2359957618957220921}
toggle1: {fileID: 2987344993920604129}
toggle2: {fileID: 4263437241937524701}
toggle3: {fileID: 2372794671036074061}
toggle4: {fileID: 6045683915690793988}
toggle5: {fileID: 3776191318234792201}
toggle6: {fileID: 6688120530323237334}
toggle7: {fileID: 8540854955145205225}
togFrequencyBands: togFrequencyBands:
- {fileID: 2987344993920604129} - {fileID: 2987344993920604129}
- {fileID: 4263437241937524701} - {fileID: 4263437241937524701}

View File

@ -38,7 +38,7 @@ public class Microwaveweapon : MonoBehaviour
public string MicrowaveinterferenceAngle; public string MicrowaveinterferenceAngle;
#endregion #endregion
/// <summary> /// <summary>
/// 是否演练开关 /// 是否演练开关
/// </summary> /// </summary>
private bool _isStartRehearsing = false; private bool _isStartRehearsing = false;
@ -95,7 +95,7 @@ public class Microwaveweapon : MonoBehaviour
MicrowaveweaponList.Add(this); MicrowaveweaponList.Add(this);
// 订阅布尔值变化事件 // 订阅布尔值变化事件
OnActivationChanged += OnActivationChangedHandler; OnActivationChanged += OnActivationChangedHandler;
} }
/// <summary> /// <summary>
/// 演练是否开始开关 /// 演练是否开始开关
@ -118,7 +118,7 @@ public class Microwaveweapon : MonoBehaviour
/// </summary> /// </summary>
private void Offmode() private void Offmode()
{ {
if (equipment.isPlayer&&coroutine!=null) if (equipment.isPlayer && coroutine != null)
{ {
StopCoroutine(Timern()); StopCoroutine(Timern());
coroutine = null; coroutine = null;
@ -130,7 +130,7 @@ public class Microwaveweapon : MonoBehaviour
/// </summary> /// </summary>
private void Openmode() private void Openmode()
{ {
if (equipment.isPlayer&&coroutine ==null) if (equipment.isPlayer && coroutine == null)
{ {
StartCoroutine(Timern()); StartCoroutine(Timern());
} }
@ -140,7 +140,7 @@ public class Microwaveweapon : MonoBehaviour
while (true) while (true)
{ {
yield return new WaitForSeconds(microwtimer + 1.5f); yield return new WaitForSeconds(microwtimer + 1.5f);
if (miceopos!=null&&ismicow) if (miceopos != null && ismicow)
{ {
Launchattack(); Launchattack();
@ -155,9 +155,12 @@ public class Microwaveweapon : MonoBehaviour
protected string Getmicdata() protected string Getmicdata()
{ {
//Debug.Log("上传位置"); //Debug.Log("上传位置");
return string.Format("{0},{1},{2},{3},{4}","Micow", equipment.deviceID, miceopos.transform.position.x,miceopos.transform.position.y,miceopos.transform.position.z); return string.Format("{0},{1},{2},{3},{4}", "Micow", equipment.deviceID, miceopos.transform.position.x, miceopos.transform.position.y, miceopos.transform.position.z);
}
private void OnMouseDown()
{
GameManager.Instance.GetAllImportance();
} }
/// <summary> /// <summary>
/// 获取设备的参数 /// 获取设备的参数
/// </summary> /// </summary>
@ -169,7 +172,7 @@ public class Microwaveweapon : MonoBehaviour
{ {
case "储能间隔时间:": case "储能间隔时间:":
Storageintervaltime = weaponitemone[i].para_value; Storageintervaltime = weaponitemone[i].para_value;
microwtimer =float.Parse(Storageintervaltime); microwtimer = float.Parse(Storageintervaltime);
break; break;
case "毁伤目标累积作用时间:": case "毁伤目标累积作用时间:":
Microwavedamagetime = weaponitemone[i].para_value; Microwavedamagetime = weaponitemone[i].para_value;
@ -198,7 +201,7 @@ public class Microwaveweapon : MonoBehaviour
if (miceopos != null) if (miceopos != null)
{ {
microwavepoint.transform.DOLookAt(miceopos.position, 0.1f).SetEase(Ease.Linear); microwavepoint.transform.DOLookAt(miceopos.position, 0.1f).SetEase(Ease.Linear);
} }
} }
/// <summary> /// <summary>
@ -206,13 +209,13 @@ public class Microwaveweapon : MonoBehaviour
/// </summary> /// </summary>
public void Launchattack() public void Launchattack()
{ {
if (miceopos!=null) if (miceopos != null)
{ {
micdistance = Vector3.Distance(miceopos.position, transform.position); micdistance = Vector3.Distance(miceopos.position, transform.position);
var newdata = Getmicdata(); var newdata = Getmicdata();
//_ = SyncCreateRoom.SendMessageAsync(string.Format("send2room {0}", newdata)); //_ = SyncCreateRoom.SendMessageAsync(string.Format("send2room {0}", newdata));
MQTTManager.instance.SendData(MQTTManager.instance.Micow, newdata); MQTTManager.instance.SendData(MQTTManager.instance.Micow, newdata);
microblog.MicrowaveDisplay(micdistance / 10+1, 0.5f); microblog.MicrowaveDisplay(micdistance / 10 + 1, 0.5f);
Closeattack(miceopos); Closeattack(miceopos);
} }
} }
@ -223,8 +226,8 @@ public class Microwaveweapon : MonoBehaviour
/// <returns></returns> /// <returns></returns>
private void Closeattack(Transform pos) private void Closeattack(Transform pos)
{ {
UnmannedAerialVehicle unmannedAerialVehicle =pos.GetComponent<UnmannedAerialVehicle>(); UnmannedAerialVehicle unmannedAerialVehicle = pos.GetComponent<UnmannedAerialVehicle>();
if (unmannedAerialVehicle!=null) if (unmannedAerialVehicle != null)
{ {
StartCoroutine(Destructiondata(unmannedAerialVehicle)); StartCoroutine(Destructiondata(unmannedAerialVehicle));
StartCoroutine(Offlaserstrike()); StartCoroutine(Offlaserstrike());
@ -244,7 +247,7 @@ public class Microwaveweapon : MonoBehaviour
game.transform.SetParent(null); game.transform.SetParent(null);
game.SetActive(true); game.SetActive(true);
Destroy(unmannedAerialVehicle.gameObject); Destroy(unmannedAerialVehicle.gameObject);
} }
/// <summary> /// <summary>
/// 销毁无人机 /// 销毁无人机
@ -253,7 +256,7 @@ public class Microwaveweapon : MonoBehaviour
/// <returns></returns> /// <returns></returns>
public string Aeroplane(UnmannedAerialVehicle unmannedAerialVehicle) public string Aeroplane(UnmannedAerialVehicle unmannedAerialVehicle)
{ {
return string.Format("{0},{1},{2}","Planedata",unmannedAerialVehicle.unmannedAerialVehicleManage.equipmentCommon.deviceID,unmannedAerialVehicle.serialNumber); return string.Format("{0},{1},{2}", "Planedata", unmannedAerialVehicle.unmannedAerialVehicleManage.equipmentCommon.deviceID, unmannedAerialVehicle.serialNumber);
} }
/// <summary> /// <summary>
@ -271,13 +274,14 @@ public class Microwaveweapon : MonoBehaviour
public void Microwavetransmission(string[] data) public void Microwavetransmission(string[] data)
{ {
//接收激光下发的位置 //接收激光下发的位置
Vector3 vector =new Vector3(float.Parse(data[2]), float.Parse(data[3]),float.Parse(data[4])); Vector3 vector = new Vector3(float.Parse(data[2]), float.Parse(data[3]), float.Parse(data[4]));
float _micdistance = Vector3.Distance(vector, transform.position); float _micdistance = Vector3.Distance(vector, transform.position);
microwavepoint.transform.DOLookAt(vector, 0.1f).SetEase(Ease.Linear).OnComplete(() => { microwavepoint.transform.DOLookAt(vector, 0.1f).SetEase(Ease.Linear).OnComplete(() =>
{
microblog.MicrowaveDisplay(_micdistance / 10 + 1, 0.5f); microblog.MicrowaveDisplay(_micdistance / 10 + 1, 0.5f);
StartCoroutine(Offlaserstrike()); StartCoroutine(Offlaserstrike());
}); });
} }
private void OnDestroy() private void OnDestroy()
{ {

View File

@ -395,12 +395,9 @@ public class Spectrumdetection : MonoBehaviour
private void OnMouseDown() private void OnMouseDown()
{ {
if (equipmentCommon.isPlayer)
{
SpectrumdetectionUI.SetActive(true);
}
if (!GlobalFlag.isStartRehearsing && GlobalFlag.blueOrRed == 1) if (!GlobalFlag.isStartRehearsing && GlobalFlag.blueOrRed == 1)
{ {
GameManager.Instance.GetAllImportance();
EquipmentCommon equipmentCommon1 = GetComponent<EquipmentCommon>(); EquipmentCommon equipmentCommon1 = GetComponent<EquipmentCommon>();
if (equipmentCommon.deviceID == equipmentCommon1.deviceID) if (equipmentCommon.deviceID == equipmentCommon1.deviceID)
{ {
@ -408,6 +405,10 @@ public class Spectrumdetection : MonoBehaviour
Frequencyiamge.gameObject.SetActive(true); Frequencyiamge.gameObject.SetActive(true);
} }
} }
if (equipmentCommon.isPlayer)
{
SpectrumdetectionUI.SetActive(true);
}
//SpectrumdetectionUI.SetActive(true); //SpectrumdetectionUI.SetActive(true);
} }
private void OnDestroy() private void OnDestroy()

View File

@ -38,7 +38,7 @@ RenderSettings:
m_ReflectionIntensity: 1 m_ReflectionIntensity: 1
m_CustomReflection: {fileID: 0} m_CustomReflection: {fileID: 0}
m_Sun: {fileID: 1113159741} m_Sun: {fileID: 1113159741}
m_IndirectSpecularColor: {r: 0.066868424, g: 0.12216938, b: 0.2541184, a: 1} m_IndirectSpecularColor: {r: 0.06497114, g: 0.121774174, b: 0.26588207, a: 1}
m_UseRadianceAmbientProbe: 0 m_UseRadianceAmbientProbe: 0
--- !u!157 &3 --- !u!157 &3
LightmapSettings: LightmapSettings:
@ -6834,7 +6834,7 @@ GameObject:
- component: {fileID: 147647013} - component: {fileID: 147647013}
- component: {fileID: 147647014} - component: {fileID: 147647014}
m_Layer: 5 m_Layer: 5
m_Name: Canvas m_Name: MainCanvas
m_TagString: Untagged m_TagString: Untagged
m_Icon: {fileID: 0} m_Icon: {fileID: 0}
m_NavMeshLayer: 0 m_NavMeshLayer: 0
@ -69824,7 +69824,7 @@ MonoBehaviour:
m_PreInfinity: 2 m_PreInfinity: 2
m_PostInfinity: 2 m_PostInfinity: 2
m_RotationOrder: 4 m_RotationOrder: 4
randSeed: 25527625 randSeed: 753317671
isDoingTransition: 0 isDoingTransition: 0
minimumHeight: 0 minimumHeight: 0
--- !u!114 &1820978574 --- !u!114 &1820978574

View File

@ -22,7 +22,7 @@ public class DragController : MonoBehaviour, IBeginDragHandler, IEndDragHandler,
void Awake() void Awake()
{ {
mastermanagement = GameObject.Find("MianCanvas").GetComponent<Mastermanagement>(); mastermanagement = GameObject.Find("MainCanvas").GetComponent<Mastermanagement>();
} }
public void OnBeginDrag(PointerEventData eventData) public void OnBeginDrag(PointerEventData eventData)
{ {

View File

@ -525,6 +525,35 @@ public class GameManager : MonoSingleton<GameManager>
} }
} }
/// <summary>
/// 获取 所有 参数 修改 面板
/// </summary>
/// <returns></returns>
public void GetAllImportance()
{
GameObject[] radar = GameObject.FindGameObjectsWithTag("Radar");
GameObject[] objs = GameObject.FindGameObjectsWithTag("Importance");
for (int i = 0; i < objs.Length; i++)
{
objs[i].SetActive(false);
}
for (int i = 0; i < radar.Length; i++)
{
radar[i].SetActive(false);
}
}
/// <summary>
/// 获取无人机参数面板
/// </summary>
public void GetWRJParameter()
{
GameObject[] wrjParameter = GameObject.FindGameObjectsWithTag("WRJParameter");
for (int i = 0; i < wrjParameter.Length; i++)
{
wrjParameter[i].SetActive(false);
}
}
private void OnDisable() private void OnDisable()

View File

@ -23,6 +23,7 @@ namespace Assets.Zion.Scripts.Adam
{ {
if (UIBootstrap.Instance.GetRoleByIDPracticeId(GlobalFlag.practiceSeatId) == "0" && Input.GetMouseButtonDown(0)) if (UIBootstrap.Instance.GetRoleByIDPracticeId(GlobalFlag.practiceSeatId) == "0" && Input.GetMouseButtonDown(0))
{ {
if (EventSystem.current.IsPointerOverGameObject()) return;
Ray ray = Camera.main.ScreenPointToRay(Input.mousePosition); Ray ray = Camera.main.ScreenPointToRay(Input.mousePosition);
RaycastHit hitInfo; RaycastHit hitInfo;
if (Physics.Raycast(ray, out hitInfo, 1000)) if (Physics.Raycast(ray, out hitInfo, 1000))
@ -40,16 +41,19 @@ namespace Assets.Zion.Scripts.Adam
} }
else else
{ {
GameManager.Instance.GetWRJParameter();
wrjMenuSetPanel.localScale = Vector3.zero; wrjMenuSetPanel.localScale = Vector3.zero;
} }
} }
else else
{ {
GameManager.Instance.GetWRJParameter();
wrjMenuSetPanel.localScale = Vector3.zero; wrjMenuSetPanel.localScale = Vector3.zero;
} }
} }
else else
{ {
GameManager.Instance.GetWRJParameter();
wrjMenuSetPanel.localScale = Vector3.zero; wrjMenuSetPanel.localScale = Vector3.zero;
} }
} }

View File

@ -104,7 +104,7 @@ public class HighPriorityTarget : MonoBehaviour
MQTTManager.instance.SendData(MQTTManager.instance.BandSetting, nowData); MQTTManager.instance.SendData(MQTTManager.instance.BandSetting, nowData);
} }
} }
public void FrequencyGamepos(string _frequency) public void FrequencyGamepos(string _frequency)
{ {
int layerValue = LayerMask.NameToLayer(_frequency); int layerValue = LayerMask.NameToLayer(_frequency);
@ -133,6 +133,8 @@ public class HighPriorityTarget : MonoBehaviour
HighPriorityTarget highPriorityTarget = hit.transform.GetComponent<HighPriorityTarget>(); HighPriorityTarget highPriorityTarget = hit.transform.GetComponent<HighPriorityTarget>();
if (!GlobalFlag.isStartRehearsing && highPriorityTarget && highPriorityTarget.Number == Number) if (!GlobalFlag.isStartRehearsing && highPriorityTarget && highPriorityTarget.Number == Number)
{ {
GameManager.Instance.GetAllImportance();
regulate.transform.position = Camera.main.WorldToScreenPoint(hit.point); regulate.transform.position = Camera.main.WorldToScreenPoint(hit.point);
regulate.gameObject.SetActive(true); regulate.gameObject.SetActive(true);
} }
@ -153,7 +155,7 @@ public class HighPriorityTarget : MonoBehaviour
{ {
HP -= 10; HP -= 10;
string nowData = GetSyncDis(Pos); string nowData = GetSyncDis(Pos);
Debug.Log("发送:"+nowData); Debug.Log("发送:" + nowData);
//DeviceManager.Instance.send2roomStr.Enqueue(nowData); //DeviceManager.Instance.send2roomStr.Enqueue(nowData);
MQTTManager.instance.SendData(MQTTManager.instance.KeyTarget, nowData); MQTTManager.instance.SendData(MQTTManager.instance.KeyTarget, nowData);
} }
@ -207,7 +209,7 @@ public class HighPriorityTarget : MonoBehaviour
UploadLogMain uploadLogMain = new UploadLogMain(); UploadLogMain uploadLogMain = new UploadLogMain();
uploadLogMain.PracticeId = GlobalFlag.practiceSubjectID; uploadLogMain.PracticeId = GlobalFlag.practiceSubjectID;
uploadLogMain.ThinkId = GlobalFlag.currentThinkId; uploadLogMain.ThinkId = GlobalFlag.currentThinkId;
string log = currentTime + " " + "重要用户(" + Number + ")频段设置为" + frequency; string log = currentTime + " " + "重要用户(" + Number + ")频段设置为" + frequency;
uploadLogMain.log = log; uploadLogMain.log = log;
uploadLogMains.Add(uploadLogMain); uploadLogMains.Add(uploadLogMain);
string uploadLogMainJson = JsonConvert.SerializeObject(uploadLogMains); string uploadLogMainJson = JsonConvert.SerializeObject(uploadLogMains);

View File

@ -362,7 +362,7 @@ public class RadarManger : MonoBehaviour
{ {
if (equipmentCommon.isPlayer && GlobalFlag.blueOrRed == 1) if (equipmentCommon.isPlayer && GlobalFlag.blueOrRed == 1)
{ {
GameManager.Instance.GetAllImportance();
imageprs.gameObject.SetActive(true); imageprs.gameObject.SetActive(true);
} }
} }

View File

@ -566,6 +566,7 @@ public class TerrestrialRadioInterferenceManger : MonoBehaviour
{ {
if (!GlobalFlag.isStartRehearsing && GlobalFlag.blueOrRed == 1 && Input.GetMouseButtonDown(0)) if (!GlobalFlag.isStartRehearsing && GlobalFlag.blueOrRed == 1 && Input.GetMouseButtonDown(0))
{ {
GameManager.Instance.GetAllImportance();
Waveimage.transform.position = Camera.main.WorldToScreenPoint(transform.position); Waveimage.transform.position = Camera.main.WorldToScreenPoint(transform.position);
Waveimage.gameObject.SetActive(true); Waveimage.gameObject.SetActive(true);
} }

View File

@ -48,12 +48,14 @@ public class UnmannedAerialVehicleUI : MonoBehaviour
btnFrequencyBand.onClick.AddListener(() => { btnFrequencyBand.onClick.AddListener(() => {
if (unmannedAerialVehicleManage) if (unmannedAerialVehicleManage)
{ {
GameManager.Instance.GetWRJParameter();
unmannedAerialVehicleManage.FrequencyBand.SetActive(true); unmannedAerialVehicleManage.FrequencyBand.SetActive(true);
} }
}); });
btnSurveillanceFrequencyBand.onClick.AddListener(() => { btnSurveillanceFrequencyBand.onClick.AddListener(() => {
if (unmannedAerialVehicleManage) if (unmannedAerialVehicleManage)
{ {
GameManager.Instance.GetWRJParameter();
unmannedAerialVehicleManage.SurveillanceFrequencyBand.SetActive(true); unmannedAerialVehicleManage.SurveillanceFrequencyBand.SetActive(true);
} }
}); });
@ -74,6 +76,7 @@ public class UnmannedAerialVehicleUI : MonoBehaviour
{ {
if (unmannedAerialVehicleManage) if (unmannedAerialVehicleManage)
{ {
GameManager.Instance.GetWRJParameter();
switch (unmannedAerialVehicleManage.wrjModel) switch (unmannedAerialVehicleManage.wrjModel)
{ {
case WRJModel.: case WRJModel.:

View File

@ -10,6 +10,8 @@ TagManager:
- WRJ1 - WRJ1
- AttackTarget1 - AttackTarget1
- Importance - Importance
- Radar
- WRJParameter
layers: layers:
- Default - Default
- TransparentFX - TransparentFX