Trick is now pickup-able and is not scored by baskets
This commit is contained in:
@@ -92,6 +92,11 @@ public class PlayerPickupController : MonoBehaviour
|
||||
rb.mass = 0;
|
||||
}
|
||||
|
||||
if (heldObject.TryGetComponent<TrickController>(out var trick))
|
||||
{
|
||||
trick.SetCarried(true);
|
||||
}
|
||||
|
||||
if (col != null) col.enabled = false;
|
||||
break;
|
||||
}
|
||||
@@ -106,6 +111,10 @@ public class PlayerPickupController : MonoBehaviour
|
||||
rb.bodyType = RigidbodyType2D.Dynamic;
|
||||
rb.gravityScale = 1;
|
||||
}
|
||||
if (heldObject.TryGetComponent<TrickController>(out var trick))
|
||||
{
|
||||
trick.SetCarried(false);
|
||||
}
|
||||
Collider2D col = heldObject.GetComponent<Collider2D>();
|
||||
if (col != null) col.enabled = true;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user