Rayを飛ばす時にRay2D ray = new Ray2D(transform.position, transform.up);のように書くと transform.upの方向にRayを飛ばしてくれるのですが、このtransform.upはtransform.upとtransform.rightしかないんですよね。 (下なら-transform.up左なら-transform.rightと書く) ...
When creating bouncing bullets or lasers, the reflection calculation can be very complicated, but Unity has a command called Vector2.Reflect(or Vector3.Reflectfor 3D) that allows you to easily obtain ...