milotoad

u/milotoad


r/Unity3D•

I was wondering how to send a keycode that would be as if I was holding down the arrow key because right now I am using the input managers first 2 indices for the arrow keys. any ideas?

010

r/Unity3D•

So I have this:

void OnCollisionEnter(Collision c) 
{ 
	var joint = gameObject.AddComponent<FixedJoint>();
	joint.connectedBody = c.rigidbody;
}

and its tied to the object I am picking up but I want to be able to delete this joint when I press a key so I can drop the object I picked up with

Destroy (joint);

would I put that in the same class in the Update() method?

21

r/Unity3D•

Ok lets say I had two fingers floating in space and a cube on a table that I wanted to pick up and hold onto. What friction coefficients would I need to use on the these rigid bodies? Right now I have it so I can grab the object but it keeps sliding out of my grasp.

Right now I'm just doing:

void FixedUpdate () { input = new Vector3(Input.GetAxisRaw ("Horizontal"), 0, Input.GetAxisRaw ("Vertical")); if (rigidbody.velocity.magnitude < maxSpeed) { rigidbody.AddForce (input * moveSpeed); } }

Then the arrow keys allow me to open and close the fingers. But what I want it to do is for the fingers to stay closed with out me having to hold the arrow key once it grabs an object.

45

r/Unity3D•

Ok lets say I had a piece of rectangular wood. What if I wanted to use an axe to cut the one piece into two parts at any place in the geometry into two semi-equal parts? Is there an easy way to accomplish this?

42


You've reached the end of this feed.