public void act() 
    {   
        if(Greenfoot.mousePressed(this)) {
            startX = getX();
            startY = getY();
        }
        //Enables the checker to respond to mouse drags
        //Only moves the checker to diagonal posisitons
        if(Greenfoot.mouseDragged(this)) {
            MouseInfo mouse = Greenfoot.getMouseInfo();
            setLocation(mouse.getX(), mouse.getY());
        }

        //gets performed when the user drops the checker on the board
        if(Greenfoot.mouseDragEnded(this)){
            if(isValidSpot(startX, startY, getX(), getY()) && ((CheckerBoard)getWorld()).playerTurn() == this.team){
                //Eat players jumped over
                jumpCheckers();
                ((CheckerBoard)getWorld()).nextPlayersTurn();

            } else {
                setLocation(startX, startY);
            }

            List<Object> objects = getIntersectingObjects(Object.class); 
            for(Object o : objects) {
                if(o instanceof Bomb) {
                    getWorld().removeObject((Actor)o);
                    getWorld().removeObject(this);
                    break;
                } else if(o instanceof Mushroom) {
                    o = (Mushroom)o;
                    ((Mushroom)o).makeKing(this);
                    break;
                } else if(o instanceof Tunnel) {
                    o = (Tunnel)o;
                    ((Tunnel)o).transport(this);
                    ((Tunnel)o).makeKing(this);
                    break;
                }
            }
        }
    }