private void paintInDeviceCoords(Graphics g)
	{
		Graphics2D g2 = (Graphics2D)g;
		
		g2.transform(baseTransform);
		
		for (int i = 0; i < chart.getWidth(); i++) {
			for (int j = 0; j < chart.getHeight(); j++) {
				
				// Draw the rectangle
				
		        Rectangle2D rectangle = new Rectangle2D.Float(XPosition + i * multiplier, YPosition + j * multiplier, multiplier, multiplier);
		        g2.draw(rectangle);
		        
		        // Paint with the correct texture
		        paintBox(g2, i, j);
		        

		        // Check for mouse hover effect
		        try {
		        	if (rectangle.contains(baseTransform.inverseTransform(new Point2D.Double((double)mouseXPosition, (double)mouseYPosition), null))) {
		        		if (streamClickEvent) {
		        			// Stream the event
		        			BoxClickedEvent evt = new BoxClickedEvent(chart.getBoxAt(i, j));
		        			
		        			Object[] listeners = eventListeners.getListenerList();
		        	        
		        	        for (int k = 0; k < listeners.length; k += 2) {
		        	            if (listeners[k] == BoxClickedListener.class) {
		        	            	((BoxClickedListener)listeners[k+1]).BoxClicked(evt);
		        	            }
		        	        }
		        		}
		        		
		        		
		        		g2.fillRoundRect(XPosition + i * multiplier, YPosition + j * multiplier, multiplier, multiplier, multiplier/8, multiplier/8);
		        	}
		        } catch (NoninvertibleTransformException e) {
		        	e.printStackTrace();
		        }
		        
			}
		}
		
		if (actionState != GamePanel.ActionState.OnNavigate) {
			for (Pair<Integer> i : targetCoordinates) {
				g2.fillRect(XPosition + i.getFirst() * multiplier, YPosition + i.getSecond() * multiplier, multiplier, multiplier);
			}
		}
        	
		
		// Paint the entities (they should be on top view)
		paintEntities(g2);
		// Sorry mate
		streamClickEvent = false;
	}