I'm a software engineer as that's what I did at uni for my degree however, I hated coding until I started up game dev during my free time, it's because of the instant reward you get from actually seeing your code do something.
My goal is to never look up something basic more than twice. If I'm looking at something for the 2nd time, I make sure to really take a second to make sure I understand it. I don't remember everything forever like this, but it helps me not just rely on looking things up immediately and forces myself to think about things logically to recreate what I can remember.
thats not how brains work lil bro. You can totally understand something , but if you dont use it ALL the time, you're going to forget it eventually. It'll just be a bit easier to learn again next time .
I agree with that. It seems too many people don't understand that developing a game is also an engineering process and it is important to understand the very fundamentals of this creative solution-finding process.
Fundamentally, all programming boils down to transforming one set of data into another set of data. A video game takes controller input data and game resource data and transforms it into pixels and sounds. A programmer carefully constructs a pipeline of transformations.
Only pipeline get jammed and shet hits the fan, Just like Arid Sohan be like Why is it the best thing I've ever read. Because he be like it so simply explained but its so much more then that.
Divide problems in too smaller problems. Now this makes perfectly sense, the problem is when you have a problem divided in small parts and the small parts are still confusing.
Then you probably need to divide those smaller parts into even smaller parts, or you lack knowledge about the particular problem and should research it more thoroughly
thats when it gets more difficult, the next best thing is solving a simpler problem that is similar to the one you cant solve rn, trying to translate understanding from the simpler problem to the more complex one.
This is excellent advice that took me forever to realize on my own. As a novice, I focused too much on the specific contextual action I wanted my character to perform, like "Jump on an enemy", for example. Once I realized I needed to simplify my thinking to "If A collides with B" things became much easier. Many different actions are basically the same as far as the code is concerned.
That's exactly it! There's no fundamental difference between a lot of concepts at the code level. You should just be modifying different implementations of things
"If you want a coin that disappears when you touch it, one simple way to achieve that, is to just, make a coin that disappears when you touch it. Next question" "wait wh-"
this is how i usually code my game. i don't have good memory about syntax. so I usually breakdown the features that I want to implement then google the basic of the code like how to detect collision, how to move using vector3, how to perform action using specific button, etc
I think that's a great way to do it. Not bothering with exact syntax when that's the type of stuff you should be googling rather than googling tutorials on the EXACT feature you need :)
I'm making games in unity for like 3 months now, few hours a day and basically it's amazing that I've discovered it few weeks ago. Just one day something clicked in my brain about developing new features and basically you can do anything as long as you can break it down into smaller logical steps and operations. Great video for people that cannot comprehand how particular features in games actually work underneath. Also, more functionality you know in the game engine, the easier and more 'handy' you can do it but most of the time, limitation is in our mind, not knowledge.
Programming is like lego. You can look up a lego plan (coding tutorial) for a specific model (game feature), and the plan (tutorial) will teach you to build the model (game feature) exactly, but are you really learing how to build with lego (program)? It's only once you learn what you can do with the bricks, and how to break down the problem you're facing, you then truly become a master builder (programmer).
The way I learned this is by simply making things from scratch without Wikipedia or Google. I've made working 3d renderers and physics engines in a very small amount of time just by trying things out and inventing my own theories about how it should work. Coding is a much better learning process when you do everything yourself, and sadly I don't see that being taught anywhere anymore. We always search the web for answers, but the most personally valuable answer is going to be one drafted yourself, even if it requires improvement or redesign later.
about 15 years ago i didnt have internet or a phone with a browser. i had an old version of Gamemaker and I just read the helpfile/doc and figured a lot out on my own. it was truly eye-opening how much i learned. I was pissed at first, about not having internet. Then I realized I had the ability to figure it out on my own.
Because when you try your own solutions without any help, and after hours of coding you still didn't have something working, it can be really demotivating. Like, when you will start working again on your code all it will remind you is that you're stuck and you are unable to solve problems. And you will maybe want to go on another project. I think that making up things on your own can be really good and satisfying, but using ideas from google to figure out the solution is also a good thing
@@DarkBane3 I'm not necessarily saying don't use any documentation at all, just that avoiding using code examples as shortcuts and trying to refrain from depending on others' frameworks can be a really enlightening experience.
@@HyperCodecI agree with this. Rather than "My code doesn't work, I'll just copy from this tutorial instead" (or even worse, not even trying yourself first), it should be "What are the differences between mine and theirs, if I change this does it fix it? If so, why?".
Beginner Web Dev here. And this is supposed to be for the first minutes of the video in which he is talking about trying to learn code. What I do to learn certain things is pretty simple. 1 .Make a little plan: In my Case for example a simple registration with SQL. And Look up what you need. 2. Think in Pseudo-Code how it could look like. (This can be hard for hard beginners I think) 3. Search on what to do but try not to copy it right away. Read it carefully and try to understand it. 4. Try to code it from your memorie as far as you can. you dont have to get far. 5. Look it up again. In short. Its a basic try and error. If its not working read again, try to understand what is happening. Then try to code it and when its not working. Try the same again. I dont know if this applies to certain areas in Game-Dev (cuz im still learning the basics) but this helps me a lot to memorize certain code structures. for example a simple SQL query. Sorry for typos and fuckups. Its 6 am and I am typing this on a laptop with an nearly broken keyboard while laying down.
I mostly agree with the video - I think some of the complication does come from people brand new to programming starting with a game engine or framework. Since when a beginner starts with a game engine their day 1 programming class is Object Oriented Programming - Which is above where they should be tbh and they also get bogged down in some engine specific stuff. I'd say that's why you have people who think _"being good at game development means understanding your engine very well"_ For people looking to start programming the pathway I would recommend is making sure you first understand: 1. Variables and Simple Data Structures (Ints, Bools, chars, floats, doubles) -- Store some variables and write them to the screen with Print (or whatever your language has for writing) 2. Strings and Arrays -- Know how to make an array/string and access elements 3. Basic operators (+ , - , *, / ) and String/Array access and manipulation (How to see what the 5th character of an array or string is, how to append or subtract things from them) 4. If statements and logical operators (and, or, not) 5. Functions & writing comments. Start breaking your code into manageable chunks and write comments to keep things clear. 6. Basic user input (Console in for now) 7. Loops (For, while, do while, ) 8. More complicated data structures - Linked Lists and other non-statics arrays, Dictionaries/Hashtables, 9. Reading and Writing from files (First as normal text files like txt, then as Binary files) 10. Basic Object Oriented Programming (What is a class, what is an object, can you write a class, can you make an object) 11. Making your own classes with your own methods and operators (e.g. implement a 3d position class with an x,y,z with operators that let you add them together) 12. More advance OOP (Inheritance, polymorphism) Then once you understand those things - You'll be able to mess around in whatever language - the concepts are the same you just write them a bit different. And when you look at a game engine or framework, you'll kinda get that components like a "Sprite" are just a classes someone else has written for you. Apologies if all of this is just me rambling and not useful to anyone 😅
Decomposition of the problem. I can’t count the number of times I’ve kicked myself for being stumped on a development problem that later becomes obvious when I break it down (making me wish I had done that sooner). You explained the concept really well in this video!
As a software engineer, I think this is a great introduction to the concepts of development. It can go a lot deeper, but you have to start somewhere, and this is a good place. It begin with an excellent point that isn't obvious to non-developers: the important skills you learn as a developer are not specific to one kind of task or domain, but generally how to model desired behavior with computers in general. Learning how to break down problems and strategically execute on those tasks is what it's all about. A skilled engineer can go from working on games to websites to databases with only having to spend a small amount of time to understand the specifics of the domain they are working in. It can take some practice to get the most out of a set of tools and APIs, but the hard part is always general problem solving.
I can't fathom how well explained this is. This is literally lesson one I got when I started programming and most classmates were struggling after that because they missed the whole point. Organizing your toughts from ideas to processes to steps is the whole reason pseudocode exists, stopping right before coding. If done properly, you could design the whole program and have someone else code it for you following your steps because of how neatly organized everything can be, and videogame development is simply one of the many scenarios. It's just like creating a cooking recipe: describe it properly and anyone can follow along, and even if you yourself get lost at some point you can just read again and understand it as long as it's written properly.
It is so refreshing to hear a youtuber who knows how developers work! I watched recommended videos from generic searchs and many were what you mention, how to implement a specific feature in a specific game in their specific coding style. Which I found unhelpful as a software engineer. To novices it is an appealing trap, copying and pasting instead of understanding the basics and how they work together which takes much more initial effort. These videos you mention give a man a fish. You teach a man how to fish.
Very important video. A lot of newbies when they code seem to have difficulties generalizing. That leads them to ask over-specific questions like "how to implement coins?" when really the sort of questions programmers should be asking is "how does this class work?", "what's the syntax for language feature x?", "what's the best way to handle this data type?", etc. All the concrete problems can be broken down into your language's abstractions :)
Excellent video, great to see a more generalised "tutorial" for problem solving. It'd also be cool to get your advice on how to debug or find issues in code if something isn't working as intended.
This was probably when i realized I could do so much more was when i first started drawing out and trying to implement things my self. I knew how to code but I just would get overwhelmed or start coding without breaking it down and feeling like I need help to do anything. its been years since then and sometimes i still forget to this but its helped me so much in realizing that you could build a complicated system if you figure out how to break it down.
I am a young game dev who has been overwhelmed by the questions in my head saying "I cant do this" or "I am not smart enough to understand this" but this video, even if it is 4 years old, has given me hope to keep learning because learning is what people like us strive for.
I really think programming is often kind of an art form! (Well, as long as you have the freedom to program what you want, things are different on the job)
Not so much visual form, but encoding his very thoughts into a form that the computer and other humans can understand. Programming is closer to writing as an art form, but its inherent nonlinearity and recursive complexity (which is the point of the video) makes it its own form.
HUGE subject, and great explanation. I've come to use this subconsciously, but I still sketch out a to-do list in mspaint every time a more complex feature arises. I'd like to share some advice that might help overcome this hurdle for beginners, coming from my experience. I'm not a pro or anything, but I've been coding for 8 years and regularly write documentation and help with problems faced by newcomers. What makes this process difficult if you're starting out is that it requires you to think like a computer, not like a human. So formulating these fundamental steps can be difficult if you don't quite know yet how code structure works, or what variables are for or what they even are. This is where practice and, to some extent, engine familiarity come in again, and where you can't really eliminate them. How I usually try to teach it is by giving assignments for self-study, or writing tutorials that are open-ended and have a set of potential jumping off points at the end. So there may be a character jump tutorial, but quests like "make a double jump using a (link) integer that (link) resets when touching the ground", or "add a jump like the (video) Super Mario Bros. 2 high jump, which needs to be charged with a (link) float timer before use" can be found at the end for those who made it through the bulk of the problem. For some people that's still too esoteric, and if you have been in a position where you struggle to understand thinking like a computer to translate your will into code it can understand, I usually recommend the following: Try translating the syntax into your language directly and forming sentences using the syntax of the code and your variables. "If", "for", "while" and the likes can be easily understood out of the box. They are english words, and their statements match what they mean in English. So "if (availableJumps >= 0) {" likens the english phrase "if more than 0 jumps are available, then" -> substituting { for "then", >= for "more than" or "over", etc. Making any phrase on paper becomes a mix-and-match game that helps you ease into the syntax of your language and logic of how computers understand your code. You end up with a short series of sentences that almost directly translate to lines of code. If statements in particular are very powerful tools that compose the vast majority of condition-based statements in programming, especially in beginner level. (Note: "for" translation is a bit more weird, because usually for (x=A; x
One more point that I think is worth mentioning when it comes to this is CONFIDENCE. I struggle with it myself. Everytime Im tryna develop a new feature, I tell myself there's prolly a better, more efficient way of doing this, and I start looking for tutorials and end up deviating or giving up on it completely.
Hey your comment is a good while old but i relate to this HARD. Sometimes you really do have enough knowledge to do smth, but your own Insecurity and Fears tend to let you overthink it and feeling like you HAVE to watch a Tutorial. What i do now is that i document certain codes for features i did in my Documentation App, so that if i ever forget it, i can refeer to that, instead of watching tutorial xyz again. Most of the time by trying and failing, you tend to improve your existing Code in your Documentation after a while
Whenever I think that my code is bad or that I'm not good enough, I remember that time someone decompiled Undertale to look at how it ticked. The game barely works. It's an extremely amateur project and it's held together by bits of string.
When I started programming I could follow the tutorials and modify the code to add a feature here and there, but when I'd try starting from a blank project I would be so lost. Practice is definitely the best teacher here. Take what you learn from the tutorials and start small and just keep adding features. As your skills improve, you'll only need tutorials for concepts that are new to you. For instance, I needed collisions detection as well as collision resolution tutorials as well as watch some refresher math videos before I could add simple physics to a 2D game. Not good advice, but I'm going to say it anyway...Chat GPT helps a lot. You can ask it to provide an explanation on how to implement a feature, and if you're still stuck ask for a code example. You'll still need to know the language pretty well to determine if the code provided will work or not or why it behaves the way it does.
Easily the best piece of advice a professor gave my class was, if a problem doesn’t make any sense, keep breaking it down into smaller problems until you find something that makes sense, then start there
What I generally like doing is like you said, dividing the system into small concepts, then for the concepts I don’t know, I’ll either check the documentation or a tutorial, then build it from there, so I am also learning how to do that one concept so I could use it later. So if I were to learn how to make a disappearing coin, I’ll figure out how to do the disappearing part, after I learned that for the coin, I could use it for other things like a projectile hitting an enemy in a game where there is no health system
I totally agree with this video. I started to develop a trading card game. It requires no computer, no "coding" and no resources, but you still need to understand how everything interacts, how feedback loops are formed, how to represent each card's properties, how to structure the game, how to add new features (cards, types, effects, game modes) without breaking anything... it has been an amazing experience overall. I played my game with some friends and I have optimized it for quite a while. With all the tree structures and flow diagrams I have sketched for the game until now, I could easily code it, but I have yet to gain experience with real life coding, and I don't want to deal with graphics and all of that for now... Anyways, people should think of games as GAMES with clear rules, processes and elements, and not as lines of code that have to do something...
basically don't do deep into level coding and end up forgetting about level design, I have understood this from a completely different discipline. I'm studying architecture (and I'm working on a game as a passion project), and in architecture school we work a lot in orthographic and delve so much into it that we forget it's just a house and the resident is never gonna see it as we do. Funny how I'm implementing that in coding as well, maybe all kinds of design follow the same principle.
Well, there _is_ a computer, a sort of choppy GPU with a very interesting set of instructions- and there _is some code, written in a language you probably know fairly well. It's natural language, and the GPU is all the players, combined, cooperating to execute the instructions in your, well... instructions! I think it's an interesting way to look at tabletop, paper-and-pencil, dice-rolling, or other sorts of board games.
This is taught, it's in your data structures and algorithms class. [rolls eyes]. You break your problem down into sub-problems, etc, etc. But great you realised this on your own. Well done.
My counterargument to this video is that if you want to implement an idea, you HAVE to type in THE code that does the job. Sometimes there are multiple options, but your code still has to work. How will you learn to write code that works? Tutorials. In fact, as fluffy here is trying to explain some ideas, he points you to.... his tutorials! Conceptually or philosophically, fluffy makes some great points here. But tutorials will still be the bread and butter of developing your skills as a game dev. Then, once you've actually built a few games with your chosen media (engine, library, or language) you would have the capacity to innovate as outlined.
Love the vid, great explanation. Until I started working on my own projects I felt like I wasn’t learning much no matter how many tutorials I watched/ read
I was quite sceptical when I read the title of this video, but pleasantly surprised after watching. Sometimes the simple stuff is hard to explain, especially when you've been doing it for so long. You explained this far better than I could. Great video!
Used to think there was something wrong with me because I couldn't memorize all the Javascript and javascript library syntax, but really it was a my understanding that needed improvement. The memory of syntax just comes with the repetition.
In my experience programming and game dev becomes so much easier when you are able to identify what you need to do, look at and really understand other examples of what you want to do in code, and use that for inspiration for how you want to solve the problem. I'm not encouraging straight copying and pasting, but there's something very satisfying about being able to read someone else's code and decide that you can adopt it or even improve it to make it do exactly what you want to do.
Sad to see you didn't bring up the point of; "there is more than one way to skin a cat" for foreigners who don't know the saying, it means more than one approach to the same problem. For game dev people, it's important to remember more than one way to tackle a problem when it comes to game dev.
Been a minute since I've seen this video, but it's one I think about often. Deffinately is one of my goals, I'm just not there yet. But I'm getting closer, and am able to now put my own spin on the tutorials I follow. Hopefully next time I see this I will be.
I get the feeling that double jump would better kept track of with a boolean, updated when grounded, so you can actually say if you have available or not the mechanic to perform a mid air jump (which is what a double jump is). The counter would make sense if you are thinking on adding a several mid-air jumps capacity, in which case it wouldnt be doublejump anymore (triplejump, quadjump, etc). Now that i've been nerdy enough let me say good video and excelent reminder of what programming is about
Nice, I'm glad that this topic is being focused on a little more because its needed. People need to see that any problem can be overcome if they think about it for a while.
Awesome video. I completely agree with the sentiments in here. I've been trying to share similar things. Most of the questions we get as "developers in the spotlight" are questions that can be answered if you spend a few minutes breaking down the problem. i think I'll share my ideas on this as well for application development. It's definitely a required skill to become a great developer.
Really great advice. Even with lots of experience in other languages I have found myself constantly looking for specific answers and guide for features as opposed to just trying to break down my problems. I think a key point with all this is that there isn’t always a “right” or best answer. Your way of solving the problem will also generally be something that makes more sense to you. You don’t want to come back to code in your game later that came from a tutorial and realize you never really understood the methods being used.
I have not seen anyone articulate this better than this video. Showing this to friends. It's just second nature to those of us who 'get it'. But so many people I try to get into game programming just can't figure out this '3rd person view' of thinking. And when I tell them that they take it wrong and think I'm talking about making 3rd person views in a game. *sigh*
Smash your keyboard, follow a tutorial, make your blood composed purely of caffeine, sit in front of your pc for 5 hours wondering why a script doesn’t work. This is the way of coding
@@visitor1588 Either this guy is the worst programmer ever or he's *cough* *cough* using exaggeration as a form of something us humans call "comedy". I'm sorry your pride makes it hard for an intellectual like you to understand humor.
@@visitor1588 Tbh, ive had a situations where ive sat for way more than 5 hours at a time trying to figuere out why something doesnt work. Also r/whooosh because you cant understand a joke
I teach CS at high school and the general way of thinking of big problems as large interconnected sets of smaller problems you talk about here is one of the most fundamental skills I try to impart. It improves problem solving not just in CS and gamedev but in so many other fields as well! What I would add is that in order to be able to actually think of solutions for those many small problems, a solid grasp of the basic workings of any subject is necessary. Your and my mind immediately think of arrays or lists when we hear multiple similar X, but if that is not the case with a student, it doesn't matter how small they try to make a problem. There comes a point where further subdivision would lead to the student trying to invent lists themselves to solve the problem. To practise both, I often use examples of already complete programs to go through and try to reconstruct why something was done the way it was done. Using some common examples, you can quickly show people almost all fundamental concepts of coding and also give them an idea of how to think about problems at the same time.
Also along the same vain just sitting back and thinking about a problem for a while really helps. Not actively working on it but like just going about your day and meditating on it.
This is an excellent video explaining for beginners trying to understand what you must do while developing a feature. Most just try looking up a tutorial on what exactly has to be done. Rather than trying to understand the "why" behind the tutorial. I highly recommend anyone starting out watch this video! Great job @DaFluffyPotato!
Doing Web Dev and did professional work as a DevOps developer. This is the best advice out there, to start breaking down the problem until YOU feel like you can do it.
Quite the interesting video, I was surprised to see how few people "chunk" their problems when programming, they tend to just take "working blocks" and glue them together instead of actually understanding what the blocks do to solve novel problems.
For the Coin one for people that don't understand First you break down Actions What is Get Coin?: You Touch Something and Scores Go Up... What is Touch?: My Character Vector Position is the Same as the Coin (XYZ of Chracter = To XYZ of Coin). - You can use a Collider Check if you have a Library... What is Scores Go up?: Adds a Number to a another Number. (1 + 1 = 2) (This is where most People get it Wrong). What Numbers are We Adding?: The Number of from a List of Numbers... Soo on so forth until it goes into a Infinite Loop of the Same Answer or you reach to a Dead end...
and with this video I learned the basic syntax of an array... I never saw the two together, only talked about. I'm still prettymuch in the Godot bandwagon for game design, but I've found watching some of these tutorials great for learning the general idea of things, and now this kinda makes me want to dive into your other tutorials even if I never touch pygame.
The point where I go on youtube is when I'm stuck on a feature architecture issue. I like to look at different implementation, find the best one for my solution and alter it so it fits my structure.
Honnestly I find thinking of the architecture first a bit complicated, because once it's coded, you will probably have cases where you'll need to rearange it. If that's your first try implementing a feature, try first to implement it roughly, (in no separate class, just on one sample, etc) and when it's done, just move and split the code in a class.
@@sho1175 Your approach works well for simple projects or projects with only a few developers. However, for medium sized projects or projects with a few developers (think 3+) this approach usually begins to fail. In general, excellent software engineers avoid costly/time-consuming mistakes by being excellent project architects above all else. With good code structure all stages of development become easier. For projects with several team members, using a quick-and-dirty structure will definitely save time at the start, but will begin to become a huge source of struggle later. This is because weak structure of code doesn't enforce standard practice across a team (this is an issue even in projects with friends). Let's say you made a kinda-gross-but-it-works coin class to handle the example in this video. Then someone else on the team needs to add, for instance, gems which can be picked up. They would look at how you had done it, think "that's the way to add collectible items in this game", and would be tempted to implement it how you had done it. Then, perhaps, you decide that gold nuggets can be picked up... so you also add those in a similar way too. Suddenly, each new object than can be collected is separate. You'll find yourself wishing you had just created singleton classes for ResourceManager, ResourceRenderer, and ResourceCollector from the very beginning.
@@erylkenner8045 Well, that's why your team isn't just programmers and actually has designers on it. The project management side with designers is there to build the logic flow in the form of charts, diagrams and other well-documented forms of psuedocode. This kind of task shouldn't really be left solely to the programmers. The programmers should focus on the programming, the designers construct the flow based on the required needs. And really, even if the team is all programmers, one of more of the members will probably take up the task of designer before actually coding anything. And if anything needs to be redesigned, it shouldn't be done directly, but should be reassessed outside of the IDE. Solo projects like home game development gets tough for many people because they do all of the tasks themselves, such as designing and programming, art, etc. It gets difficult to structure the development process or know when to step back and go back to designing if something doesn't work.
Thank you for the circle idea, I get everything you're talking about, not a noob anymore.... but the circle concept was just something I never considered before.. its silly actually, such a simple usage of the draw circle method available in different graphics engines. I'll definitely make use of it going forward.
1:46 personally i find that after making games for so long, you start to understand the way a think should be done so it will be efficient and the least amount of code.. in other words, many of your current systems you will come back to in a few years and go 'holy cow, that Frankenstein actually works?' then rewrite the entire page into 3 lines of code...
Very helpful thinking! i just started learning how to read and write code, the tutorials certainly do help at the start but at some point they feel like a easy way out compared to learning to solve the problem yourself. Great video :)
the hard part of programming is not building a new feature but rather refactoring old features or trying to write a new one that has to be inserted into an older one which wasn't well implemented since the beginning. In short, every project that you start from scratch has a difficulty of 0 by default. It doesn't matter if the goal is to create a simple 2D videogame or the next billionaire SaaS with lots of complexity.
I see you're talking about pygame. I don't know much about that engine, but in the case of unity, the rendering part is actually done for you with the MeshRenderer component, and you can detect collision with coins by giving them a collider and setting it to trigger (so the player can still move through them) and calling the OnTriggerEnter method to keep track of any colliders/triggers, either on the player or on the coin (preferrably player). Have them either be destroyed, or just turn off their collider and renderer when touched, and add 1+ to the coin counter.
very important video. only few sources on youtube about planning and code management. there is plenty of content about implementation of rudimentary to complex features, but I have the feeling that most viewers struggle with tieing in new functionality or combining things in different ways than how it has been teached. sure there is a aspect of experience through experimenting, but teaching different ways to approach the architecture helps keeping the learning curve more linear. great video!
i think watching tutorials only work at the surface level (or a general topic) but when your working in a project, often times you will be developing such niche features/tools that there aren't really any exact tutorials for it. Thats when you can apply your existing knowledge to come up with something original.
as the video says, practice practice practice. I only feel confident putting a game together in unity after... I've lost count now, at least 6 pretty serious projects, of which only 1 was finished. And that's on top of a lot of experience with Flash (AS3, basically Javascript) in the old days. You really just have to get out there and code. ChatGPT is an absolutely invaluable newer tool, but probably not in the way you're using it. You should be asking it for concepts, not code. You should be able to get a paragraph of how A* pathfinding works or something, and be able to write your own code for it. Read the official documentation for whatever language you're using. Study coding patterns (very important), never stop learning
As someone who learned JavaScript's Async/Await logic and then mimicked the combat of Undertale(minus player's turn), I see this video as a win.🙃 Thank you for sharing your wisdom, Btw.
Old video but I just wanted to say this helped me so muchp Code is a little intimidating for me and I tend to get lost in problems and lose my mind lol. I was able to follow along with this video clearly and write some of my own examples. Thanks so much!
0:50 this is literally what is taught in an introduction to programming course at University (Like CS106A at Stanford). At least if the course is taught well, focusing on how to solve problems, and not just going through the syntax/features of a specific programming language.
I feel like I haven't been doing this as much as I should. I'm definitely the guy that looks up a lot of tutorials when I get stuck on something mostly because I always wind up a little confused as to how to implement certain things. For instance, I use unity, so if i'm making a simple character movement system using the transform positions instead of the built in rigidbody or character controller I have to store it in a Vector3 variable and then after I write my code for the movement itself I have to store the transform position in that variable. It sounds simple enough now but starting out I wouldn't have even guessed that you'd need to do that order to get things working and I end up having a lot of similar issues with other things too. I try to just use the documentation but the examples and descriptions provided don't always immediately connect for me.
Everything I code always follows a similar train of thought you describe in this video. I'm not a game dev, I make tools for managing realestate and build projects etc. So the workflow might be different in the sense that I work in a scrum team but the coding itself is always kinda the same. Sometimes things are complicated but it still always boils down to "what information do I need to make X happen" when you have that, then there might be the time to check some online resources if needed. For example, yesterday I did some bug fixing in like a 'legacy' part of the service. I've never really dabbled in jquery and cshtml so I quickly identified where the bug is and what I need to fix it but of course I had to figure out how to get the data I needed from the controller, to the view and use it in the script. Now I know and the next time I need to leave my comfy React environtment, I'm at least a bit better equipped even though I wouldn't add jquery into my resume just yet 😅
Honestly, I have to admit, the first thing I thought was “this kid sounds 14.” After watching the video for a bit though I realized you make a really great point! It seems obvious, but it is so easy to let this mindset slip away from you while working on games.
nothing beats pencil and paper. Half of my best sketching happened on 9x12 blank printer paper. there's a fine process of converting brain pseudo-idea into ideas and converting those ideas into pseudocode, but it works so well on paper.
Been making games for years and yeah he's absolutely right. Especially for big games with many features. When you don't organize your code, you will loose control of it at some point.
I don’t find coding basic features difficult. However, stuff like organising the code, having cutscenes and cutscene manager, organising what data needs to be saved (for example, in RPGs you need to save xp, stats, money, items and quest states) and loading correct dialogue or correct maps based on how far into the game you get. The reason this is difficult for me is because as you code more and more, it gets more and more confusing.
Yeah, I’ve heard from plenty of people to write down the steps in say English or whatever language you speak before coding it. That way you know what steps your algorithm will take to do what you want it to do. It also gives you time to think it through and figure out how you want to handle certain tasks.
I would also add for double jump the specific case where you fall off of a cliff. Most people expect (because of other video games in the past) that you would only get one jump instead of two. So in that particular case, you simply add an additional check for the case where a player has not pressed jump, but is also not on the ground. In that case, you set jump to 1 so that they can still only jump once if they already fell from a platform or cliff before ever jumping.
what I would prefer doing is keeping track of only air jumps- jumps off of the ground are free. So, to give the player a double jump, you give them 1 air-jump, and this also takes care of falling-off-cliffs jumps being limited to just the one air-jump, rather than getting to leech the second jump that could be in the air or on the ground.
Honestly I think the problems come less from tutorials themselves, and more how people might not be able to adapt the code from a tutorial to what they want to achieve since they're just copying what's on screen without knowing what each bit of code does. Sometimes tutorials are a great way to help a game dev approach the methods of coding a feature with an idea they weren't aware of before. So yes, I do think breaking a feature down into each piece of code helps, but that doesn't mean tutorials shouldn't be used to help with it. What I like to do is write down a rough outline describing what I want the bool to be like. For example, "Trigger a function that displays a number with it's number parameter in the invoke being one of the scripts set integers". Hell, some tutorials will explain in good detail the purpose of each piece of code, and you can apply that knowledge for coding features without a tutorial. At the end of the day, tutorials are fine if you know what you're doing.
Bro, if you are very tired and want to sleep, then you don't need to record a video, my respect for how you didn't fall asleep completely during the recording
I have similar problems in software dev. People ask me how to do their things. I could sit with you and tell you but then you won't learn anything. Even worse, oftentimes coming up with a solution is like 90% of the work done. If I have to sit with you, think things through with you, and come up with a detailed plan then I might as well do this task myself. Don't get me wrong, sometimes it's valuable to brainstorm a solution or even teach someone so that they are helpful later. But some people just stay as a liability even though their programming skills upgrade to mid or senior-level. It's in the mindset and sometimes I'm lost as to how to change that mindset.
I like the insightful manner you are trying to explain things. I can see where this is still experimental and I think if you used popular game mechanics then you could do a few more videos. Much like how you are doing now but instead of waiting for people to ask you how to conceptualize a mechanic, instead maybe make a list of game mechanics that you like/are prevalent enough to explain how to break these things down conceptually. I for one tear apart games that I play(and make) and try to break them in almost the same manner as you've described. I like how you are doing this.
I'm a software engineer as that's what I did at uni for my degree however, I hated coding until I started up game dev during my free time, it's because of the instant reward you get from actually seeing your code do something.
same
Same here but as a frontend developer
Hey me too
@@nirjan13 and backend developer too , you change base url and boom , its not work
Its when u learn any graphical interface
My goal is to never look up something basic more than twice. If I'm looking at something for the 2nd time, I make sure to really take a second to make sure I understand it. I don't remember everything forever like this, but it helps me not just rely on looking things up immediately and forces myself to think about things logically to recreate what I can remember.
thats not how brains work lil bro. You can totally understand something , but if you dont use it ALL the time, you're going to forget it eventually. It'll just be a bit easier to learn again next time .
I agree with that. It seems too many people don't understand that developing a game is also an engineering process and it is important to understand the very fundamentals of this creative solution-finding process.
Fundamentally, all programming boils down to transforming one set of data into another set of data. A video game takes controller input data and game resource data and transforms it into pixels and sounds. A programmer carefully constructs a pipeline of transformations.
Sculpt the pathway
I would add that a well crafted pipeline is modular and allows you to replace and modify parts with relative ease
Oh yessss, the floor is made from floor, nice logic :D
Quite neatly put. ❤️❤️
Only pipeline get jammed and shet hits the fan, Just like Arid Sohan be like Why is it the best thing I've ever read.
Because he be like it so simply explained but its so much more then that.
“Nothing is particularly hard if you divide it into small jobs." -Henry Ford
Chinese: "even easier when you have endless slaves to do them for you"
@@blackcitadel37 LMFAO
@@blackcitadel37 theyre not wrong just very immoral 💀
@@blackcitadel37 Shrek: „Onions have layers, ogres have layers. Ogres have layers like onions do. People hate onions.”
"I litteraly never said that."
- Henry Ford
Divide problems in too smaller problems.
Now this makes perfectly sense, the problem is when you have a problem divided in small parts and the small parts are still confusing.
Then you probably need to divide those smaller parts into even smaller parts, or you lack knowledge about the particular problem and should research it more thoroughly
Sorry that was confusing, can you explain it in smaller chunks
Hahaha 😂
Then divide it into smaller parts. Also learning the fundamentals of programming like data structures helps a lot.
thats when it gets more difficult, the next best thing is solving a simpler problem that is similar to the one you cant solve rn, trying to translate understanding from the simpler problem to the more complex one.
This is excellent advice that took me forever to realize on my own. As a novice, I focused too much on the specific contextual action I wanted my character to perform, like "Jump on an enemy", for example. Once I realized I needed to simplify my thinking to "If A collides with B" things became much easier.
Many different actions are basically the same as far as the code is concerned.
That's exactly it! There's no fundamental difference between a lot of concepts at the code level. You should just be modifying different implementations of things
"If you want a coin that disappears when you touch it, one simple way to achieve that, is to just, make a coin that disappears when you touch it. Next question"
"wait wh-"
"But first, ask yourself what a coin means. It can be so many things; one of them being a metal circle. Speaking of metal, I can...."
Jordan Peterson enters the chat
You see the missile knows where its by knowing where it isn't
i mean he isnt wrong there
@@AkshayKumar-iy4gg literally that
this is how i usually code my game.
i don't have good memory about syntax. so I usually breakdown the features that I want to implement then google the basic of the code like how to detect collision, how to move using vector3, how to perform action using specific button, etc
I think that's a great way to do it. Not bothering with exact syntax when that's the type of stuff you should be googling rather than googling tutorials on the EXACT feature you need :)
@@olbluelips i used that exact technique while learning blender
I'm making games in unity for like 3 months now, few hours a day and basically it's amazing that I've discovered it few weeks ago. Just one day something clicked in my brain about developing new features and basically you can do anything as long as you can break it down into smaller logical steps and operations. Great video for people that cannot comprehand how particular features in games actually work underneath. Also, more functionality you know in the game engine, the easier and more 'handy' you can do it but most of the time, limitation is in our mind, not knowledge.
Programming is like lego.
You can look up a lego plan (coding tutorial) for a specific model (game feature), and the plan (tutorial) will teach you to build the model (game feature) exactly, but are you really learing how to build with lego (program)?
It's only once you learn what you can do with the bricks, and how to break down the problem you're facing, you then truly become a master builder (programmer).
The way I learned this is by simply making things from scratch without Wikipedia or Google. I've made working 3d renderers and physics engines in a very small amount of time just by trying things out and inventing my own theories about how it should work.
Coding is a much better learning process when you do everything yourself, and sadly I don't see that being taught anywhere anymore. We always search the web for answers, but the most personally valuable answer is going to be one drafted yourself, even if it requires improvement or redesign later.
about 15 years ago i didnt have internet or a phone with a browser. i had an old version of Gamemaker and I just read the helpfile/doc and figured a lot out on my own. it was truly eye-opening how much i learned.
I was pissed at first, about not having internet. Then I realized I had the ability to figure it out on my own.
Because when you try your own solutions without any help, and after hours of coding you still didn't have something working, it can be really demotivating. Like, when you will start working again on your code all it will remind you is that you're stuck and you are unable to solve problems. And you will maybe want to go on another project. I think that making up things on your own can be really good and satisfying, but using ideas from google to figure out the solution is also a good thing
@@DarkBane3 I'm not necessarily saying don't use any documentation at all, just that avoiding using code examples as shortcuts and trying to refrain from depending on others' frameworks can be a really enlightening experience.
@@HyperCodecI agree with this. Rather than "My code doesn't work, I'll just copy from this tutorial instead" (or even worse, not even trying yourself first), it should be "What are the differences between mine and theirs, if I change this does it fix it? If so, why?".
when you are low on time there is no "learn your self" i would say if the wheel is invented don't reinvent it but worse unless you have time
Beginner Web Dev here. And this is supposed to be for the first minutes of the video in which he is talking about trying to learn code.
What I do to learn certain things is pretty simple.
1 .Make a little plan: In my Case for example a simple registration with SQL. And Look up what you need.
2. Think in Pseudo-Code how it could look like. (This can be hard for hard beginners I think)
3. Search on what to do but try not to copy it right away. Read it carefully and try to understand it.
4. Try to code it from your memorie as far as you can. you dont have to get far.
5. Look it up again.
In short. Its a basic try and error. If its not working read again, try to understand what is happening.
Then try to code it and when its not working. Try the same again.
I dont know if this applies to certain areas in Game-Dev (cuz im still learning the basics)
but this helps me a lot to memorize certain code structures. for example a simple SQL query.
Sorry for typos and fuckups. Its 6 am and I am typing this on a laptop with an nearly broken keyboard while laying down.
I mostly agree with the video -
I think some of the complication does come from people brand new to programming starting with a game engine or framework.
Since when a beginner starts with a game engine their day 1 programming class is Object Oriented Programming - Which is above where they should be tbh and they also get bogged down in some engine specific stuff.
I'd say that's why you have people who think _"being good at game development means understanding your engine very well"_
For people looking to start programming the pathway I would recommend is making sure you first understand:
1. Variables and Simple Data Structures (Ints, Bools, chars, floats, doubles) -- Store some variables and write them to the screen with Print (or whatever your language has for writing)
2. Strings and Arrays -- Know how to make an array/string and access elements
3. Basic operators (+ , - , *, / ) and String/Array access and manipulation (How to see what the 5th character of an array or string is, how to append or subtract things from them)
4. If statements and logical operators (and, or, not)
5. Functions & writing comments. Start breaking your code into manageable chunks and write comments to keep things clear.
6. Basic user input (Console in for now)
7. Loops (For, while, do while, )
8. More complicated data structures - Linked Lists and other non-statics arrays, Dictionaries/Hashtables,
9. Reading and Writing from files (First as normal text files like txt, then as Binary files)
10. Basic Object Oriented Programming (What is a class, what is an object, can you write a class, can you make an object)
11. Making your own classes with your own methods and operators (e.g. implement a 3d position class with an x,y,z with operators that let you add them together)
12. More advance OOP (Inheritance, polymorphism)
Then once you understand those things - You'll be able to mess around in whatever language - the concepts are the same you just write them a bit different.
And when you look at a game engine or framework, you'll kinda get that components like a "Sprite" are just a classes someone else has written for you.
Apologies if all of this is just me rambling and not useful to anyone 😅
Decomposition of the problem. I can’t count the number of times I’ve kicked myself for being stumped on a development problem that later becomes obvious when I break it down (making me wish I had done that sooner).
You explained the concept really well in this video!
As a software engineer, I think this is a great introduction to the concepts of development. It can go a lot deeper, but you have to start somewhere, and this is a good place. It begin with an excellent point that isn't obvious to non-developers: the important skills you learn as a developer are not specific to one kind of task or domain, but generally how to model desired behavior with computers in general.
Learning how to break down problems and strategically execute on those tasks is what it's all about. A skilled engineer can go from working on games to websites to databases with only having to spend a small amount of time to understand the specifics of the domain they are working in. It can take some practice to get the most out of a set of tools and APIs, but the hard part is always general problem solving.
If you wanted to train up your personal squad of prodigies what type of concepts or paths would you get them on after this?
I can't fathom how well explained this is. This is literally lesson one I got when I started programming and most classmates were struggling after that because they missed the whole point. Organizing your toughts from ideas to processes to steps is the whole reason pseudocode exists, stopping right before coding. If done properly, you could design the whole program and have someone else code it for you following your steps because of how neatly organized everything can be, and videogame development is simply one of the many scenarios. It's just like creating a cooking recipe: describe it properly and anyone can follow along, and even if you yourself get lost at some point you can just read again and understand it as long as it's written properly.
It is so refreshing to hear a youtuber who knows how developers work!
I watched recommended videos from generic searchs and many were what you mention, how to implement a specific feature in a specific game in their specific coding style. Which I found unhelpful as a software engineer. To novices it is an appealing trap, copying and pasting instead of understanding the basics and how they work together which takes much more initial effort.
These videos you mention give a man a fish. You teach a man how to fish.
Excellent advice! I've been doing programming for decades at this point and I couldn't have said it better myself.
Very important video. A lot of newbies when they code seem to have difficulties generalizing. That leads them to ask over-specific questions like "how to implement coins?" when really the sort of questions programmers should be asking is "how does this class work?", "what's the syntax for language feature x?", "what's the best way to handle this data type?", etc.
All the concrete problems can be broken down into your language's abstractions :)
Excellent video, great to see a more generalised "tutorial" for problem solving. It'd also be cool to get your advice on how to debug or find issues in code if something isn't working as intended.
That’s a pretty good idea. I might do that.
Recently i started doing more code by my self when learning how to make games. This video helped me even more with that
Hey! Just curious, are you still doing Gamedev?
This was probably when i realized I could do so much more was when i first started drawing out and trying to implement things my self.
I knew how to code but I just would get overwhelmed or start coding without breaking it down and feeling like I need help to do anything.
its been years since then and sometimes i still forget to this but its helped me so much in realizing that you could build a complicated system if you figure out how to break it down.
1:00 that's actually my way of thinking for solving even irl issues.
its actually a pretty common problem solving method, especially in the tech industry, its called divide and conquer
I am a young game dev who has been overwhelmed by the questions in my head saying "I cant do this" or "I am not smart enough to understand this" but this video, even if it is 4 years old, has given me hope to keep learning because learning is what people like us strive for.
You're no longer just a programmer at this point, are truly an artist! You're now simply expressing your ideas into visual form
I really think programming is often kind of an art form! (Well, as long as you have the freedom to program what you want, things are different on the job)
Not so much visual form, but encoding his very thoughts into a form that the computer and other humans can understand. Programming is closer to writing as an art form, but its inherent nonlinearity and recursive complexity (which is the point of the video) makes it its own form.
programming is the highest level art
HUGE subject, and great explanation. I've come to use this subconsciously, but I still sketch out a to-do list in mspaint every time a more complex feature arises. I'd like to share some advice that might help overcome this hurdle for beginners, coming from my experience. I'm not a pro or anything, but I've been coding for 8 years and regularly write documentation and help with problems faced by newcomers.
What makes this process difficult if you're starting out is that it requires you to think like a computer, not like a human. So formulating these fundamental steps can be difficult if you don't quite know yet how code structure works, or what variables are for or what they even are. This is where practice and, to some extent, engine familiarity come in again, and where you can't really eliminate them.
How I usually try to teach it is by giving assignments for self-study, or writing tutorials that are open-ended and have a set of potential jumping off points at the end. So there may be a character jump tutorial, but quests like "make a double jump using a (link) integer that (link) resets when touching the ground", or "add a jump like the (video) Super Mario Bros. 2 high jump, which needs to be charged with a (link) float timer before use" can be found at the end for those who made it through the bulk of the problem.
For some people that's still too esoteric, and if you have been in a position where you struggle to understand thinking like a computer to translate your will into code it can understand, I usually recommend the following: Try translating the syntax into your language directly and forming sentences using the syntax of the code and your variables. "If", "for", "while" and the likes can be easily understood out of the box. They are english words, and their statements match what they mean in English. So "if (availableJumps >= 0) {" likens the english phrase "if more than 0 jumps are available, then" -> substituting { for "then", >= for "more than" or "over", etc. Making any phrase on paper becomes a mix-and-match game that helps you ease into the syntax of your language and logic of how computers understand your code. You end up with a short series of sentences that almost directly translate to lines of code. If statements in particular are very powerful tools that compose the vast majority of condition-based statements in programming, especially in beginner level.
(Note: "for" translation is a bit more weird, because usually for (x=A; x
Nah pen and paper is the goat
One more point that I think is worth mentioning when it comes to this is CONFIDENCE. I struggle with it myself. Everytime Im tryna develop a new feature, I tell myself there's prolly a better, more efficient way of doing this, and I start looking for tutorials and end up deviating or giving up on it completely.
Hey your comment is a good while old but i relate to this HARD. Sometimes you really do have enough knowledge to do smth, but your own Insecurity and Fears tend to let you overthink it and feeling like you HAVE to watch a Tutorial. What i do now is that i document certain codes for features i did in my Documentation App, so that if i ever forget it, i can refeer to that, instead of watching tutorial xyz again. Most of the time by trying and failing, you tend to improve your existing Code in your Documentation after a while
Whenever I think that my code is bad or that I'm not good enough, I remember that time someone decompiled Undertale to look at how it ticked. The game barely works. It's an extremely amateur project and it's held together by bits of string.
When I started programming I could follow the tutorials and modify the code to add a feature here and there, but when I'd try starting from a blank project I would be so lost. Practice is definitely the best teacher here. Take what you learn from the tutorials and start small and just keep adding features. As your skills improve, you'll only need tutorials for concepts that are new to you. For instance, I needed collisions detection as well as collision resolution tutorials as well as watch some refresher math videos before I could add simple physics to a 2D game.
Not good advice, but I'm going to say it anyway...Chat GPT helps a lot. You can ask it to provide an explanation on how to implement a feature, and if you're still stuck ask for a code example. You'll still need to know the language pretty well to determine if the code provided will work or not or why it behaves the way it does.
Easily the best piece of advice a professor gave my class was, if a problem doesn’t make any sense, keep breaking it down into smaller problems until you find something that makes sense, then start there
this dude is my savior i would have wasted so much time watching tutorials if not for this video thank you bud
What I generally like doing is like you said, dividing the system into small concepts, then for the concepts I don’t know, I’ll either check the documentation or a tutorial, then build it from there, so I am also learning how to do that one concept so I could use it later. So if I were to learn how to make a disappearing coin, I’ll figure out how to do the disappearing part, after I learned that for the coin, I could use it for other things like a projectile hitting an enemy in a game where there is no health system
I totally agree with this video.
I started to develop a trading card game. It requires no computer, no "coding" and no resources, but you still need to understand how everything interacts, how feedback loops are formed, how to represent each card's properties, how to structure the game, how to add new features (cards, types, effects, game modes) without breaking anything... it has been an amazing experience overall. I played my game with some friends and I have optimized it for quite a while.
With all the tree structures and flow diagrams I have sketched for the game until now, I could easily code it, but I have yet to gain experience with real life coding, and I don't want to deal with graphics and all of that for now...
Anyways, people should think of games as GAMES with clear rules, processes and elements, and not as lines of code that have to do something...
basically don't do deep into level coding and end up forgetting about level design, I have understood this from a completely different discipline. I'm studying architecture (and I'm working on a game as a passion project), and in architecture school we work a lot in orthographic and delve so much into it that we forget it's just a house and the resident is never gonna see it as we do. Funny how I'm implementing that in coding as well, maybe all kinds of design follow the same principle.
Well, there _is_ a computer, a sort of choppy GPU with a very interesting set of instructions- and there _is some code, written in a language you probably know fairly well. It's natural language, and the GPU is all the players, combined, cooperating to execute the instructions in your, well... instructions!
I think it's an interesting way to look at tabletop, paper-and-pencil, dice-rolling, or other sorts of board games.
This is taught, it's in your data structures and algorithms class. [rolls eyes]. You break your problem down into sub-problems, etc, etc. But great you realised this on your own. Well done.
My counterargument to this video is that if you want to implement an idea, you HAVE to type in THE code that does the job. Sometimes there are multiple options, but your code still has to work.
How will you learn to write code that works? Tutorials. In fact, as fluffy here is trying to explain some ideas, he points you to.... his tutorials!
Conceptually or philosophically, fluffy makes some great points here. But tutorials will still be the bread and butter of developing your skills as a game dev. Then, once you've actually built a few games with your chosen media (engine, library, or language) you would have the capacity to innovate as outlined.
Love the vid, great explanation. Until I started working on my own projects I felt like I wasn’t learning much no matter how many tutorials I watched/ read
I was quite sceptical when I read the title of this video, but pleasantly surprised after watching.
Sometimes the simple stuff is hard to explain, especially when you've been doing it for so long. You explained this far better than I could. Great video!
This video is soo good and explains the process in building things. It's not really emphasized much anywhere except DS and ALGOs
Used to think there was something wrong with me because I couldn't memorize all the Javascript and javascript library syntax, but really it was a my understanding that needed improvement. The memory of syntax just comes with the repetition.
In my experience programming and game dev becomes so much easier when you are able to identify what you need to do, look at and really understand other examples of what you want to do in code, and use that for inspiration for how you want to solve the problem. I'm not encouraging straight copying and pasting, but there's something very satisfying about being able to read someone else's code and decide that you can adopt it or even improve it to make it do exactly what you want to do.
Sad to see you didn't bring up the point of; "there is more than one way to skin a cat" for foreigners who don't know the saying, it means more than one approach to the same problem. For game dev people, it's important to remember more than one way to tackle a problem when it comes to game dev.
Been a minute since I've seen this video, but it's one I think about often.
Deffinately is one of my goals, I'm just not there yet. But I'm getting closer, and am able to now put my own spin on the tutorials I follow.
Hopefully next time I see this I will be.
I get the feeling that double jump would better kept track of with a boolean, updated when grounded, so you can actually say if you have available or not the mechanic to perform a mid air jump (which is what a double jump is). The counter would make sense if you are thinking on adding a several mid-air jumps capacity, in which case it wouldnt be doublejump anymore (triplejump, quadjump, etc).
Now that i've been nerdy enough let me say good video and excelent reminder of what programming is about
Nice, I'm glad that this topic is being focused on a little more because its needed. People need to see that any problem can be overcome if they think about it for a while.
Also knowing the common software design patterns helped me a lot as it gave me basic templates to build upon
Awesome video. I completely agree with the sentiments in here. I've been trying to share similar things. Most of the questions we get as "developers in the spotlight" are questions that can be answered if you spend a few minutes breaking down the problem. i think I'll share my ideas on this as well for application development. It's definitely a required skill to become a great developer.
Really great advice. Even with lots of experience in other languages I have found myself constantly looking for specific answers and guide for features as opposed to just trying to break down my problems. I think a key point with all this is that there isn’t always a “right” or best answer. Your way of solving the problem will also generally be something that makes more sense to you. You don’t want to come back to code in your game later that came from a tutorial and realize you never really understood the methods being used.
I have not seen anyone articulate this better than this video. Showing this to friends.
It's just second nature to those of us who 'get it'. But so many people I try to get into game programming just can't figure out this '3rd person view' of thinking.
And when I tell them that they take it wrong and think I'm talking about making 3rd person views in a game. *sigh*
Smash your keyboard, follow a tutorial, make your blood composed purely of caffeine, sit in front of your pc for 5 hours wondering why a script doesn’t work. This is the way of coding
@@visitor1588 Either this guy is the worst programmer ever or he's *cough* *cough* using exaggeration as a form of something us humans call "comedy". I'm sorry your pride makes it hard for an intellectual like you to understand humor.
@@visitor1588 You neglect to understand that 4 of those hours is procrastinating on UA-cam watching stupid videos to vend frustration.
@@visitor1588 Tbh, ive had a situations where ive sat for way more than 5 hours at a time trying to figuere out why something doesnt work. Also r/whooosh because you cant understand a joke
@@visitor1588 You are so smart that you can't even understand irony, you must be very annoying lol
I teach CS at high school and the general way of thinking of big problems as large interconnected sets of smaller problems you talk about here is one of the most fundamental skills I try to impart. It improves problem solving not just in CS and gamedev but in so many other fields as well!
What I would add is that in order to be able to actually think of solutions for those many small problems, a solid grasp of the basic workings of any subject is necessary. Your and my mind immediately think of arrays or lists when we hear multiple similar X, but if that is not the case with a student, it doesn't matter how small they try to make a problem. There comes a point where further subdivision would lead to the student trying to invent lists themselves to solve the problem. To practise both, I often use examples of already complete programs to go through and try to reconstruct why something was done the way it was done. Using some common examples, you can quickly show people almost all fundamental concepts of coding and also give them an idea of how to think about problems at the same time.
Also along the same vain just sitting back and thinking about a problem for a while really helps. Not actively working on it but like just going about your day and meditating on it.
This is an excellent video explaining for beginners trying to understand what you must do while developing a feature. Most just try looking up a tutorial on what exactly has to be done. Rather than trying to understand the "why" behind the tutorial. I highly recommend anyone starting out watch this video! Great job @DaFluffyPotato!
def Program(problem):
if problem.complexity < max_complexity:
exec(Solve(problem))
return 1
for element in split(problem):
Program(element)
return 0
Doing Web Dev and did professional work as a DevOps developer. This is the best advice out there, to start breaking down the problem until YOU feel like you can do it.
Quite the interesting video, I was surprised to see how few people "chunk" their problems when programming, they tend to just take "working blocks" and glue them together instead of actually understanding what the blocks do to solve novel problems.
For the Coin one for people that don't understand
First you break down Actions
What is Get Coin?: You Touch Something and Scores Go Up...
What is Touch?: My Character Vector Position is the Same as the Coin (XYZ of Chracter = To XYZ of Coin). - You can use a Collider Check if you have a Library...
What is Scores Go up?: Adds a Number to a another Number. (1 + 1 = 2) (This is where most People get it Wrong).
What Numbers are We Adding?: The Number of from a List of Numbers...
Soo on so forth until it goes into a Infinite Loop of the Same Answer or you reach to a Dead end...
The tldw is basically "learn to create and use logical abstractions". It's a fundamental requirement for any kind of programming, not just game dev.
It‘s a fundamental requirement for anything really
and with this video I learned the basic syntax of an array... I never saw the two together, only talked about.
I'm still prettymuch in the Godot bandwagon for game design, but I've found watching some of these tutorials great for learning the general idea of things, and now this kinda makes me want to dive into your other tutorials even if I never touch pygame.
The point where I go on youtube is when I'm stuck on a feature architecture issue. I like to look at different implementation, find the best one for my solution and alter it so it fits my structure.
Honnestly I find thinking of the architecture first a bit complicated, because once it's coded, you will probably have cases where you'll need to rearange it. If that's your first try implementing a feature, try first to implement it roughly, (in no separate class, just on one sample, etc) and when it's done, just move and split the code in a class.
@@sho1175 Your approach works well for simple projects or projects with only a few developers. However, for medium sized projects or projects with a few developers (think 3+) this approach usually begins to fail. In general, excellent software engineers avoid costly/time-consuming mistakes by being excellent project architects above all else. With good code structure all stages of development become easier.
For projects with several team members, using a quick-and-dirty structure will definitely save time at the start, but will begin to become a huge source of struggle later. This is because weak structure of code doesn't enforce standard practice across a team (this is an issue even in projects with friends). Let's say you made a kinda-gross-but-it-works coin class to handle the example in this video. Then someone else on the team needs to add, for instance, gems which can be picked up. They would look at how you had done it, think "that's the way to add collectible items in this game", and would be tempted to implement it how you had done it. Then, perhaps, you decide that gold nuggets can be picked up... so you also add those in a similar way too. Suddenly, each new object than can be collected is separate. You'll find yourself wishing you had just created singleton classes for ResourceManager, ResourceRenderer, and ResourceCollector from the very beginning.
@@erylkenner8045 Well, that's why your team isn't just programmers and actually has designers on it. The project management side with designers is there to build the logic flow in the form of charts, diagrams and other well-documented forms of psuedocode. This kind of task shouldn't really be left solely to the programmers. The programmers should focus on the programming, the designers construct the flow based on the required needs. And really, even if the team is all programmers, one of more of the members will probably take up the task of designer before actually coding anything. And if anything needs to be redesigned, it shouldn't be done directly, but should be reassessed outside of the IDE. Solo projects like home game development gets tough for many people because they do all of the tasks themselves, such as designing and programming, art, etc. It gets difficult to structure the development process or know when to step back and go back to designing if something doesn't work.
Thank you for the circle idea, I get everything you're talking about, not a noob anymore.... but the circle concept was just something I never considered before.. its silly actually, such a simple usage of the draw circle method available in different graphics engines.
I'll definitely make use of it going forward.
I like programming when it feels like puzzle
1:46 personally i find that after making games for so long, you start to understand the way a think should be done so it will be efficient and the least amount of code.. in other words, many of your current systems you will come back to in a few years and go 'holy cow, that Frankenstein actually works?' then rewrite the entire page into 3 lines of code...
Very helpful thinking! i just started learning how to read and write code, the tutorials certainly do help at the start but at some point they feel like a easy way out compared to learning to solve the problem yourself. Great video :)
the hard part of programming is not building a new feature but rather refactoring old features or trying to write a new one that has to be inserted into an older one which wasn't well implemented since the beginning. In short, every project that you start from scratch has a difficulty of 0 by default. It doesn't matter if the goal is to create a simple 2D videogame or the next billionaire SaaS with lots of complexity.
I see you're talking about pygame. I don't know much about that engine, but in the case of unity, the rendering part is actually done for you with the MeshRenderer component, and you can detect collision with coins by giving them a collider and setting it to trigger (so the player can still move through them) and calling the OnTriggerEnter method to keep track of any colliders/triggers, either on the player or on the coin (preferrably player). Have them either be destroyed, or just turn off their collider and renderer when touched, and add 1+ to the coin counter.
I got a 9+ (maybe B+ or something like that) from my programming class with this! Thanks dude :)
It's interesting how we have all the features in programming languages to create anything we want.
very important video. only few sources on youtube about planning and code management. there is plenty of content about implementation of rudimentary to complex features, but I have the feeling that most viewers struggle with tieing in new functionality or combining things in different ways than how it has been teached. sure there is a aspect of experience through experimenting, but teaching different ways to approach the architecture helps keeping the learning curve more linear. great video!
i think watching tutorials only work at the surface level (or a general topic) but when your working in a project, often times you will be developing such niche features/tools that there aren't really any exact tutorials for it. Thats when you can apply your existing knowledge to come up with something original.
as the video says, practice practice practice. I only feel confident putting a game together in unity after... I've lost count now, at least 6 pretty serious projects, of which only 1 was finished. And that's on top of a lot of experience with Flash (AS3, basically Javascript) in the old days. You really just have to get out there and code. ChatGPT is an absolutely invaluable newer tool, but probably not in the way you're using it. You should be asking it for concepts, not code. You should be able to get a paragraph of how A* pathfinding works or something, and be able to write your own code for it. Read the official documentation for whatever language you're using. Study coding patterns (very important), never stop learning
Great video. I’ll be exploring more game math now. I find that it makes things much easier to understand.
As someone who learned JavaScript's Async/Await logic and then mimicked the combat of Undertale(minus player's turn), I see this video as a win.🙃
Thank you for sharing your wisdom, Btw.
Old video but I just wanted to say this helped me so muchp Code is a little intimidating for me and I tend to get lost in problems and lose my mind lol. I was able to follow along with this video clearly and write some of my own examples. Thanks so much!
0:50 this is literally what is taught in an introduction to programming course at University (Like CS106A at Stanford). At least if the course is taught well, focusing on how to solve problems, and not just going through the syntax/features of a specific programming language.
The art is amazing, water movement and environment very impressive, Thumb-Up!
I feel like I haven't been doing this as much as I should. I'm definitely the guy that looks up a lot of tutorials when I get stuck on something mostly because I always wind up a little confused as to how to implement certain things. For instance, I use unity, so if i'm making a simple character movement system using the transform positions instead of the built in rigidbody or character controller I have to store it in a Vector3 variable and then after I write my code for the movement itself I have to store the transform position in that variable. It sounds simple enough now but starting out I wouldn't have even guessed that you'd need to do that order to get things working and I end up having a lot of similar issues with other things too. I try to just use the documentation but the examples and descriptions provided don't always immediately connect for me.
Acutally, what people has to learn first isn't how to make a game with Python, it's how to solve a problem. This applies to all programming...
All this time, the answer that's been shoved in my face is always 'find a tut, find a tut', and then I find this video. Omg, thank you. T_T
Everything I code always follows a similar train of thought you describe in this video. I'm not a game dev, I make tools for managing realestate and build projects etc. So the workflow might be different in the sense that I work in a scrum team but the coding itself is always kinda the same. Sometimes things are complicated but it still always boils down to "what information do I need to make X happen" when you have that, then there might be the time to check some online resources if needed. For example, yesterday I did some bug fixing in like a 'legacy' part of the service. I've never really dabbled in jquery and cshtml so I quickly identified where the bug is and what I need to fix it but of course I had to figure out how to get the data I needed from the controller, to the view and use it in the script. Now I know and the next time I need to leave my comfy React environtment, I'm at least a bit better equipped even though I wouldn't add jquery into my resume just yet 😅
Honestly, I have to admit, the first thing I thought was “this kid sounds 14.” After watching the video for a bit though I realized you make a really great point! It seems obvious, but it is so easy to let this mindset slip away from you while working on games.
nothing beats pencil and paper. Half of my best sketching happened on 9x12 blank printer paper. there's a fine process of converting brain pseudo-idea into ideas and converting those ideas into pseudocode, but it works so well on paper.
Idk why such obvious solutions never come to me until someone points them out.
Been making games for years and yeah he's absolutely right. Especially for big games with many features. When you don't organize your code, you will loose control of it at some point.
I don’t find coding basic features difficult. However, stuff like organising the code, having cutscenes and cutscene manager, organising what data needs to be saved (for example, in RPGs you need to save xp, stats, money, items and quest states) and loading correct dialogue or correct maps based on how far into the game you get. The reason this is difficult for me is because as you code more and more, it gets more and more confusing.
personally i've just thought of stuff like this that way by default
That’s how it was for me too, but it’s rather uncommon.
@@DaFluffyPotato This video definitely need to be expand upon! Do you mind if I share it on linkedIn?
@@stephanrhodes4227 damn mate he would be happy if you share it, he will get more viewers
thank you for your relentless effort to educate and entertain!
Yeah, I’ve heard from plenty of people to write down the steps in say English or whatever language you speak before coding it. That way you know what steps your algorithm will take to do what you want it to do. It also gives you time to think it through and figure out how you want to handle certain tasks.
I’m a Professional coder working in FAANG. This methodology is exactly right! I’ve never seen it put so clearly though!
Oddly enough, their voice is relaxing.
Almost like unintentional ASMR
But that's just me and I'm weird
I like to break tasks into the smallest possible chunks. it helps with learning
I would also add for double jump the specific case where you fall off of a cliff. Most people expect (because of other video games in the past) that you would only get one jump instead of two. So in that particular case, you simply add an additional check for the case where a player has not pressed jump, but is also not on the ground. In that case, you set jump to 1 so that they can still only jump once if they already fell from a platform or cliff before ever jumping.
what I would prefer doing is keeping track of only air jumps- jumps off of the ground are free. So, to give the player a double jump, you give them 1 air-jump, and this also takes care of falling-off-cliffs jumps being limited to just the one air-jump, rather than getting to leech the second jump that could be in the air or on the ground.
Im not kidding when I say this advice immidietly helped me troubleshoot way better, tysm for the advice!
In 0:28 you showed a list of steps, a tutorial on how to learn game development. Is there another video for this? Please link, thank you!
Honestly I think the problems come less from tutorials themselves, and more how people might not be able to adapt the code from a tutorial to what they want to achieve since they're just copying what's on screen without knowing what each bit of code does. Sometimes tutorials are a great way to help a game dev approach the methods of coding a feature with an idea they weren't aware of before. So yes, I do think breaking a feature down into each piece of code helps, but that doesn't mean tutorials shouldn't be used to help with it. What I like to do is write down a rough outline describing what I want the bool to be like. For example, "Trigger a function that displays a number with it's number parameter in the invoke being one of the scripts set integers". Hell, some tutorials will explain in good detail the purpose of each piece of code, and you can apply that knowledge for coding features without a tutorial. At the end of the day, tutorials are fine if you know what you're doing.
I’ve been developing games with c# for 3+ years and this was still very helpful.
Bro, if you are very tired and want to sleep, then you don't need to record a video, my respect for how you didn't fall asleep completely during the recording
I have similar problems in software dev. People ask me how to do their things. I could sit with you and tell you but then you won't learn anything. Even worse, oftentimes coming up with a solution is like 90% of the work done. If I have to sit with you, think things through with you, and come up with a detailed plan then I might as well do this task myself.
Don't get me wrong, sometimes it's valuable to brainstorm a solution or even teach someone so that they are helpful later. But some people just stay as a liability even though their programming skills upgrade to mid or senior-level. It's in the mindset and sometimes I'm lost as to how to change that mindset.
Thank you for the video. Its nice to watch this because recently I started working in a horror game (and its my first game )
the wall jump is so satisfying 4:58
I like the insightful manner you are trying to explain things. I can see where this is still experimental and I think if you used popular game mechanics then you could do a few more videos. Much like how you are doing now but instead of waiting for people to ask you how to conceptualize a mechanic, instead maybe make a list of game mechanics that you like/are prevalent enough to explain how to break these things down conceptually. I for one tear apart games that I play(and make) and try to break them in almost the same manner as you've described. I like how you are doing this.