Creating own character control...cant figureout gravity in c#

Hello I am working on a custom c# script to move my player around but i am having trouble creating a gravity to allow him to fall. Another would be collision. I want to figure it out but dont know what variables i need to use to achieve this?

Is there a way i can create a global gravity script where the objects i want manipulated can be attached to it? If so how?

There is a Physics.gravity value, which is a Vector3.

If you are using unity physics just apply gravety to the rigidbody but if not then the easiest way to make gravety is to add a constant force to the y-acess in a negative direction.

make sure you use global y axis if your game objects rotate.

Post the code… working without it is like shooting in the dark, yeah you hit a bunch of women and children but are you sure your at the Crips mothers house?

Not sure what the code will help but here it is. I tried using both rigidbody and canstant force, when the game start the player topples over.

this is my lil test dummy for the controls. You cant really till but he fell over from the gravity or the use of constant force,

[using UnityEngine;
using System.Collections;

public class CharacterControl : MonoBehaviour {

	
	//Character Movement
	public int Forward = 10;
	public int Backward = 10;
	public int straffeLeft = 5;
	public int straffeRight = 5;
	public int rotateLeft = 3;
	public int rotateRight = 3;
	
	// Use this for initialization
	void Start () {
	
	}
	
	// Update is called once per frame
	void Update () {
	
		if (Input.GetKey(KeyCode. W) )
		{
			transform.Translate(0, 0,Forward );
		}		
		
		if (Input.GetKey(KeyCode. S))
		{
			transform.Translate(0, 0, -Backward);
		}
		if(Input.GetKey(KeyCode. A))
		{
			transform.Translate(-straffeLeft, 0, 0);
		}
		if(Input.GetKey(KeyCode. D))
		{
			transform.Translate(straffeRight, 0, 0);
		}
	    if(Input.GetKey(KeyCode. Q ))
		{
			transform.Rotate(0, -rotateLeft, 0);
		}
		if(Input.GetKey(KeyCode. E))
		{
			transform.Rotate( 0, rotateRight, 0);
		}	
	}
	
	
	

}
/CODE]