Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Lately I have been writing a game engine, and I have been writing a lot of \"fou

ID: 654658 • Letter: L

Question

Lately I have been writing a game engine, and I have been writing a lot of "foundation stuff" (standard interfaces, modules, a message system ect.), but I have noticed a pattern, a lot of the stuff is interdependent and I can not debug until everything is done, hence I do not debug for about 3 to 5 hours at a time. I am wondering if this is an acceptable practice for this part of the project, and if not, if anyone can give me some advice?

-----Update-----:

I downloaded some code metrics tools, and my programs cyclomatic complexity is 1.52 which as I understand it is good, and should correlate to high cohesion, if I am wrong please correct me/

Explanation / Answer

This is called coupling. You can reduce coupling by breaking everything into smaller pieces, which should increase the cohesion of each piece. It will make it easier and faster to develop and test each piece.

If you are developing something with dependencies on other pieces, try designing with Dependency Injection in mind. This should let you develop each piece individually, without needing to create all of its dependencies first.