Google.Maps.PlayableLocationsService

The entry point for using Playable Locations.

Summary

Inheritance

Inherits from: MonoBehaviour

Public types

BadLocationReason{
  Other,
  NotPedestrianAccessible,
  NotOpenToPublic,
  PermanentlyClosed
}
enum
Reason for reporting a bad playable location.

Public functions

ReportBadPoint(string placeId, BadLocationReason reason, string reasonDetails, ReportBadPointStatusCallback statusCallback)
void
Submits a bad place report to the server.
ReportInteractedPlace(int gameObjectType, string placeId)
void
Reports that the user interacted with the game object placed at this playable location.
ReportPresentedPlace(int gameObjectType, string placeId)
void
Reports that a game object placed at this playable location was presented to the user.

Classes

Google.Maps.PlayableLocationsService.ReportBadPointStatus

Encapsulates the status of the completed request for submitting a bad place report.

Public types

BadLocationReason

 BadLocationReason

Reason for reporting a bad playable location.

Properties
NotOpenToPublic

Location is not open to everyone. For example, a private office building.

NotPedestrianAccessible

Location is not accessible to pedestrians. For example, location is in the middle of a highway.

Other

Reason not included in the following list. Clients must provide reasonDetails with more information.

PermanentlyClosed

Location is permanently closed. For example the shop at that location has been shut down.

Public functions

ReportBadPoint

void ReportBadPoint(
  string placeId,
  BadLocationReason reason,
  string reasonDetails,
  ReportBadPointStatusCallback statusCallback
)

Submits a bad place report to the server.

After the request finishes, the ReportBadPointStatus parameter of the callback is populated with information about whether the request succeeded. Internally, the network requests are retried multiple times in case of failures.

Note:reasonDetails must be non-empty.

Details
Parameters
placeId
The ID of the place to report.
reason
The primary reason why this is a bad place for gameplay.
reasonDetails
Freeform text explaining why the user reported this place.
statusCallback
The callback to call when the request completes.

ReportInteractedPlace

void ReportInteractedPlace(
  int gameObjectType,
  string placeId
)

Reports that the user interacted with the game object placed at this playable location.

For more information about gameObjectType, see ReportPresentedPlace().

Details
Parameters
gameObjectType
The type of game object placed at this playable location.
placeId
The place identifier.

ReportPresentedPlace

void ReportPresentedPlace(
  int gameObjectType,
  string placeId
)

Reports that a game object placed at this playable location was presented to the user.

Google uses the information logged in ReportPresentedPlace and ReportInteractedPlace to improve the quality of playable locations. This is done by comparing how often game objects placed at different playable locations are visited by players.

Because different game object types (for example, monster and powerup) are expected to be visited with different frequencies, you must assign a gameObjectType to each playable location (for example: monster=0, powerup=1). This is used to bucket reports into comparable events. There should be only a small number of unique game object types—ideally no more than 10.

You can call this method repeatedly with the same Place IDs. The SDK only reports places to the server if they haven't been reported before, or if the player interacted with the game object placed at the playable location since the last report.

Note: You are free to define what presented means, as long as you use that definition consistently. One possibility is to report all playable locations the lie within 500 meters of the player.

Details
Parameters
gameObjectType
The type of game object placed at this playable location.
placeId
The place identifier.