Solid tips for beginner trying to get more serious with coding in unity. Great video!
@valkoinendev16 күн бұрын
Rarely wish a video was longer but this is one. Well done.
@swagmuffin411gaming818 күн бұрын
As a professional software developer let me say #2 Comments when you said "Use them frugally" made me very sad. Document everything brothers. More is better than less I promise. If your game pops off and some other company wants to port it they will thank you.
@useronetwothree-z6f23 күн бұрын
great video i use those tips in my big unity project
@aleksp876824 күн бұрын
SerializeField gang!
@ChapCanaiАй бұрын
After watching this video, I kinda regret doing composition over inheritance
@notBradYourselfАй бұрын
Not naming variables "yourmom" is an advanced tip? 😂
@cimbyoteАй бұрын
So, this video basically summarizes like 80% of what I learned getting a degree in Software Engineering/Real Time Systems. Obviously lacks depth (how could you in a 22 min video) but is an amazing resource.
@da3l_525Ай бұрын
why do you look like you hate the day you born
@AlexPBentonАй бұрын
You can use Invoke with the actual function itself, not just the string name. This helps prevent typos and lets you refactor more easily
@felipesuarez4820Ай бұрын
I had to give a like to this good hearted gentleman for sharing this treasures with us 🥹❤👍
@narf0339Ай бұрын
for breaking a big function into multiple smaller functions, should put those smaller functions in the big function, unless they are being shared by other function in the class, so u can easily know those smaller functions only work in that scope of that big function.
@narf0339Ай бұрын
i have a noob naming method, all functions start with fct, all integer variables start with int, all string variables start with str, etc. so i dont have to remember all the variable name, i just need to remember their type, when i need to use them, when type int, fct, or str ... autocomplete(or intellisense) will give me a list to choose from. works well until there are too many variables or functions in the same scope, then i will start to split code into different scope.
@VariapolisАй бұрын
As someone with a few years of professional dev experience, I still use "yourmom" as a variable name in prototyping. I've actually used it more and more over time.
@radiofloyd2359Ай бұрын
Half the time my debugs return "minou" (Kitty in french) or something equally stupid, and I'll call my variables stuff like that too if I'm only trying to get a hang of the conceptual logic for the code.
@TwoHornsYoutubeАй бұрын
Thank you so much for this video bro! 💛
@nasther2 ай бұрын
This is awsome! Many cool things.
@khushalkhan832 ай бұрын
ScriptableObjects were introduced in Unity 3.5, which was released in 2012. This feature has since become a powerful tool for managing data and creating modular systems in Unity, allowing developers to store data outside of scene files and reduce dependencies between game components.
@local.interloper2 ай бұрын
Another tip: When using Invoke, instead of writing the func name yourself, use nameOf(MethodName), that way you will get an error if you misspell the method name.
@VyvyanTheGreat2 ай бұрын
So much great info here! Perfect!
@bil4x4672 ай бұрын
Great video! Just a tip, do not use == to compare null as it can be overloaded. Use "is null" or "is not null"
@designator74023 ай бұрын
"fortunately, Unity RECENTLY released a feature called scriptable objects." Scriptable objects were released TWO YEARS prior to this video... How is that _recent_
@danibettlemuse.94893 ай бұрын
This video made me feel so much better about the things I have been confused about at school, thank you so much for putting this together.
@Devorkan3 ай бұрын
don't pass the coroutine name as a string literal: pass it as nameof(YourCoroutineName) so that it's checked by the compiler and the method can be refactored later if needed
@Devorkan3 ай бұрын
1:59, talking about consistency while showing 3 different naming conventions in the same class
I'm not actively using Unity at the moment, but a lot of these are solid pieces of advice for programming in general.
@ringofdeath133 ай бұрын
Okay Wasn't what I was looking for but this was super helpful. I was wondering if you could make a video on just better "coding methods" like showing us how to apply recursion in unity instead of loops. I know recursion because I took a course it for college but I totally forgot the rest of my C++ course so yea.
@sztamjan8663 ай бұрын
The last tip 21:05 I learnt it the hard way 😅 For those who didn't experience it yet, take it very serious, it'll save a lot of time and nerves 😁
@kronusbr173 ай бұрын
what are the font that you are using in the code editor? Seems so nice, clean
@HakoTaco12 ай бұрын
Consolas
@Creezusz3 ай бұрын
Not only useful for unity but just in general
@issussov3 ай бұрын
Tip If your naming conventions are okay and you still need to explain what your code is doing .... you are doing it wrong. (whatever it is)
@gaelp.58473 ай бұрын
Video's great but this is very beginner Coding tips, half topics are covered in Unity dev introduction course and the other half is basic dev/OOP knowledge without going too much into it. Advanced, especially for big projects, would be dependancy injection, code architectures with pros/cons & how to mix and mash and use the best of them in Unity, Unit testing, Memory Usage, Pooling, etc..
@dan_dorjay4 ай бұрын
Lots of good advice here. The main omission from my perspective is unit tests. Increase stability and make changes quickly and safely by covering your code with tests :)
@herbertpimentel4 ай бұрын
Man what amazing engineering job you made explaining your bot system in such richness of details. Thank you, this is a really valuable content ❤
@shingouki23854 ай бұрын
This was awesome! Thank you for this great information.
@ВладимирПочепцов4 ай бұрын
Some of this advice is very bad and inapplicable to big projects! Using Singletons all over the project will make your code unreadable and unrefactorable, because everything will reference everything, and you won't even be able to see all the dependencies in one place, as they will be spread all over a file. Use DI container instead. Same with UnityEvents, it's easy to just assign a method to the event in the Inspector when you are the one person working on a project, but if you are in a team of developers and you will have a conflict in this prefab, you'll likely just miss this event and everything will break. It's always preferable and easier for developers to link the events in code. Deep layers of Inheritance is also not very good, composition is better instead.
@radiofloyd2359Ай бұрын
I don't think he ever suggested deep inheritance, though. I think weapon - gun / melee - specificWeapon is a reasonable inheritance chain. We're not talking about that many layers of inheritance.
@tayyabchadhar38764 ай бұрын
starting Unity and will follow your tips.
@andersmalmgren65284 ай бұрын
Your weapon code probbaly would fit beter as components not sub classes.
@muzboz4 ай бұрын
VERY GOOD VIDEO. Thanks for all the effort putting it together. Great stuff. :D
@jackblack98724 ай бұрын
you made a great video here. 😀
@jackd89334 ай бұрын
4:55 Hold alt in your IDE to select multiple lines of code at a time. Very useful!
@IsKid-tb6wq4 ай бұрын
i really like this vid, he really helped me get into the mindset of developing a big project and even made it seem a little less daunting by splitting things up and haveing your code correlate with itself, thanks
@non-shockingtopics75635 ай бұрын
1 more tip for whoever needs to hear it: Stop watching KZbin videos about how to do stuff and go try to do it yourself! You'll learn best by doing.
@frankyfraaank5 ай бұрын
Damn. Sage programming advice from a young programmer. This guy is going places.
@JakobNorell5 ай бұрын
Really good video! One additional thing that I like to have as a standard when using strings for Invoking or Coroutines is to use the built-in "nameof()" function so the editor can identify the references.
@drewltinder98725 ай бұрын
These are great tips. I recently cleaned up a project significantly just by drawing a box for each script in my project on a piece of paper and drawing an arrow from each box to each box it referenced. I realized i had tons of messy and unnecessary references all over the place and was able to delete almost half of all the code I had written as well as delete an entire class that turned out to be unnecessary.
@Bat3p5 ай бұрын
On the Action class for your event, why did you not use the event keyword?
@3604marine5 ай бұрын
I feel like you can generate a navMesh with colliders. Its somewhere in the navMesh settings
@GuitarGarry6455 ай бұрын
What's great about this video is many of these tips apply to almost all software. I wish some of my coworkers would watch this lmao
@TheHimmus5 ай бұрын
For my project to come to a grinding halt first it needs to come to a grinding start.