The short answer: bind a key (or a pause-menu button) that grabs a screenshot, the end of the log and the player's system info, and opens a short form for them to describe what happened. This guide sets that up in a Unity game in about ten minutes, with a way to reply to the player afterwards.
Beta The Unity package is new. If something doesn't work in your project, tell us and we'll fix it.
What makes a game bug report useful?
- A screenshot of the moment, since "the boss got stuck" can mean many things.
- The game version, OS, GPU and graphics API, because many game bugs are hardware-specific.
- The tail of the log, with the exceptions and their stack traces that led up to it.
- Game state such as the scene, level or save slot, so you can get to the same spot.
- A way to reach the player, to ask a follow-up question or tell them it's fixed.
Step 1: Create an app in StareGlare
Start a free trial (30 days, no card) and create an app for your game. Its Install tab has your app slug and public key.
Step 2: Add the package
Download the StareGlare package (MIT licensed, source
included) and keep it inside your project, for example in Packages/. In Window → Package
Manager, click +, choose Add package from tarball… and pick the file. It
works with Unity 2021.3 and later and has no dependencies.
Step 3: Fill in two settings
Choose Assets → Create → StareGlare → Settings and save it as Assets/Resources/StareGlareSettings.asset. StareGlare starts on its own when the game does. In the
Inspector, set:
App Slug = your-game
Public Key = stareglare_pk_… Players can now press F9 to report a bug, with the Input System or the legacy Input Manager. You can pick another key, or None, under Hotkey. The package keeps the last 256 KB of the log while the game runs, so there is nothing to turn on for it.
Step 4: Add a button and some context
// From your pause-menu button:
StareGlare.Report();
// With extra details for this report:
StareGlare.Report(new Dictionary<string, object> { ["level"] = "forest_3", ["difficulty"] = "hard" });
// Sent with every report from now on:
StareGlare.SetContext("save_slot", 2); StareGlare needs no using. If your scripts have an assembly definition of their own, add a
reference to StareGlare.Runtime.
Step 5: Ask for a report after a crash
The package notices when the last session didn't exit cleanly: a crash, a freeze the player force-quit, or a
power loss. Reports sent in the next session then also carry the previous session's log (Unity's Player-prev.log; the log files page says where it is on each
platform) and are marked as a crash in your inbox. To ask the player right away:
StareGlare.CrashedLastSession += () =>
{
// Show your own "The game closed unexpectedly. Send a report?" dialog, then:
StareGlare.Report();
}; Nothing is sent on its own. Detection is off when you run the game in the editor.
Step 6: Send a test report and reply
Build the game, run it, press F9 and send a report. It arrives in your inbox with the screenshot, log and system info. If the player left an email, your reply reaches them by email and their answer threads back into the same report.
Optional: capture exceptions on their own
Turn on Capture Exceptions and uncaught exceptions go to the game's Errors tab, where identical ones are grouped and counted per version, at most 30 a session. Only do this if your privacy policy says the game reports errors on its own.
Questions
How do players report bugs from a Unity game?
Give them a key or a pause-menu button that captures a screenshot, the tail of the log and system info, then opens a short report form. The StareGlare Unity package does this with one call, StareGlare.Report(), and binds F9 by default.
Which Unity versions and platforms does the package support?
Unity 2021.3 and later, on Windows, macOS and Linux builds. The package is in beta. WebGL is best effort: the package opens the report page link without a screenshot or log. Mobile is untested.
Does it work with the new Input System?
Yes. The hotkey works with the Input System package, the legacy Input Manager, or both. The package has no other dependencies.
Does the package send anything without the player knowing?
Not by default. It only stages the screenshot and log on a short-lived session. The player sees what is attached on the report page and chooses whether to send it. Sending exceptions on their own is a setting you turn on yourself.
Can I attach the level or save slot to the report?
Yes. Pass a dictionary to StareGlare.Report(), or call StareGlare.SetContext(key, value) once and it is sent with every report.
Related guides
- How to add a bug report button to your website
- How to add a custom feedback form to your website
- How to collect bug reports from a macOS app
- How to get crash reports from a macOS app
- How to collect bug reports and crashes from an iOS app
- How to collect bug reports from a Godot game
- How to track JavaScript errors on your website
All 9 guides, from the first report to the fix.