Week 10 – UmLet Movement Code 2

This is the UmLet for the second version of the Movement script.

Movement2.cs

_spd is the variable controlling the speed of movement

_hz is used to get the movement for the forward – backward axis

rb is connecting the RigidBody to the code, for a future jumping function.

_rFacing and _lFacing are used when switching the direction the player is facing

_sw is the variable used to manage the switching of direction

The script does fulfill the scope set out, allowing the player to move on the forward – backward axis and also changing the direction correctly.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s