📅  最后修改于: 2022-03-11 14:58:41.607000             🧑  作者: Mango
//you sould be able to get away with something like this:
RaycastHit2D hit = Physics2D.CircleCastAll(currentSoldier.transform.position, currentSoldier.weapon.range, new Vector3(0, 0, 0), 0f);
transform transform = hit.transform;