The video is a detailed code review of a C++ Snake game project that the reviewer, The Cherno, praises as one of the most professionally presented projects he has ever seen. He is highly impressed by the developer's use of industry-standard practices, including comprehensive documentation in the README.md, CMake for the build system with automatic dependency fetching, unit tests using Catch2, and a meticulous project management approach using Jira-style issue tracking with 181 commits for a simple game.
However, after praising the project's external structure, the review shifts to a critique of the underlying code architecture. The reviewer identifies significant flaws, primarily within the main game loop. He points out unnecessary nested while loops for each game state, repeated rendering code, and a confusing and brittle state management system that blurs the lines between the UI, game logic, and core application flow. The video concludes by opening a discussion, inviting viewers to his Discord channel to propose solutions for refactoring the architecture, with a promise of a follow-up video to discuss the suggestions.
The Most Professional C++ Project I've Ever Reviewed
0:46 - Exceptional Project Presentation: The reviewer is immediately impressed by the project's professionalism, highlighting the detailed README.md file which includes Doxygen documentation, unit tests, a Kanban/Jira project management methodology, and a CMake build system.
2:26 - A Showcase of Industry Practices: With 181 commits and Jira-style ticket numbers, the project is presented as a perfect, if somewhat bureaucratic, example of professional software development. The reviewer uses this to discuss the value of project management skills versus pure coding ability in a job candidate.
6:56 - Initial Flaws on First Run: Despite its polish, the project has a common flaw: it fails to run out-of-the-box due to an incorrect working directory setting in Visual Studio, preventing assets from loading. The reviewer also notes the window is not resizable and lacks an application icon.
8:23 - Excellent Build System: The use of CMake is highly praised, especially its ability to automatically download and configure dependencies like Raylib and Catch2. This is noted as a clean and robust way to handle external libraries.
10:11 - Good Modular Structure: The project is logically split into a core library, a render library, and a main executable. While overkill for a snake game, the reviewer notes this is an excellent demonstration of understanding scalable software architecture, which is valuable for a portfolio piece.
14:42 - Architectural Flaw #1: Unnecessary Nested Loops: The main architectural critique begins with the game loop. Each game state (menu, game, etc.) is handled in a function that contains its own redundant while loop. The reviewer demonstrates that these can be removed entirely, simplifying the code to rely on a single, primary game loop.
17:35 - Architectural Flaw #2: Repeated Code and Logic: The reviewer points out that rendering calls (begin drawing, end drawing) and other logic are repeated inside each state-handling function. This code should be moved to the main loop to avoid repetition and make the state-handling functions more focused.
18:33 - Architectural Flaw #3: Confusing State Management: The logic for managing game state is convoluted. For instance, creating a new game (by deleting and reallocating the game object) happens inside a loop triggered by a UI event, making a "one-shot" action feel complex and hard to follow.
20:25 - Blurring Module Responsibilities: The review highlights that core application logic, like the state machine that controls the entire game flow, is located within the render module (GameUI class). This breaks the separation of concerns that the modular project structure was meant to enforce.
22:07 - A Call to Action for Refactoring: Instead of solving the issues, the video ends by inviting viewers to a new Discord channel to discuss how to improve the flawed architecture. He promises a follow-up video to cover the community's ideas and his own solutions.
Summary of YouTube Comments
The comment section is overwhelmingly positive, with viewers engaging in several key discussions:
Praise for the Project's Professionalism: Many commenters, including some in hiring positions like a Director of Software Engineering, agree that the level of documentation, issue tracking, and project management is a massive "bonus point" for a job applicant. They see it as proof of diligence, communication skills, and an understanding of the software development lifecycle, which can be more valuable than perfect code.
Agreement with the Code Critique: While praising the presentation, many also agree with the reviewer's assessment of the code's architectural flaws. They echo his points about the messy main loop and confusing state management, with some suggesting the architecture needs a complete rework.
The "Blizzard Dad" Joke: The reviewer's off-hand comment at 11:49 ("Maybe they're just trying to make their dad who worked at Blizzard proud") was a huge hit and is referenced and joked about in dozens of comments.
Hiring Philosophy Debate: A debate emerged on the importance of project management skills versus pure technical skills for new hires. One director claimed they ignore PM skills and expect new hires to adapt, while others argued that finding developers who already understand these processes is a significant advantage.
Technical Explanations and Suggestions: Viewers offered technical insights, with one explaining that splitting the project into modules is essential for unit testing (as the test runner needs its own main function). Others debated the merits of fetching dependencies with CMake versus vendoring them directly in the repository.
Suspicion of AI: A recurring theory among some commenters is that the extremely detailed documentation and project structure might have been generated or assisted by AI (like ChatGPT), given its "boilerplate" feel and the style of the README.