How can I add Force to my object with gravity so that It can travel to Long Distance?

I am new In Unity and I am Developing one Simple game where Plates are Initiate from One place and It will Destroy on click. I want to show my plate flying from one place to another place with Gravity.

My code for Plate Initiate is Below…

void Update () {

    InitTimer -= Time.deltaTime;
    print("InitTimer" +InitTimer);
    if(InitTimer <= 0){
        InitTimer = Random.Range(1f, 2f);
        Instantiate(plate,new Vector3 (range,transform.position.y,transform.position.z), Quaternion.identity);
    }

}

Can Anyone give me any reference code or any guidance?

I want to fly my every plate In one Direction.

Thank You In Advance…

Regards,

Dharmesh Kheni

It works for me thanks for help.. [Dharmesh][1] [1]: http://www.variyasoftsolutions.com/unity3d.html

please mark it as solved if his answer helped you

1 Answer

1

Do you want it to be like skeet shooting? In which case you need to add a rigidbody to your plates, then use Vector3.AddForce(transform.forward * strength) after instantiating. Shooting them could be accomplished with Raycasts.

I've converted this comment from below the question to answer so that OP can mark it as selected. @LearnUnity3d you should now select this as answer.