So it was written and so it shall be. I hand these down to you to do what you will with them.
- Thou Shalt Learn
- Thou Shalt Learn Some More
- Remember the Code Review to Keep It Holy
- Understand Thy Code Base
- Honor Knowledge, Keep Reading Books
- Thou Shalt Ask for feedback
- Thou Shalt Be Wrong
- Liketh Nike, Just Do It
- Thou Shalt Comment
- Thou Shalt Not Break The Build
1. Thou Shalt Learn
Even as a senior programmer, learning is the most essential skill a programmer can have. It is the Swiss Army Knife of programmer tools. I promise you that software development will move at a faster pace than you can handle, especially the game industry. The only way to keep up is to endlessly search out new information. There WILL be new lighting techniques. There WILL be new types of shaders in the rendering pipeline. There WILL be advancements in AI. There WILL be new software and hardware effects to program into sound systems. There WILL… you see where I’m going with this? Keep up to date whether through the internet or books.
2. Thou Shalt Learn Some More
Really, I can’t stress this enough. I would have made it all ten commandments for all levels of programmers, but that would not nearly have made for as great an article. Speaking of articles, go seek out some interesting new articles!
3. Remember the Code Review to Keep It Holy
I have spoken about code reviews. I have talked about how I review code. However, this might not be reaching the entire audience. Get your code reviewed, even if by other peers with the same or less experience. Try to put as many eyes on your code as possible. Don’t have an ego and don’t be embarrassed. No one likes their code a year later. It is not a vulnerability to get your code picked apart at a review, it is a strength. As uncommon as it is, a game programmer with a deep sense of humility is a strong asset. There are enough bad egos and just as much bad code to go with it in the games industry. Don’t let your code or your career suffer. Get a critique.
4. Understand Thy Code Base
Read through it. All of it. On a larger game this can be a daunting task, but it is well worth it. Code is knowledge. What to do and what not to do is contained within. You’ll get up to speed much more quickly once you’ve seen the dirty internals.
5. Honor Knowledge, Keep Reading Books
You may have read some books in college. That’s a good start. Now it’s time to round out your collection. Have you read Effective C++ by Scott Meyers? What about The Pragmatic Programmer by Dave Thomas and Andy Hunt? Read the latest in the GPU Gems series?
There will always be new books on new topics. You can’t read them all, but you can try. Don’t limit yourself to books about your favorite topic. Grab some books about a broader topic such as architecture. Go for a book in the language of your choice. Maybe try flexing that gray matter with a book about a game system you haven’t yet worked on.
6. Thou Shalt Ask For Feedback
If your manager is not doing 1 on 1s, request them. If your peers are not reviewing your code, ask them. You should open up as many channels of feedback as possible. If you’ve ever seen Johari’s Window, you are trying to locate and improve stuff in the Blind Spot.
7. Thou Shalt Be Wrong
Don’t be afraid to be wrong. If you sit back and let the senior folks drive, you might let valuable input go ignored. However, more importantly, you might actually be wrong. Without raising the question, you go about your day thinking you should have introduced the magic bullet to fix everyone’s problems, but really you just would have had a reasonable explanation of why your idea wouldn’t, shouldn’t, and couldn’t work out. You miss 100% of the shots you don’t take, right?
8. Liketh Nike, Just Do It
I read this one in Game Developer. When you have some great idea, don’t let it get lost in the chain of command. Spend a few hours on Saturday and get it done. If it takes multiple weeks, so be it. Spend the time and get it done. That’s step one. Step two? Let everyone know how great you are!
9. Thou Shalt Comment
Get into the habit! It’s a good habit. Comments make life better. See my previous article on comments here.
10. Thou Shalt Not Break The Build
Breaking the build can be a pretty major offense at some companies. It is not hard to do, either. Check in a typo and you’ll get yelled at quick enough. It’s easy to prevent this, though.
Compile right before you submit. Don’t go spelunking through the code afterwards.
Test. Test. Test.
Not sure? Test again.
Diff your changes before submitting.
Get a code review.
Test again.
Now go out there and code! Obey these, the ten commandments, and you shall be on your way to an awesome career as a game programmer.
14 ResponsesLeave a comment ?
I would recommend these things to all programmers, not just game programmers. Good article anyways.
Comments lie. Comments do not necessarily change with the code. Comments don't get compiled or executed. Code does.
#9 should read "Thou shalt write clear, intention revealing code"
Good points. Writing clear and readable code should be a commandment. (Maybe I can pull an Effective C++ and do the 11 Commandments?)
However, comments should be on the why and not the how. If your comments degrade, you commented poorly or refactored / reimplemented a system properly. If you no longer need a comment saying “// This is done to avoid an exception,” be a pal and take it out. Touching upon or adding your own comments is just as important as removing / verifying old, wrong, confusing ones.
It's Scott Meyers, not Steven Meyer.
Ha ha, whoops. I always mess that up because I worked with a guy named Steven Meyers. Doesn't help that he was pretty sharp and good with dispensing C++ tips.
Yer still missing an "s" there in the article…
I also can't type. Thanks!
[...] This post was mentioned on Twitter by Loiane Groner, theworkinggeek, Bruno Cezar Rocha, Tech & Friki Stuff, Aaron Ogan and others. Aaron Ogan said: 10 Commandments of the Junior Programmer http://is.gd/aWAOU [...]
Nice list, Chad – but I wouldn't limit those suggestions to only junior programmers. Many senior devs I've worked with would do well to follow your advice as well.
Maybe there's a Senior Programmer list forthcoming.
I work with someone that removes my PHP Doc Comments blocks from my code..
Any reason why? Do you put block comments with large ASCII pictures of your face in it?
I love the learning stuff, but my favorite was "Thou Shalt Be Wrong." Too many people are far to afraid of saying the wrong thing. This came up in a disucssion with my father-in-law the other day. He thought I was crazy for saying that I liked being wrong. I would rather get out there what is on my mind and be corrected, learning something in the process; instead of staying silent and continuing to be wrong.
I mean, I obviously want to know enough not to be wrong all the time, but being wrong sometimes is going to happen. Since it is inevitable anyway, you might as well look at it as a learning opportunity.
[...] Comments / Tags: Comments / You may or may not have seen my article on commenting, or my 10 Commandments article in which I listed Commenting as one of the 10 Commandments. Well, there was a little noise in some [...]