#Collider is offset in Y Axis (topdown 2D Game)
1 messages · Page 1 of 1 (latest)
Just use the built-in collider bruh
i have a box collider 2d on both objects
and in the code for the movement i use them
but now it seems to be using the pixels instead of the box collider
i found the issue, but dont know how to fix it
is there any variable of the offset of the box collider?
i figured it out: for the origin position of Physics2D.BoxCast you had to add the position of the gameobject to the collider offset (GetComponent<BoxCollider2D>().offset)