K

Size: a a a
K
А
W3
А
W3
А
W3
А
KE
KS
M
AN
private void Update()
{
transform.Translate(Vector3.forward * speed * direction * Time.deltaTime);
Plane[] planes = GeometryUtility.CalculateFrustumPlanes(Camera.main);
if (!GeometryUtility.TestPlanesAABB(planes, collider.bounds))
direction *= -1;
}
AP
private void Update()
{
transform.Translate(Vector3.forward * speed * direction * Time.deltaTime);
Plane[] planes = GeometryUtility.CalculateFrustumPlanes(Camera.main);
if (!GeometryUtility.TestPlanesAABB(planes, collider.bounds))
direction *= -1;
}
AP
АА
private void Update()
{
transform.Translate(Vector3.forward * speed * direction * Time.deltaTime);
Plane[] planes = GeometryUtility.CalculateFrustumPlanes(Camera.main);
if (!GeometryUtility.TestPlanesAABB(planes, collider.bounds))
direction *= -1;
}
AN
AP
AP
AN
AN