private void OnDisplayGoChange(ActorObj actorGo) { collider2D = actorGo.GetBodyCollider(); Vector2 offset = GetColliderOffset(collider2D); UpCheckPoint = new Vector2(offset.x, offset.y + collider2D.bounds.extents.y + CollisionOffset); DownCheckPoint = new Vector2(offset.x, offset.y - collider2D.bounds.extents.y - CollisionOffset); RightCheckPoint = new Vector2(offset.x + collider2D.bounds.extents.x + CollisionOffset, offset.y); LeftCheckPoint = new Vector2(offset.x - collider2D.bounds.extents.x - CollisionOffset, offset.y); colliderShape = new Shape(); colliderShape.ShapeType = ShapeType.AABB; colliderShape.AABBMin = new Vector2(offset.x - collider2D.bounds.extents.x, offset.y - collider2D.bounds.extents.y); colliderShape.AABBMax = new Vector2(offset.x + collider2D.bounds.extents.x, offset.y + collider2D.bounds.extents.y); }