



package FollowTurtle;


@ISA = qw(Turtle
);


sub follow {
    my ($self,$b,$speed) = @_;

    my $dir = atan2(($b->y - $self->y) , ($b->x - $self->x))*360/3.1415926/2;
    $self->direction($dir);
    $self->forward($speed);
}

