Inconsistencies with your own C# style guide

Hi,

I’ve noticed a lot of inconsistencies in your c# code,
not only the book isn’t consistent with itself, it also isn’t consistent with YOUR OWN c# for unity style guide.

Some examples:

Methods
some of your methods are camelCased while other are PascalCased, though most of the time private ones are camelCased and public ones are PascalCased this isn’t always the case.

Your style guide clearly suggesting:

Methods are written in PascalCase. For example DoSomething().

Access Level Modifiers

Almost every class in your book have a mix of public variables, private variables and variables with no access modifiers IN THE SAME CLASS. The same goes for the class methods, some methods have access level modifiers, some doesn’t (especially the IEnumerator ones, but not them only).

And again your own style guide suggests:

Access level modifiers should be explicitly defined for classes, methods and member variables.

Now, I know you’ve written the style guide after the book was done, and I know that few writers were involved in this book, but this is not an excuse for book inconsistencies, and even worse, inconsistencies in the same class.

This isn’t only confusing your readers, but give the entire book a very unprofessional and immature appeal.

I hope you take this review seriously and make this book better than its current shape. I have a lot of admiration for what you’re doing here, and I’m a big fan of everything you do for the community, but don’t let your popularity lower your quality.

Peace

Hey @oronbz ,

Thanks for your comment!

That guide was updated by me 4 days ago and is intended to be used going forward. However, the book was written quite a while ago so it still uses the old standards.

That said, we do take your review seriously and we’ll review the code. We strive for the highest quality, especially in our books. Thanks for bringing this up!

Cheers,
Eric