Featured Posts

Animation | Final | Taylor Swift Hellscape

December 20, 2017

Getting Started - Character Model

 

As is the case with a lot of my final projects, I started this assignment with the intent of creating something around Taylor Swift. So, the obvious first step was creating a Taylor Swift avatar on Fuse.

 

 

Fuse doesn't have a lot of templates to choose from, but luckily, I could just go with generic white girl to create my Taylor Swift avatar. I gave her a biker/fighter outfit and medium-length blond hair. I spent quite a lot of time trying to get her facial features right, only to realize later that I did not need to show her face at all in the game.

 

 

Movements Set

 

Once that was done, I exported her to Mixamo.

 

 

I had a lot of fun trying on different animations on Taylor, and since she was already looking tough, I downloaded a lot of martial arts / MMA moves for her. Even the idle state I chose was an idle fighting stance.

 

 

Setting Up Controls

 

Next up was setting up the controls for animation.

 

I initially wanted really dramatic walk/strafe cycle, but the ones I found on Mixamo did not walk/strafe in a straight line, so I used Gabe's animation package from the google drive folder.

 

I also had some issues with the code in the tutorial, so I added some extra variables and functions to my animation script.

 

 

if (Input.GetButtonDown ("Jump")) {
            myAnimator.SetBool ("Jumping", true);
            Invoke ("ActionToggle", .2f);
            Invoke ("StopJumping", .5f);
        }

 

 

...

 

    void StopJumping (){
        myAnimator.SetBool ("Jumping", false);
        myAnimator.SetBool ("isInAction", false);
    }

 

    void ActionToggle(){
        myAnimator.SetBool ("isInAction", true);    
    }

 

 

 

Even though I had StopJumping(), the program kept going to the start of the movement before StopJumping got invoked. So for example if I press spacebar, the character would go into the start of jumping animation, say .1f, go back to 0f, then .1f, and keep repeating this until .5f when StopJumping() gets invoked. The variable isInAction basically prevents the loop by telling the program the character is already in the middle of the animation and should not loop to the start.

 

I had 8 controls for the character:

  • W/S (Vertical): run forward/backward

  • A/D (Horizontal): left/right strafe

  • Spacebar (Jump): jump

  • Left Click (Fire 1): kick

  • Right Click (Fire 2): headbutt

  • Middle Click (Fire 3): tornado kick

 

Additionally, I set the mouse to move the camera and rotate the character. I copied code from this tutorial.

 

Environment

 

I wanted Taylor to fight something, and I found this free face 3D model from TurboSquid.

 

 

For some reason, the anchor point of this face wasn't its actual center, so I took advantage of that and made it rotate around the center point.

 

 

This was the script that I attached to the face prefab:

 

transform.Rotate (new Vector3 (0, 70, 0) * Time.deltaTime);

 

 

Once I had multiple creepy faces in my scene, I downloaded more things from the Asset Store. First was Realtime Reflections.

It came with this reflective water surface that gave my scene a real creepy feel.

 

Next was Purple Space Nebula Skybox.

 

 

I tried adding multiple directional/spot lights, but I did not really figure these out, so I just changed the existing directional light's color to red.

 

I also had sound playing in the scene.

 

This was the final scene setup I had.

 

 

Collisions

 

I wanted to make Taylor fight these faces, and tried to make some collision physics work. However, my onCollisionEnter / onTriggerEnter did not get called at all when I collide her with the faces. I had Rigidbody & Capsule Collider for Taylor, and Rigidbody & Box Collider for the faces.

 

Maybe I need to look into Kinematic type or check my code again, but so far the game works without anymore scripting. Taylor can knock down some faces, but not send them flying away.

 

 

 

 

 

 

 

Share on Facebook
Share on Twitter
Please reload

Related Posts
Please reload

Generative Music | Latent Space Sequencer

December 13, 2018

1/10
Please reload

Recent Posts
Please reload

Search By Tags