@Override
    public void running(BehaviorEvent event) {
        if (state != IDLE) {
            if (target == null) return;
            int x = event.getX(), y = event.getY();
            if (group.contains(x, y)) {
                Point p = group.parentToChild(new Point(x, y));
                state = RUNNING_INSIDE;
                int cx = initCursor.x, cy = initCursor.y;
                int x0 = initBounding.x, y0 = initBounding.y;
                if (gridSize == 0) {
                    target.moveTo(x0 + p.x - cx, y0 + p.y - cy);
                } else if (Math.abs(p.x - cx) > gridSize || 
                        Math.abs(p.y - cy) > gridSize) {
                    int gx = (p.x - cx) / gridSize;
                    int gy = (p.y - cy) / gridSize;
                    target.moveTo(x0 + gx * gridSize, y0 + gy * gridSize);
                }
                
            } else {
                state = RUNNING_OUTSIDE;
            }
            // System.out.println("running");
        }
    }