Tesseract
Tesseract
  • 9
  • 168 997
20 Advanced Coding Tips For Big Unity Projects
End spaghetti code! Learn the tools you need to write scalable, well-structured, clean code. So many game developers are forced to scrap their ambitious Unity games because they don't know these tips. As a young, self taught game developer, I didn’t discover these tools and techniques for years. Hopefully this video will help you to skip the learning curve and expose you to some of the more advanced programming devices that don’t get enough attention from the plethora of beginner Unity tutorials.
//chapters
00:00 - Intro
01:12 - Variable Names
02:11 - Comments
02:58 - Encapsulate in Functions
03:36 - Plan Your Code
03:57 - C# Properties
04:38 - Serialize Field
05:02 - Component Architecture
06:00 - Enums
06:25 - Coroutines
07:32 - Invoke/Invoke Repeating
08:03 - Structs
08:50 - Singletons
10:38 - C# Events
12:34 - Unity Events
12:56 - Interfaces
14:34 - Inheritance
17:50 - Scriptable Objects
19:15 - Custom Editor Tools
20:25 - Use Version Control
21:00 - Refactor Often
21:38 - Outro
//socials
Instagram: tesseract.yt
TikTok: tesseractyt
//long description
So you finally decided to begin work on your “dream game”, a fantasy MMO RPG sandbox battle royale powered by a blockchain economy. What could possibly go wrong? Then, two months later, progress comes to a grinding halt. You have scripts that are a thousand lines long, you’ve forgotten what your old code does, adding new features means you have to rewrite three old ones, every script relies on every other one, and overall, your project becomes an unorganized, unmanageable, confusing, dumpster fire of spaghetti code. Tragically, you are forced to scrap the project and give up on your game dev dreams. Sound familiar?
There are hundreds of hours of Unity tutorials online, but very few are geared towards more advanced developers aiming to create large scale commercial games. That’s why I’ve compiled a list of some of the most valuable unity coding tips that I’ve learned over the years, along with examples of how I’ve actually used these techniques in my own game. Hopefully, by the end of the video, you’ll have the tools you need to write scalable, well structured, clean code that won’t come back to bite you down the road.
//music
Evan King - Nightmares and Violent Shapes
ua-cam.com/channels/T1Z.html...
contextsensitive.bandcamp.com/
Internet Historian: Sthlm Sunset - Ehrling, A.X - Ehrling, Night Out - LiQWYD
ua-cam.com/video/wS5R3LnXC2o/v-deo.html
Music from Uppbeat (free for Creators!):
uppbeat.io/t/mountaineer/fly-away
License code: VVIYH4NIZH0ARSHF
uppbeat.io/t/hartzmann/joyful-lights
License code: AMYFJECHAZAJGCMI
uppbeat.io/t/swoop/lucidity
License code: Z6V3SJ5TMSRFUKKU
uppbeat.io/t/movediz/summer-vibes
License code: F9CFDRM8JFBQIVOD
//hashtags
#unity #unity3d #unitytutorial #gamedevelopment #coding #programming #indiegame #cleancode #codingtips
Переглядів: 151 856

Відео

Making my Game a Real Game | Indie Game Devlog #4
Переглядів 3,4 тис.Рік тому
I'm making a top down shooter multiplayer mobile game! In this video, I work on the game's main menu and match loop. This includes a loadout screen, weapon select screen, lobby, match timer, match scores, match start and end sequence, and more. I also polish the game up to prepare for public playtesting with TestFlight on IOS. Play-Testing Discord: discord.gg/w5GQ8mHTp4 Flight Test Link (if you...
Designing the Ultimate PVP MAP for my Multiplayer Game | Indie Game Devlog #3
Переглядів 1,8 тис.Рік тому
This is devlog#3 for my multiplayer, top down shooter, indie mobile game Ultimate Battle Arena. In this video, I design and implement my game's first PvP map. My goal is to make Ultimate Battle Arena the first actually good mobile shooter. It will have simple controls, lots of satisfyingly weapons, a variety of characters with abilities, class creation, strategy, and exciting movement. //social...
Can I Make Elden Ring in 10 MINUTES? | Unity 3D
Переглядів 4,9 тис.Рік тому
Join me as I create Elden Ring in 10 minutes using the Unity Game Engine. Yes, the whole thing... Okay fine, only one "boss battle". I may have cut a few corners... It's really just souls-style combat. Keep in mind that this is not a tutorial, it is more of a challenge video with the goal of being educational for beginners and entertaining for all. If you are interested in game development, thi...
Adding SHOTGUNS to my Multiplayer Mobile Game | Indie Game Devlog #2
Переглядів 8912 роки тому
This is the second devlog for my online multiplayer top down shooter mobile game called Ultimate Battle Arena. In this video, I add shotguns, submachine guns, weapon switching, UI, animations, dive rolling, and audio in an effort to purge the game from lameness (lame and shotguns don't really coexist). Watch till the end to see the most satisfying kill montage ever. The game is made with the Un...
Using Python to Unsubscribe From College Emails
Переглядів 6152 роки тому
Fighting college spam with the power of Python and Selenium web scraping. Ever since I took the PSAT almost three years ago, my inbox has been cluttered with thousands of unopened emails from colleges that I have no interest in. I'm going to program a bot to log into my email account, detect college emails, and go through the unsubscribe process for each one. I guess you might learn some things...
Networking, Explosions, AI, Oh my... | Indie Game Devlog #1
Переглядів 1,5 тис.2 роки тому
This is the second devlog for my indie game Ultimate Battle Arena. UBA is an online multiplayer, top down, twin stick shooter game meant for mobile. I'll talk about how networking works in multiplayer games, my struggles implementing networking, the glorious results after getting networking working, and then some stuff not related to networking. I added grenades and explosions with MaTh, and I ...
Can I Make Flappy Bird in 10 MINUTES? | Unity3D
Переглядів 2,9 тис.2 роки тому
Let's make Flappy Bird together... or rather, a scuffed version of it, "Flappy Egg" using the Unity game engine. Oh yeah, and we're going to do it in under 10 minutes. This video is intended for people who are curious about how video games are made. It's a quick, uncut, and hopefully fun example demonstrating the general idea behind making a game and implementing key features such as responding...
I'm making a MOBILE GAME | Indie Game Devlog #0
Переглядів 1,4 тис.2 роки тому
About 3 years ago, I started work on a mobile game called Ultimate Battle Arena using the Unity game engine. In this video, I introduce the game and discuss my journey from an empty game scene to a full fledged project and back to a nearly empty game scene. I’ll share my struggle with nearly every aspect of game development: programming, design, art, graphics, and more. Ultimate Battle Arena is...

КОМЕНТАРІ

  • @stadiagamer9689
    @stadiagamer9689 3 дні тому

    you have no idea how helpful this is

  • @64imma
    @64imma 4 дні тому

    4:36 this is something I'm definitely planning to start implementing in future projects.

  • @Nytrock
    @Nytrock 7 днів тому

    This video makes me feel like a freaking senior developer at my 17

  • @Dylan-my8dt
    @Dylan-my8dt 7 днів тому

    this is just the video that i needed that you so much

  • @BritBox777
    @BritBox777 8 днів тому

    This would be too advanced for a lot of beginners, but this is peak Intermediate advice. Heavily recommend following these tips.

  • @patnor7354
    @patnor7354 9 днів тому

    Great advice

  • @Der_Yoloist
    @Der_Yoloist 15 днів тому

    Man what happened to you.. I found the video and it is soo good. but you have only 5 videos.. years ago.. is everything fine?

  • @WaspFree
    @WaspFree 15 днів тому

    Just one thing I want to add from my experience. As I like C# events more than those from Unity, there is a big advantage for the unity ones. When you're working in a team with designers, it's much more productive if they can change what happens on an event, than asking a programmer to change it. It's not always the case, of course, but it's something worth considering :)

  • @erfant1471
    @erfant1471 17 днів тому

    Very Nice

  • @FrancisThrasher1
    @FrancisThrasher1 19 днів тому

    Love the video

  • @tensofdu1700
    @tensofdu1700 24 дні тому

    12 seconds in and I feel personally attacked

  • @Angry-Lynx
    @Angry-Lynx Місяць тому

    As someone with decade of experience with unity: Dont use unity for big projects. Ull suffer terribly and it will be too late to change engine later. Its closed black box and ull hit wall after wall of unity limitations and very closed software approach it have

  • @BarcelonaMove
    @BarcelonaMove Місяць тому

    Please Keep this series going, This video is pure gold

  • @riery2762
    @riery2762 Місяць тому

    Its funnier that some guy is called "god dev", now is going to godot and did not have this impact full that you did. Thank you ❤

  • @superpepe826
    @superpepe826 Місяць тому

    Okay, you didn't have to call me out that hard at the beginning of the video...

  • @bobbob9821
    @bobbob9821 Місяць тому

    The only one I disagree with is the notion that you should completely isolate your scripts from one another. Setting that rule for yourself makes it hard if you need to coordinate different actions, like pushing the player back when you fire a weapon.

  • @LeviLeuthold
    @LeviLeuthold Місяць тому

    There is definitely a major lack of people talking about advanced coding practices in gamedev, especially when it often becomes the biggest barrier for people trying to make games as their projects inevitably devolve into an unworkable pile of spaghetti. Hope to see more similar content

  • @harry6270
    @harry6270 Місяць тому

    This is something I had to learn the hard way with my first game. It wasn’t huge or anything but I was still very new and oh boy was the backend the biggest piece of garbage 😂

  • @unitywithzaher1374
    @unitywithzaher1374 Місяць тому

    Nice viedo but it's defenetly not ADVANCED!

  • @Johan-rm6ec
    @Johan-rm6ec Місяць тому

    Any progress?

  • @dmansor2
    @dmansor2 Місяць тому

    dislike just because you are using the youtube name "Tesseract". you are not worthy of that name.

  • @FlawLessPixel
    @FlawLessPixel Місяць тому

    Will my experience from roblox studio help me

  • @PablofMorales
    @PablofMorales Місяць тому

    Mostly good :D Couple of things Singleton is anti-patter that affect the SOLID principles mainly SRP and DIP for that reason you should never use singleton Inherence section, you can here check the liskov sustitution, and mostly of the things that you mention your guns class should have, can be added later as a external components like ammo, attachments, recoil, spawn properties, etc I'm learning C# and unity and I saw a lot of horrible code even in AAA games like Rust. I will say that stick to SOLID principle and the first chapters of your video will make a greater architecture that what I can see right now. I imagine this is happening because making a game requires so much knowledge about so many things that sometimes they cannot be great on everything. Keep up with the work!

  • @henribooysen3882
    @henribooysen3882 Місяць тому

    Amazing video... Dahm I have to learn so much QQ I feel like a deer in headlights after looking at this lol

  • @fred1541
    @fred1541 Місяць тому

    That's good~ thanks

  • @ericjeker
    @ericjeker 2 місяці тому

    Perfect video! Thank you so much!

  • @code_craze7705
    @code_craze7705 2 місяці тому

    Can you speak in English bro?

  • @BornToTroll-it5ju
    @BornToTroll-it5ju 2 місяці тому

    Advanced? Hmm 😂

  • @FWpapo
    @FWpapo 2 місяці тому

    wont unity events break when u change scene? lose reference? *question*

  • @erlexfortin3413
    @erlexfortin3413 2 місяці тому

    Really great content, keep it up man 😊

  • @MightBeGiants
    @MightBeGiants 2 місяці тому

    Extremely helpful video that introduced me to a few new concepts I had not encountered before. Great job!

  • @CJEXP
    @CJEXP 2 місяці тому

    Working on my first game and yea its slowly starting to turn into spaghetti code Its very early though and thus fixable still but yea its tough 😅

  • @wieDASland
    @wieDASland 3 місяці тому

    most of these are just basic c# tips that everyone should know considering working on a "big" unity project lol

  • @krasimirdimitrov4955
    @krasimirdimitrov4955 3 місяці тому

    That was the most useless video for "advanced" guidance...

    • @b5fan504
      @b5fan504 42 хвилини тому

      I think it`s a rather good video but agree its something short of advanced. Basic+?

  • @0997udan
    @0997udan 3 місяці тому

    This is sick! I am currently making a video similar to this one :)

  • @user-tm2vn5yj9r
    @user-tm2vn5yj9r 3 місяці тому

    Beware the pitfall of Singletons. Overuse them and you have a giant bowl of spaghetti soon. Mostly only a manager should ever be a singleton. Think like this: - I am a component, I receive orders, I return results and notify my observers. I have one job function and I do not know about anything that is not directly related to doing my job. I do not use Singletons, I do not send messages to other parts of the system. Any subcomponents I require to do my job I am solely in control of, everything goes through me. - I am a controller, my job is to control flow of logic and information and order things to be done. I still only control things within my job function, but this could be a wider set of things that are related. I am a controller, I do not micromanage; I expect my components to do their job, I expect my fellow controllers to do their jobs. I can use singletons(managers), but I do it wisely. Orders travel down the hierarchy (never horizontal), notifications and results travel up. Some will say this is rigid to work with, and it is ... however, it WILL save the project from failing with spaghetti syndrome, it WILL prevent lazy programmers to do shortcuts that come back to bite you in the ass later, and it WILL make it possible for a new programmer on the project to have a chance to take over and change the code base without huge side effects (we can not have a project fall apart or get severely limited because a programmer left the project leaving incomprehensible spaghetti behind). ed. Communications with components should happen through interfaces as much as possible, to prevent lazy programmers from messing with internals of components. Yes it can feel like unnecessary bureaucracy, and in small projects it is, but already at 2 programmers or code reuse between projects it pays off instantly.

  • @uSMELLSOGOOD
    @uSMELLSOGOOD 3 місяці тому

    You are officially the best

  • @thomascarson81
    @thomascarson81 3 місяці тому

    Watching this video has made me realise how terribly spaghettified my most recent Unity project is

  • @spacefood5716
    @spacefood5716 3 місяці тому

    Make more videos please

  • @Seshua87
    @Seshua87 3 місяці тому

    Suggestion for a sniper class perhaps when holding the shoot stick the cam can zoom in and the closer it gets to full zoom the more accurate the shot will be.

  • @Seshua87
    @Seshua87 3 місяці тому

    Here's my unofficial advice when you struggle with something like color palettes or other dev related things, just research what a successful game does and press ctrl c, ctrl v. Then just change it a bit.

  • @brianwilson7497
    @brianwilson7497 3 місяці тому

    this was an excellent video, thanks for the ideas!

  • @googleuser4720
    @googleuser4720 3 місяці тому

    Lol and listen to a Gen Z dude? No thanks

  • @spalekralj
    @spalekralj 3 місяці тому

    Bruh, you a genius. As someone who is just starting with Unity and this game dev shi (I am a huge newbie when it comes to this whole shi) - I enjoyed this very much! Thanks.

  • @juanpidanda
    @juanpidanda 4 місяці тому

    This tips are awesome and is for all levels in my opinion either if you are a beginner, intermediate or advance developer

  • @Sp1tfire100
    @Sp1tfire100 4 місяці тому

    Which theme do you use?

  • @Eqqs
    @Eqqs 4 місяці тому

    This is brilliant @TesseractDev .Thanks for sharing!

  • @miran_sky
    @miran_sky 4 місяці тому

    Where's the other hoodie string 😭 but seriously, this is such a great video! I learned so much, thank you!!!

  • @jumpjumpdiegaming
    @jumpjumpdiegaming 4 місяці тому

    Great video, I’m sure you’ve noticed this now as it’s a year since you posted this, but usually methods have a capital letter at the start!

  • @Fyres11
    @Fyres11 4 місяці тому

    Another tip for the #6 could be [field: serializedfield] public {get; private set} to be able to change the property in the inpector but still private set. For the #7 I totally agree, decoupling is a great thing to learn and the observer pattern help a lot for that.