how to put upward force using tap

hello…

iam new to unity and i just want to ask you about tapping,that if you tap the button the object will goes upward and then if i want to stop tapping the button it will go back to its original position…

we are trying toimplement a game just like water toss that you need to shoot the ring in the pole dat once you tap the ring it applied upward force inorder to shoot the ring to the pole…

i hope you can read this message asap… we nid ur helppp… thank you so muuuuch

This might work not sure, I’ve just made my Mill (Blades) start rotating. This should make your camera rotate, use this to start working out which way it needs to rotate if you understand how Vector3 works. I’m not sure how to make it reset back to its set position you will have to work that one out I’m a nooob at coding.

var button: GameObject; // Attach a GUI.Tecture here
var camera: GameObject; // Attach your Camera Here in your inspector
var speed: int; // Speed of the camera moving upwards

	var btnTexture : Texture;
	function OnGUI() {
		if (!btnTexture) {
			Debug.LogError("Please assign a texture on the inspector");
			return;
		}
		if (GUI.Button(btnTexture))
				camera.transform.Rotate(-Vector3.forward * speed * Time.deltaTime);
				Debug.Log("Clicked the button with an image");
		else {
			Debug.Log("You need to attach a reset script here. Not sure how to do this myself.")
	}

I had that problem just a couple of minutes ago. I solved it by adding:

    if (Input.GetButtonDown ("Jump")) {
        rigidbody.AddRelativeForce (Vector3.up  * 1000);
    }

to the void Update. That said, I am going about this in a strange way because of the way my game works.