Tag: C#
All the articles with the tag "C#".
On Android, escape Is the Back Button
The advice to split with #if UNITY_EDITOR because play mode doesn't stop is correct. But ship this script to Android and the back button becomes a quit button — and the docs don't recommend this function on Android in the first place.
A One-Way Platform Is an Angle, Not a Direction
Finding PlatformEffector2D is the right answer. But what the component actually evaluates isn't 'did you come from above or below' — it's whether the contact normal falls inside an arc. Not knowing that angle is what snags you at the edges.
Fake Null on Unassigned Fields Only Happens in the Editor
The explanation of how fake null works is accurate. But the 'reduce the cost' list that follows it is almost entirely off — it calls something cheaper that runs the exact same function, and two of its snippets don't compile.
Thousands of Players on Mirror? The Official Guide Says 200-300 Per Instance
The steps for wiring up a multiplayer room with NetworkRoomManager are worth following. But the scale claim in the intro is off by an order of magnitude from Mirror's own guide, and the way it pairs the four scene fields is the reverse of the source comments.