Comments

  • The UpdateTypedWord function starts by determining the zombie state, as player typing and combat only applies when the zombie is chasing or attacking.
  • Next, the CompareWords function determines the extent of the match, if any, between the typed word and the associated word. This function is part of the WordList class, coded in the last chapter. It returns a string representing the amount of match between the typed string and the associated word. If there is no match, the string length will be 0. If there is a partial match, the string length will be > 0, but less than the associated word length. There is a complete match when the associated word length and the typed-string length are identical.
  • When a match is detected, the OnTypingMatched ...

Get Mastering Unity 2017 Game Development with C# - Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.