These last few weeks I have been banging my head against the proverbial digital wall, trying to get my computer game -- or 3D digital game-based learning environment, which sounds more sophisticated -- to work just the way I would like. The primary problems were: (1) the door animations in the game just didn't open and close right and (2) I couldn't get two animations on the same mesh object to play independently of each other inside of Unity. Taking inspiration from a Talking Heads song, I decided to burn everything to the ground and start over. As trying to explain my problems in written format is difficult, I made a video highlighting what the problems were and the solution I found for them:
So what have I learned? Well, for starters, any changes (e.g., scaling and rotation) you want to make to a Blender object that you will eventually import into Unity *must* be done in Edit Mode, not in Object Mode. If you made these changes already in Object mode then Alt-R will clear the rotation and Alt-S will clear the scaling. Apparently, you cannot include more than one animation armature on an object, which makes animations working independently of each other difficult to create (e.g., opening and closing two doors). However, this worked example by Devin and Calin Reimer shows that it is possible, with some advanced knowledge of how Blender animations work inside of Unity and a handle on the C# programming language. Thanks, Devin! Oh, by the way, if you use Devin's script in Unity when you have the Terrain Toolkit loaded, you'll get nothing but errors.
Now it's just a question of getting the models rebuilt, working on a GUI for the player to use, and getting some of the game functionality programmed. Trying to make the deadline by end of next semester so that I can run an experiment with a beginning German language course and publish the results. Let's see if I will be able to get everything done by then.