private void RemoveOutOfRangeBeacons() { for (int i = 0; i < mBeacons.Count; i++) { EstimoteUnityBeacon beacon = mBeacons [i]; if (beacon != null && beacon.LastSeen.AddSeconds(_LastSeenSeconds) < System.DateTime.Now) { mBeacons.RemoveAt(i); } } }
public void Setup(EstimoteUnityBeacon eb, EstimoteUnity estimoteUnity) { mEstimoteUnityBeacon = eb; mEstimoteUnity = estimoteUnity; _UUIDText.text = "UUID: " + mEstimoteUnityBeacon.UUID; _MajorMinorText.text = "Major / Minor: " + mEstimoteUnityBeacon.Major + ":" + mEstimoteUnityBeacon.Minor; _DistanceText.text = "Distance: " + mEstimoteUnityBeacon.Accuracy; GetComponent <Button> ().onClick.AddListener(delegate() { mEstimoteUnity.GetBeaconCloudDetails(mEstimoteUnityBeacon); }); }