This is a rant about videos analysing Yandere Simulator& #39;s code that have been bothering me lately.
I want to get this off my chest, so hold on to your hats folks because I& #39;m firing on all cylinders just this once.
tl;dr: Don& #39;t watch them to improve as a programmer.
I want to get this off my chest, so hold on to your hats folks because I& #39;m firing on all cylinders just this once.
tl;dr: Don& #39;t watch them to improve as a programmer.
First, I won& #39;t defend anyone& #39;s or even my own code. I& #39;m highly pessimistic and because of that I have 2 core values:
1. Elegant architecture.
2. Correctness.
Elegance leads to maintainability and correctness, and correctness is a result of simplification which leads to elegance.
1. Elegant architecture.
2. Correctness.
Elegance leads to maintainability and correctness, and correctness is a result of simplification which leads to elegance.
Recently, "professional" programmers have taken to decompiling YanSim and trying to improve it by offering refactoring tips.
Viewers think they& #39;re learning and becoming better programmers themselves from this. It& #39;s a valiant effort, but my core values are never met.
Viewers think they& #39;re learning and becoming better programmers themselves from this. It& #39;s a valiant effort, but my core values are never met.
If you think the solution to a 2000 line method is adding ternaries or splitting into sub-methods, to game state is to have statics, to performance is to not use `Debug.Log()` in your code, etc...
Then you have much to learn.
Then you have much to learn.
If you& #39;re calling yourself competent at and analysing Unity performance, meanwhile apparently oblivious to e.g. the generous amount of calls to `GetComponent()` in critical paths (which analysers would warn you about: https://github.com/JetBrains/resharper-unity/wiki/Avoid-usage-of-GetComponent-methods-in-performance-critical-context)..
Then">https://github.com/JetBrains... you have much, much to learn.
Then">https://github.com/JetBrains... you have much, much to learn.
If you& #39;re analysing a bunch of "UpdateX" methods and don& #39;t see the potential for architectural improvement, or looking at 20 if-statements in a row and the only thing that comes to mind is combining them, then guess what?
You still have much to learn.
You still have much to learn.