Please make sure you have completed the following checklist:
- Register as a new BugSplat User.
- Log in using your email address.
- Download the BugSplat Unity package.
The BugSplat Unity package handles all installation or update of the needed files. Double click on this file to launch Unity, create or select a project, and the BugSplat tool will be imported. After unpacking, the tool will be ready to be used. (Note: At least for our team, Mac users have to manually import the package contents.)
Exploring the BugSplat Sample
To get a feel of the BugSplat service before using it in your application, try out the debug scene embedded as a sample in the BugSplat Report Tool.
Double-click the debug scene icon found in the projects tab.
Hit the Play button and you will see our example running as shown below. The scene consists of three test buttons and an animated cube.
The Prompted Exception button will send an interactive crash report. A pop-up dialog will ask the user to provide some information and confirm that the crash report should be sent to BugSplat.
The Custom Exception button will create a report using a custom Exception (i.e., created using throw new Exception(“msg”).
The Null Reference Exception button will force a Null Reference Exception (i.e., a common runtime exception in Unity).
By default, crashes are posted to the BugSplat database ‘Fred’. Login at the BugSplat website with username Fred and password Flintstone to view these crash reports.
If you would like to post crashes to your own database, select the app GameObject and it will show the Reporter variable Inspector. Provide your own values for Database, App, Version and the optional Key parameters.
Integrating Into Your Game
Follow the steps below to create a Reporter instance that will handle the detection of Errors and also allow users to send their own reports to the BugSplat server.
- Create an empty script or use one already created.
- Create a Reporter variable. Don’t forget to add using BugSplat; directive.
- On the Start or Awake method call reporter.Initialize() so it will start watching for Exceptions.
- Add your script to a GameObject and check that the reporter Inspector is available.
- Configure and fill the fields with data of your BugSplat account:
|Quiet||Flag that allows ReportComponent to emit debug logs so the user can confirm things are working.|
|Database||Target database where reports will be sent|
|App||App name string|
|Version||Version string of the app|
|Previous||Last sent report|
|Logs||List of detected Unity logs|
|Ignored||Number of ignored repeated reports|
|Count||Number of Reports sent|
|Generate Screenshots||Flag that allows the capture of screenshots before a Report is generated|
|Generate Log File||Flag that allows the creation of a text file with all logs before the Report|
|Prompt||Flag that allows the use of a dialog before sending a Report|