To move a 3d game object

I want to drag a 3d gameobject in its x axis along with mouse. please help me to do this!

Hi,
Did you try to do any searches before you came to ask that question? There are many tutorials and writings out there on the topic. Search for “Unity drag object with mouse” and it will bring you examples.

1 Like

Hi sir,
Actually what I want is, I want to create a 3d slider like UI slider. I checked some mouse dragging codes, but its all about dragging object on its world(x,y,z).