79427800

Date: 2025-02-10 17:13:25
Score: 2
Natty:
Report link

If I recall correctly TryGetComponent(out T component) also avoids some minor memory allocation while you're in Editor, so it can be considered a micro-optimization during development. Apparently that memory allocation doesn't occur in the built Player, so for builds GetComponent and TryGetComponent should have similar performance.

Reasons:
  • No code block (0.5):
  • Single line (0.5):
  • Low reputation (1):
Posted by: KesKim