From 9cc2cee9367363b6b35c3dae2d63b2838e2ae9d2 Mon Sep 17 00:00:00 2001 From: Ray Date: Mon, 31 May 2021 18:32:35 +0200 Subject: [PATCH] Update text_draw_3d.c --- examples/text/text_draw_3d.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/examples/text/text_draw_3d.c b/examples/text/text_draw_3d.c index bc4c55293..a579a528b 100644 --- a/examples/text/text_draw_3d.c +++ b/examples/text/text_draw_3d.c @@ -191,10 +191,10 @@ int main(void) Ray ray = GetMouseRay(GetMousePosition(), camera); // Check collision between ray and box - bool collision = CheckCollisionRayBox(ray, + RayCollision collision = GetRayCollisionBox(ray, (BoundingBox){(Vector3){ cubePosition.x - cubeSize.x/2, cubePosition.y - cubeSize.y/2, cubePosition.z - cubeSize.z/2 }, (Vector3){ cubePosition.x + cubeSize.x/2, cubePosition.y + cubeSize.y/2, cubePosition.z + cubeSize.z/2 }}); - if (collision) + if (collision.hit) { // Generate new random colors light = GenerateRandomColor(0.5f, 0.78f);