Little tweaks
This commit is contained in:
parent
e1fba1deed
commit
8ffc34f2d0
2 changed files with 14 additions and 5 deletions
|
@ -432,7 +432,7 @@ public class DungeonGenerator {
|
|||
r.tiles[pos].type = Room.TileType.ROCK;
|
||||
continue;
|
||||
}
|
||||
float prob2 = 0.02f;
|
||||
float prob2 = 0.04f;
|
||||
if (UnityEngine.Random.value > 1 - prob2)
|
||||
{
|
||||
r.spawnpoints.Add(pos);
|
||||
|
|
|
@ -57,11 +57,20 @@ public class PlayerMovement : MonoBehaviour {
|
|||
//Debug.Log(br);
|
||||
Debug.DrawLine(transform.position, transform.position + br, Color.red, 0.01f, false);
|
||||
}
|
||||
if ( Input.GetAxis("Horizontal") < 0 )
|
||||
rb.MoveRotation(rb.rotation + turnSpeed);
|
||||
//transform.Rotate(Vector3.forward * turnSpeed);
|
||||
if ( Input.GetAxis("Horizontal") > 0 )
|
||||
rb.MoveRotation(rb.rotation - turnSpeed);
|
||||
if (Input.GetAxis("Horizontal") < 0)
|
||||
{
|
||||
//rb.rotation += turnSpeed;
|
||||
rb.MoveRotation(rb.rotation + turnSpeed);
|
||||
} else
|
||||
//transform.Rotate(Vector3.forward * turnSpeed);
|
||||
if (Input.GetAxis("Horizontal") > 0)
|
||||
{
|
||||
//rb.rotation -= turnSpeed;
|
||||
rb.MoveRotation(rb.rotation - turnSpeed);
|
||||
} else {
|
||||
rb.MoveRotation(rb.rotation);
|
||||
}
|
||||
//transform.Rotate(Vector3.forward * -turnSpeed);
|
||||
// Debug lines
|
||||
Debug.DrawLine(transform.position, transform.position + speedVec, Color.magenta, 0.01f, false);
|
||||
|
|
Loading…
Add table
Reference in a new issue