what i want here when i touch the screen character move when i touch specific game object (as button ) character should jump.
i have completed both the thinks, but the problem I’m facing currently when i touch Game object its calculate the screen touch also, because of that my character move’s also with jump.
is there is any possibility that when i touch the game object it’s should not calculate as screen touch, so my character only jump when we touch game object.
Find a tutorial or post on how to use raycast to detect that you are pointing at the GameObject (mesh probably) instead of scenery (there are plenty of these; just search for raycast).
checked with raycast, but is there any option in raycast that touch has ended. because what i want when object is touch animation is playing as we remove finger the animation should stop.