This commit is contained in:
账号名 2024-01-17 16:38:10 +08:00
parent b742070f23
commit 37263081db
1 changed files with 2 additions and 2 deletions

View File

@ -178,7 +178,7 @@ public class UnmannedAerialVehicleManage : MonoBehaviour
break;
}
var _unmannedAerialVehicle = unmannedAerialVehicles.FindAll(x => x != null&&x.gameObject.activeInHierarchy);
var _unmannedAerialVehicle = unmannedAerialVehicles.FindAll(x => x != null&&x.gameObject.activeSelf);
if (_unmannedAerialVehicle.Count == 0)
{
string nowData = string.Format("{0},{1}", "SetToBeDestroyed", equipmentCommon.deviceID);
@ -264,7 +264,7 @@ public class UnmannedAerialVehicleManage : MonoBehaviour
isEngagedTarget = true;
colliders1.ForEach(x => Debug.Log(x.transform.name));
int _number = UnityEngine.Random.Range(0, colliders1.Count - 1);
List<UnmannedAerialVehicle> _unmannedAerialVehicles = unmannedAerialVehicles.FindAll(x => x != null&&x.gameObject.activeInHierarchy);
List<UnmannedAerialVehicle> _unmannedAerialVehicles = unmannedAerialVehicles.FindAll(x => x != null&&x.gameObject.activeSelf);
SendMsg(colliders1[_number].transform);
for (int i = 0; i < _unmannedAerialVehicles.Count; i++)
{