Miscellaneous comments on the early access version

Here’s some miscellaneous comments or errata which was found when reading the early access version of the book. Although perhaps a bit picky, it might be of value when the final version is assembled.

– In chapter 3, page 69, there’s a camera shake script added in the picture. However, the reader has at that point only been given instructions to add the PlayerController script, so gets confused how it was added.

– In chapter 4, page 90, there could be a reminder not to forget to press the Apply button, after setting up the RigidBody and SphereCollider for the Alien GameObject in the hierarchy. Otherwise, if the reader forgets it, when playing the game in chapter 5, page 125, he will wonder why the spawned aliens don’t react upon being hit by a bullet.

Well, he might soon figure it out, but anyway, it wouldn’t hurt. For the record, the actual instruction to do so is present in the book, but comes a few pages later, on page 130, in another context.

– In chapter 6, page 146, the description of what happened behind the scenes is a bit unclear. There’s no mentioning of the new Animator component which was added to the BobbleArena game object. And the Animator controller (different from the component) was added in the project hierarchy, under animations. It could have been mentioned where to find this.

– In chapter 7, page 184, there’s a typo in the following code:

Rigidbody bullet = createBullet();
bullet.GetComponent<Rigidbody> ().velocity = transform.parent.forward * 100;

I believe it should be:

Rigidbody bullet = createBullet();
bullet.velocity = transform.parent.forward * 100;

– In chapter 7, page 187, it says:

“In the Inspector, select the Pickup prefab and set Layer property to Upgrade and
select No, this object only when prompted.”

However, the layer was already set to Upgrade. I’m not sure how this happened. The layers were manually added in an earlier chapter, and I’m pretty sure I never set the layer when working with the script for the prefab.

– In chapter 7, page 189, you drag the BobbleMarine-Body game object into the Gun property of the GameManager. The Gun is a Script and the BobbleMarine-Body is a GameObject. There could be an explanation that Unity automatically finds the script component (Gun) for that game object. I’m not sure if this has been covered before.

– In chapter 7, page 194, it could be mentioned that it’s the Audio Source of the BobbleMarine-Body which should be used when setting the output property to the Gun group. I first tried setting the Gun group on the same audio source as the sound manager group, incorrectly believing the output field was able to hold a collection of objects.

– In chapter 8, page 203, the salty remark on another game seems to me a bit out of place, in this otherwise so wittily and positively written tutorial.

– In chapter 8, when playing the game after the code for beheading the marine is in place, I have seen several times the headless body continue to firing bullets. Thus, there must exist some state in the execution of the game that killing the marine at exactly that state will leave the gun firing.

– In chapter 8, page 229, when bringing up the animation window, the animation event ActivatePlatform() was already present as a pip on the gray bar.

– In chapter 8, when playing the final version and watching the end sequence, on my screen the elevator moved up and got the player out of sight. It looked better if the camera was allowed to follow the player to the top. Thus, the following line can optionally be commented out:

public class Arena : MonoBehaviour {
	void OnTriggerEnter(Collider other) {
		//Camera.main.transform.parent.gameObject.GetComponent<CameraMovement>().enabled = false;

On a final note and generally speaking, thank you for a very fun and informative tutorial. Unity suddenly feels so much more approachable. I cannot wait to read the rest of the tutorials!

Great commentary. Thanks heaps. Yes, I also enjoyed the first 8 chapters and have high hopes for the remainder of the book.

Thanks for the great feedback! These chapters are still in development and we’ll make sure to fix these issues before release. I’m glad you enjoyed the chapters! More to come rather soon.