Fixed mouse hovering detection
[sixth-3d.git] / src / main / java / eu / svjatoslav / sixth / e3d / renderer / raster / shapes / basic / texturedpolygon / TexturedPolygon.java
index cafcbbf..3539ab1 100644 (file)
@@ -141,11 +141,11 @@ public class TexturedPolygon extends AbstractCoordinateShape {
         projectedPoint3.roundToInteger();
 
         if (mouseInteractionController != null)
-            if (renderBuffer.mouseEvent != null)
+            if (renderBuffer.getMouseEvent() != null)
                 if (pointWithinPolygon(
-                        renderBuffer.mouseEvent.coordinate, projectedPoint1,
+                        renderBuffer.getMouseEvent().coordinate, projectedPoint1,
                         projectedPoint2, projectedPoint3))
-                    renderBuffer.objectUnderMouse = mouseInteractionController;
+                    renderBuffer.setObjectUnderMouse(mouseInteractionController);
 
         // Show polygon boundaries (for debugging)
         if (showBorders)