From aa078f4d46a6b6f524a671f48e3c33e84a7d095a Mon Sep 17 00:00:00 2001 From: Godzil Date: Thu, 20 Feb 2020 00:47:02 +0000 Subject: [PATCH] Fix in world. --- source/world.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/world.cpp b/source/world.cpp index 936ab95..fa45c6b 100644 --- a/source/world.cpp +++ b/source/world.cpp @@ -83,9 +83,9 @@ Intersect World::intersect(Ray r) { Intersect xs = this->objectList[i]->intersect(r); - for(j = 0; xs.count(); j++) + for(j = 0; j < xs.count(); j++) { - ret.add(xs[i]); + ret.add(xs[j]); } }