void GrabThing(Rigidbody2D rigidbody2D) { if (GrabJoint != null) { return; } GrabJoint = this.gameObject.AddComponent <HingeJoint2D>(); GrabJoint.connectedBody = rigidbody2D; GrabJoint.anchor = new Vector2(0, 4.68f); massBuffer = centerController.getRig().mass; centerController.getRig().mass = 1; centerController.gameObject.transform.SetParent(rigidbody2D.gameObject.transform); }
public void enableAbility(CenterController centerController) { _isEnable = true; armRig = centerController.getArmController().getRig(); playerRig = centerController.getRig(); armController = centerController.getArmController(); }
public override void excute() { base.excute(); if (freze) { centerController.getRig().velocity = Vector2.zero; } }
public void enableAbility(CenterController centerController) { rig = centerController.getRig(); _isEnable = true; }
public void enableAbility(CenterController centerController) { this.centerController = centerController; massBuffer = centerController.getRig().mass; _isEnabled = true; }