Skip to main content
Each of these runs only while the playtest turns it on in Protokite and the player has allowed it. None of them needs code: the C# calls on this page are for a game that wants its own menus or buttons around them, and they are safe in every build — with no playtest running they answer false, null or TurnedOff. Only three work without one: a test video, the player’s consent answer, and the Steam ID, which is kept for the session to come. The feedback form needs a loaded playtest, but not the player’s consent: it already opens while the consent question waits for an answer, and after an answer of “nothing”. Setting the build up is on the Unity package page.

What the player allowed

The build asks its player what this playtest may collect before it collects anything, and their answer decides what the rest of this page does. Heavy analytics is the playtest’s detailed play data: frame times, memory, scene loads and your own playtest events (Heavy analytics). Your own screen can also allow the recording alone or play data alone, with ProtokitePlaytest.SetPlaytestConsent. ProtokitePlaytest.IsFeatureEnabled already answers for both at once: a feature the playtest turns on and the player left out reads as off, everywhere. Exception capturing follows play data there, but exceptions themselves are the Flock SDK’s, reported with its own setting whatever the player answered.
Drag your HUD’s icon onto Recording Icon in the Inspector: it shows from the moment the playtest has loaded and the player’s answer lets the screen be recorded. ProtokitePlaytest.Config is null unless the status is Ready; LogWhatThisPlaytestCollects logs a line such as Playtest 01J…: video True, play data True, exceptions True, feedback form True.
The feedback form is not covered by that answer. It is sent only when a player fills it in and presses Send, which is their own doing either way — and a form an earlier launch could not send is still sent later, whatever they answered since.

On a phone: which networks recordings upload on

On an Android build that records video, an answer that lets the screen be recorded is followed, on the same panel, by a second question: Upload on Wi-Fi only, or Upload on Wi-Fi or mobile data. The second answer says about how much mobile data a minute of play uses at the recording’s bitrate (about 11 MB at the default 1500 kbps).
A game on a phone showing the playtest's question When your recordings may upload, with Upload on Wi-Fi only and Upload on Wi-Fi or mobile data

On a phone, the second question, after an answer that lets the screen be recorded.

The answer decides only when recordings upload, never whether the screen is recorded. A Wi-Fi only player’s recordings wait on the phone and upload the next time it is on Wi-Fi, in the same launch or a later one, and an upload under way stops when the phone leaves Wi-Fi and is sent again, from the start, on Wi-Fi. Any network that is not the phone’s mobile data (Wi-Fi, Ethernet, tethering) counts as Wi-Fi. The answer is kept on the phone beside the consent answer and used by every later launch. The Protokite session starts once it is given, so each session start carries playtest_upload_network: wifi_only, wifi_and_mobile_data, or not_asked (a desktop, a build that asks nobody, or an answer that records nothing). The screen is recorded meanwhile; a game closed while the question is still open has no session for those seconds, and the next launch deletes them. Nothing is asked on Windows, and nothing waits there. Your game can show the answer and change it from its own settings screen:
The answer applies at once, and the Console says what it allows. ProtokitePlaytestUploadNetworkChoice.NotAnswered forgets it, so a phone build that asks puts the question again.

Starting and ending sessions and recordings

A Protokite session is a stretch of play, as it shows on the playtest’s Sessions page. By default each launch runs one, started by itself once a player is signed in (see Watch it run), with one recording of the screen. A game that wants a session, or a recording, for one part of play only (a level, a match, a booth visitor’s turn) turns off Start Session And Recording Automatically in Protokite → Playtest → Settings and calls these on ProtokitePlaytest, on the main thread: The start and end calls say in the Console why they returned false. One session and one recording run at a time, and a launch may hold several of each. A recording always goes to the session open while it recorded, never a later one; one that uploaded is deleted before the next starts, and one that did not is kept on disk with its session, for a later launch to upload. Recordings made while no session is open are all kept, and all go to the next session started. With the setting on (the default), the first session and recording start by themselves, and every session the game starts later gets a recording of its own too; these calls are there to end them and start more. ProtokitePlaytest.PlaytestSessionId is the open session’s id, and null before it starts and once it has ended.
A new session or recording cannot start while a session is ending: start the next level’s from ended, or once it has been called. While the player’s answer is Wi-Fi only and the phone is off Wi-Fi, EndPlaytestSession ends the session at once and the recording waits on the phone, uploading to that session once it is on Wi-Fi. A game that quits while a session is ending ends it then, and ended still hears how it went.

Video recording

The game’s screen is recorded from the moment the playtest loads and the player has allowed it, before anyone signs in: one recording per launch by default (your game can start more: see Starting and ending sessions and recordings), encoded as H.264 by the graphics card’s own video encoder (the phone’s, on Android) and written as it records into an MP4 file a browser plays with nothing installed. A recording cut off by a crash keeps every frame before the cut. Time the game spends in the background is left out. The settings are in Protokite → Playtest → Settings: the first four under Video recording (64-bit Windows), which a Windows build and the editor read, and the last three under Recordings (every platform). Android players read their own section, Video recording (Android); see Recording on a phone. The frame is copied, scaled and converted on the graphics card, read back without waiting for it, and encoded on the graphics card too; handing frames to the encoder and writing the file each run on a thread of their own, and a frame that cannot keep up is dropped rather than stalling the game. When a recording ends, the Console says what it holds, which encoder made it, and how many frames were dropped, and why.

When a recording is uploaded

Uploads are automatic: there is no call to make. The Console shows [Protokite Playtest] lines saying when an upload starts, when it is done, and why a recording was kept, and your game hears the same through ProtokitePlaytest.RecordingUploadChanged, raised on the main thread with a ProtokitePlaytestUploadUpdate: Every update names the recording’s Protokite session in PlaytestSessionId. FromAnEarlierLaunch is true for a recording an earlier launch kept; those are told about once their upload begins, so one held back for Wi-Fi from the start of the launch is told WaitingForWiFi only if an upload of it had begun. Nothing is raised while the game quits. A handler that throws is logged and stops neither the upload nor the other handlers.
A recording is uploaded to its session once its file is finished and the session has started, whichever comes second. A file is finished when:
  • it reaches Max Recording Minutes or Max Recording Size Mb;
  • the player presses Upload your recording on the feedback form, or your game calls ProtokitePlaytest.StopRecordingAndSendIt();
  • your game stops it with ProtokitePlaytest.StopVideoRecording() or EndPlaytestSession, such as at the end of a demo:
StopVideoRecording returns false when nothing is recording; ProtokitePlaytest.IsRecordingVideo says whether the playtest’s recording is capturing (a test video does not count). On a phone whose player chose Wi-Fi only, it also waits until the phone is on Wi-Fi (see On a phone: which networks recordings upload on). It is sent straight from disk, never whole in memory, and counts as uploaded only when the storage accepts the file itself. A failed upload is tried once more. An uploaded recording is deleted from the machine; one that was not is kept with its session, and the Console says why.
Quitting does not upload. A whole recording cannot be sent while the game closes, so a recording still going at quit is finished and kept, and the next launch sends it. A later launch sends every recording an earlier one kept — a failed upload, a quit, a crash — oldest first, even with Playtesting Enabled off, so a release build never strands what a playtest build recorded. A recording no session ever started for is deleted, since it can never be sent.
Offer the player a button of your own only while ProtokitePlaytest.CanSendTheRecording is true. It is false when no session has started for the recording, and a button pressed then would stop the recording and send nothing:
Pressed, the Console shows [Protokite Playtest] The player asked for their recording to be sent., and the upload lines once the file is finished.

Room on the player’s disk

Recordings Disk Budget Mb (on Android, Android Recordings Disk Budget Mb) is the most every recording kept on the machine may take together. Before a recording starts, recordings earlier launches left are deleted until it fits: test videos first, then recordings waiting to upload, the oldest first. One being uploaded, or still held by a copy of the game that is running, is never deleted. A recording makes room only for what its length limit records at its bitrate, with a quarter to spare (about 810 MB at the defaults), so a short recording never deletes one it would fit beside. With less than 1 MB left, that launch records no video, and a warning names the setting to raise. While a phone’s uploads wait on the player’s answer (Wi-Fi only and the phone off Wi-Fi, or the question still to be answered), a recording waiting to upload is never deleted for a new one: the new one records into the room left, and with less than 1 MB records nothing that launch and the Console says why. At the default 1024 MB, about 94 minutes of play can wait for Wi-Fi in full. Recordings also never take a phone’s free space below the line where Android warns that storage is running out (500 MB, or 5% of the storage when that is less): a fuller phone gives a recording less room. A recording cut off by a crash, a power cut or a killed game is finished by the next launch with every whole frame it holds, then uploaded to its session like any other; one whose session never started is deleted.

Recording on a phone

Android players read their own section of Protokite → Playtest → Settings, Video recording (Android): A recording stopped for heat or the battery is kept and uploaded like any other. Max Recording Minutes and Max Recording Size Mb apply on every platform. A phone whose encoder does not take the video’s size or rate records at the next size down it does, then at 15 and 10 frames a second, and the Console says which. When the game goes to the background, everything the recording holds is written to its file, so a game Android ends while it is away keeps every frame recorded before it left. The phone’s encoder is given back meanwhile, and the first frame after the return starts again on a keyframe in the same file.

Heavy analytics

The playtest sends these through the Flock SDK’s analytics, under the playtest category, and they read on Dashboards → Game Metrics:
  • performance_window, for every ten seconds of play: the median, 95th and 99th percentile frame time (the time 95 or 99 frames in 100 stay within, so the slowest frames show), hitches (a hitch is a frame slow enough to see as a stutter: one that took Hitch Frame Time Ms, 60 by default, or longer), memory used and at its peak, and map, the active scene. A frame time is the real time from one frame to the next, so slow motion or a paused game is measured as the frames the player saw.
  • level_loaded, for every scene the game loads in place of the one before, with the scene before it and load_seconds, how long the load held the game up.
  • Your own events, on the same timeline and in the same category:
RecordPlaytestEvent answers true when the event was queued, can be called from any thread, and sends only while heavy analytics runs, which starts once the playtest has loaded; an event recorded earlier in the launch answers false and is not kept. The two names the playtest sends itself, performance_window and level_loaded, are refused. The event shows on Dashboards → Game Metrics, under playtest, once the Flock SDK has sent it. Heavy analytics needs the Flock SDK’s Analytics Enabled, on the Advanced Settings tab of Flock → Settings: with it off, nothing is measured and the Console says so once. The events are Flock events like any other, so they wait for a signed-in player and follow the Flock SDK’s own analytics consent. See Analytics & events for how the category and the dashboards fit together.
Played offline, six windows a minute fill the Flock SDK’s offline queue (Analytics Max Cached Events, under Analytics Settings on the Advanced Settings tab, 1000 by default) in under three hours. Raise it for playtests your testers play offline.

Exceptions

Exceptions stay the Flock SDK’s. It captures the game’s exceptions from every thread, and faulted tasks nobody awaited, with Analytics Capture Exceptions in Flock → Settings → Advanced Settings (on by default), and reports them on Diagnostics → Errors. A playtest’s exception switch never turns that on or off. With the Flock SDK’s switch off, the live self-test’s exception step is skipped and names it; the SDK’s Analytics.GetExceptionCaptureCoverage() says what the capture hears. The same exception thrown again and again reaches the dashboard as one report, then one repeat report counting the others once the repeat window (Analytics Exception Repeat Window, 60 seconds) closes. Debug.LogError lines are not exceptions and are not reported.

The feedback form

When the playtest publishes a feedback form in Protokite, the player opens it over the game with F9 and fills it in. It is built from what you published — every question, label, help text and option — so editing the form in Protokite needs no new build: text, many-line text, a rating from 1 to 5, a choice of options, and a checkbox. A question of a kind this package does not know yet is a text box, which is how Protokite reads it. It is the player’s own message, so it opens and sends whatever their consent answer, “nothing” included; it never opens over the consent question.
A playtest feedback form over a Unity game, with a rating, a choice, text answers and an Upload your recording button

A published form, drawn from the playtest: every question, the button that sends the recording, and Powered by Qwacks at the bottom left.

Some of these settings need a recent package, as the table says (“Version 1.100.0 or later”). To find yours, open the Playtesting tab of Flock → Settings: it reads Installed: version …, the same version as your Flock SDK. A package added through Package Manager also shows its version in Package Manager.
  • Send checks the answers the way Protokite does, and shows every problem against its question before anything is sent: a required question left empty, a rating out of range, an option the question does not offer. A required checkbox counts when it is left unticked, and an empty optional answer is left out rather than sent empty.
  • A sent form is kept on the device first and sent from there, so neither a closed game nor a lost network loses it: one that could not go now is sent when the network comes back, two minutes later, or by a later launch. One Protokite refuses for good is deleted, and the Console names the question it refused. It names this launch’s Protokite session once one has started, and is sent with the Game Version ID it was filled in under.
  • A form that names no session, whose send failed after Protokite may already have stored it, is sent again: you may see that report twice rather than lose it. One naming a session is replaced, never added.
  • Closing it without sending keeps what was typed for the rest of the launch. Escape in a text box does nothing, and a click puts the caret where it lands rather than selecting everything.
  • Upload your recording appears while this launch records the screen and its session has started: it stops the recording and sends it now. Opening the form never stops the recording on its own.
  • With Unity’s old Input Manager, Unity’s runtime UI misses the odd quick click, or takes it where the cursor has moved to (up to 10 in 100 measured; the Input System missed none). Nothing wrong is sent: the player sees the click did nothing, and clicks again.
Your game still reads its own keys while the form is open. A game that moves on WASD, or opens a menu on Escape, should ignore its input while ProtokitePlaytest.IsFeedbackFormOpen is true, or turn on Pause The Game While The Form Is Open. While the form is open the cursor is shown and free. A click in the form’s first half second is ignored, and so is one while the game locks the cursor again every frame (a warning says so).

Open it from your own button

F9 works with no code. To open the form from a button of your own, show the button only while there is a form to open, and call OpenFeedbackForm when it is pressed:
  • CanOpenFeedbackForm is true once a playtest with a published form has loaded, whatever the player’s consent answer. It is false with no playtest, with a playtest that publishes no form, and before the playtest has loaded.
  • OpenFeedbackForm() returns false when there is no form, one is already open, the consent question is on screen, or nothing can be drawn (batch mode, no graphics). CloseFeedbackForm() closes it without sending and keeps what was typed.
  • CanSendTheRecording and StopRecordingAndSendIt() are what the form’s recording button does, for a button of your own (see When a recording is uploaded).

A form of your own

A game that draws its own form reads the questions from ProtokitePlaytest.FeedbackForm and sends the answers through the same checking and keeping as the built-in form. Each answer is recorded by the question’s Id, so read the ids from the form rather than typing them: the studio can change the questions in Protokite without a new build.
IsAnswered(id) says whether anything was recorded for a question, a rating of 0 or an empty option included (they are sent as unanswered, yet IsAnswered stays true); Remove(id) takes an answer back entirely and Clear() empties them all. An answer under an id the form does not have is left out when sending, not refused, so a typo loses that answer quietly: take ids from form.Fields. Finding problems. FindProblems(form) checks the answers the way Protokite does and returns one problem per question (FieldId, and a Message to show beside it): “This one is needed.” for a required question left empty, “Choose a rating from 1 to 5.” and “Choose one of the options given.”. An empty list means Protokite would take the form. What sending tells you. SendFeedbackForm returns true when the answers are kept on this device, not when Protokite has them: sending happens in the background, and nothing is lost if the game closes or the network drops meanwhile. It returns false, with a warning in the Console, when no playtest with a form is loaded, no answers were given, FindProblems is not empty, or the answers could not be kept. What happens next shows only in the Console: A game cannot wait for the answer from Protokite: there is no event or result for it, only these lines. Forms waiting to be sent are kept in ProtokitePlaytest/FeedbackForms under the game’s persistent data folder, one file each, with no API key in them.
Two rules are easy to miss. Set every checkbox, ticked or not: the server counts an unticked box as an answer, and a needed checkbox that was never set is missing. And a chosen option must match letter for letter — the server compares options exactly, so bug is not Bug.

Calls your game can make

All on ProtokitePlaytest, in the Protokite.Playtest namespace. Call them from the main thread; RecordPlaytestEvent also works from any other. A game with Steam can name the player by their Steam ID instead of this install’s device ID. Call it before your game signs the player in to Flock, since the session starts after that. This block needs the Steamworks.NET package, with Steam running:
An ID that is empty, longer than 64 characters or holds a space is refused, and the device ID is sent. One set while a session is starting or open is refused, and changes nothing until the next session.

The sample

The package’s sample is one component, ProtokitePlaytestSample, that draws a panel of buttons over the Game view in Play Mode. It comes with the package:
  • Installed from the Playtesting tab or the .unitypackage: Assets/ProtokitePlaytest/Samples/PlaytestSample/.
  • Installed with Package Manager: Packages → Protokite Playtest → Samples → PlaytestSample in the Project window.
Set the playtest up as on the Unity package page, create an empty GameObject in a scene, press Add Component in the Inspector, type Protokite Playtest Sample and pick it, then press Play. It signs in with this device, and shows the status, the playtest and its session, the features on, the consent answer and the question, the upload network answer, a Steam ID, a playtest event, the recording, the feedback form (opened, sent from code and closed from code) and a test video. It does not set the upload network or run the live self-test: those are on this page.
The Protokite Playtest sample's panel of buttons at the top left of the Unity Game view

The sample's panel over the Game view in Play Mode, signed in, with a playtest loaded and its session started.

Trying it in the editor

The setup window, Protokite → Playtest → Setup Checks And Test Video, has everything for testing in its lower half. In Play Mode it looks like this:
The Protokite Playtest setup window during Play Mode, with the While testing, Test video and Live self-test sections

The whole setup window in Play Mode: Setup checks at the top, then Test video, While testing and Live self-test.

  • Forget This Machine’s Answer forgets this machine’s answers, so the next Play asks the consent question again.
  • Open Feedback Form opens the form the way its key does.
  • Record Test Video records the Game view for the seconds you set, with the video settings and no playtest needed: playtesting off and nobody signed in is fine. A test video is saved under ProtokitePlaytest/Recordings/TestVideos/ in the game’s persistent data folder, never uploaded, and the window shows where it went. It is refused while the playtest’s own recording runs, and gives way to it. Like all video, it records on 64-bit Windows and Android; in the editor it uses the Windows settings.
  • Run Live Self-Test checks the whole playtest against your real Protokite (below).
A game can record a test video itself, from a debug menu’s “record a clip” button for instance. It records in Play Mode or a player; outside Play Mode it is refused, with the reason:
TestVideoState is None until a test video is asked for, then WaitingToStart, Recording, Finishing, and last Finished (FinishedTestVideoPath is the file) or NotRecorded (TestVideoProblem says why).

Checking a playtest build

The live self-test checks everything a playtest build does against your real Protokite in one go, and logs a line per step and a count at the end. Run it in Play Mode with Run Live Self-Test, or from code in the editor or a development build (a release build refuses it):
NotRunBecause says why nothing ran: a release build, another self-test under way, or the Flock SDK not running. Each step has a Name, an Outcome (Passed, Failed or Skipped) and a Detail; AllRunStepsPassed is true when it ran, nothing failed and at least one step passed. The self-test also logs every step itself, as [Protokite Playtest] Self-test: lines. Each check sits beside a request Protokite must refuse: a wrong API key, a missing one, a version no playtest is linked to, a session start that names no player, a form missing a needed answer or choosing an option that is not on the list, and a form, an upload link and an end for a session that does not exist. A check that only ever succeeds cannot tell a working build from a broken one, so a refusal passes only with its own HTTP status and, for a form, the question it names.
  • Sign a player in first, and answer the consent question. It signs nobody in; steps that need a session or an answer are skipped, saying why.
  • Run it in a Play or launch of its own. It stops this launch’s recording to upload it, sends a filled-in form that replaces one the player sent this launch, and raises two exceptions on purpose — so with Error Pause on in the Console, Play pauses there until you resume it.
  • It leaves a trace on your dashboards: one filled-in form on the session, one playtest_self_test event, one exception raised twice so its repeat is counted, and the launch’s recording. Each carries the run’s id (report.RunId), so you can find them in Flock and Protokite.
  • A step is skipped, saying why, when the playtest does not turn its feature on, when the build has no video encoder (every platform but 64-bit Windows and Android), and for a closed playtest unless you name one: pass a closed playtest’s Game Version ID to RunAsync, or type it into Closed Playtest Version ID in the window.

What stays on the player’s machine

Under ProtokitePlaytest/ in the game’s persistent data folder (Application.persistentDataPath):

Platforms

Everything on this page runs wherever the Flock SDK runs, except video. Video is recorded on 64-bit Windows, in the editor and in players, Mono and IL2CPP alike, through Windows’ own H.264 encoder on the graphics card. The package ships no native file, so Windows 11’s Smart App Control has nothing of the package’s to refuse. A PC whose graphics card has no H.264 encoder records no video and says why once in the Console, unless Allow Software Encoder is on; so does a Windows N edition without its Media Feature Pack. The setup window names the encoder Windows offers first on your own PC, and a test video shows whether it records. Recording runs on Direct3D 11 and 12, Vulkan and OpenGL, in the Built-in Render Pipeline and URP, in Linear and Gamma colour, and needs a graphics card that runs compute shaders. On Android the screen is recorded with the phone’s own hardware H.264 encoder, so the package ships no native file there either. It is measured on one flagship phone (a Galaxy S23 Ultra), so treat its figures as a best case. Against the same game built without the package, drawing 400 moving lit cubes at the phone’s full resolution at 60 frames a second, a recording at the defaults cost no frame rate in IL2CPP (64-bit) or Mono (32-bit) players, and collecting play data alone cost nothing measurable. What recording does cost sits on the one frame in four that is captured: about 1 to 3.5 ms more of the graphics card’s time and up to 2 ms more of the render thread on those frames, and about 6% of a processor core in the phone’s media service; a Mono build’s main thread also spends about 3 ms more on them. The package adds about 7 MB to an IL2CPP build and 1.4 MB to a Mono one. Android players read their own settings (see Recording on a phone). A phone whose graphics cannot run compute shaders, or that has no hardware H.264 encoder, records no video and says why once. Unity builds Mono for 32-bit ARM only; a 64-bit build is IL2CPP. x86 Android devices are not measured. “No video on this platform” means exactly that and nothing more: a build for any other platform — macOS, Linux, iOS, WebGL, or 32-bit or ARM64 Windows — has no video encoder, says once in the Console that it records no video, and runs everything else: the session, the consent question, heavy analytics, exceptions and the feedback form. The setup window tells you in advance: “Players built for … record no video”. A game that draws nothing (a server build, or one started with -nographics or -batchmode) records nothing either, and cannot show the consent question: answer it from code with SetPlaytestConsent, or turn asking off. On WebGL the playtest’s files — the consent answer, the device ID and feedback forms waiting to be sent — are copied to the browser’s storage after every change, so they are there on the player’s next visit wherever the browser keeps the site’s data. A private window forgets them when it closes.