Hey, so i ran across this little problem, i dont know how to raycast around my player. At this point i can only raycast at the top, here is the example:
Heres the code, its pretty straitght Forward:
for(float i = 0; i < amount; i += 0.25f)
{
Vector2 pos = new Vector3(posX + i, posY, 0);
RaycastHit2D hit = Physics2D.Raycast(transform.position, pos, distance);
Debug.DrawRay(transform.position, pos, Color.red);
if (hit.collider != null)
{
//More Code.....