dev/verify-custom-chat-peer.cs

A small test/verification script run on a remote (non-host) client that checks a CustomChatExample UI component for expected message counts and privacy. It throws if run on the host, finds the single CustomChatExample in the active scene, asserts specific PrivateResults and OrdinaryMessages values and that no displayed lines contain "private", then returns an object with results.

Networking
if ( Networking.IsHost ) throw new InvalidOperationException( "Connected remote test client required." );
var view = Game.ActiveScene.GetAllComponents<SuperuserCompatibilityLab.UI.CustomChatExample>().Single();
if ( view.PrivateResults != 0 || view.OrdinaryMessages != 2 || view.Lines.Any( line => line.Contains( "private" ) ) )
	throw new InvalidOperationException( "Peer privacy or ordinary delivery check failed." );
return new { Pass = true, view.PrivateResults, view.OrdinaryMessages, view.Lines };