add time based street light, fix directional room entrance
This commit is contained in:
@@ -123,16 +123,6 @@ public void WalkInDirection(Vector3 direction)
|
||||
{
|
||||
Vector3 forwardDir = direction;
|
||||
forwardDir.y = 0; // don't move on the y axis
|
||||
|
||||
if (cameraController != null)
|
||||
{
|
||||
// re-matrix the rotation direction so movement is consistent no matter what
|
||||
// the camera rotation is
|
||||
|
||||
Matrix4x4 matrix = Matrix4x4.Rotate(Quaternion.Euler(0, cameraController.playerCamHome.rotation.eulerAngles.y, 0));
|
||||
forwardDir = matrix.MultiplyPoint3x4(forwardDir);
|
||||
}
|
||||
|
||||
forwardDir *= walkSpeed;
|
||||
|
||||
characterController.Move(forwardDir * Time.deltaTime);
|
||||
|
||||
Reference in New Issue
Block a user