using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class JumperControl : MonoBehaviour {

	public float forceMagnitude;
//	public float fallMagnitude;
	public Rigidbody rb;
	public bool mierda;
	public Vector3 zChange;

	void Awake() {
		rb = GetComponent<Rigidbody> ();
		mierda = true;
		zChange = new Vector3 (0f, 0f, -10f);
	}
	void Update () {
		if (Input.GetKeyDown (KeyCode.Space)) {
			rb.AddForce (Vector3.up * forceMagnitude, ForceMode.Impulse);
		}
		if (Input.GetKeyDown (KeyCode.A) && mierda) {
			transform.position += zChange;
			mierda = false;
		}
//		rb.AddForce (Vector3.down * fallMagnitude, ForceMode.Force);
	}
}
