public override void OnPlayerEnteredRoom(Player newPlayer) { if (PhotonNetwork.CurrentRoom.PlayerCount >= 1) { if (PhotonNetwork.IsMasterClient) { PhotonSendEvent.SendHintsAndBoardLatAndLong(PhotonNetwork.CurrentRoom.PlayerCount); } } }
public double[] GetCurrentLocation() { if (Input.location.status == LocationServiceStatus.Failed) { print("Unable to determine device location"); double[] userLocation = new double[] { 0, 0 }; PhotonSendEvent.SendCurrentUserLocation(userLocation); return(userLocation); } else { double[] userLocation = new double[] { Input.location.lastData.latitude, Input.location.lastData.longitude }; PhotonSendEvent.SendCurrentUserLocation(userLocation); return(userLocation); } }