void start() { Debug.Log("Start"); targetName = ""; callback = false; plugin = IAPlugin.pluginWithGameObjectName(gameObject.name); }
void Start() { Debug.Log("in UserLocation.Start"); // In this case, gameObject is Canvas. gameObjectName = gameObject.name; Debug.Log("gameObject name: " + gameObjectName); // Create a singleton plugin instance with the gameObject's name. plugin = IAPlugin.pluginWithGameObjectName(gameObjectName); // Button for testing Unity–Android communication. // When user clicks on the button, an empty string text ("") in Canvas should be changed. // startLocationUpdatesButton.onClick.AddListener (plugin.startLocationUpdates); Debug.Log("exiting UserLocation.Start"); }