Games::RailRoad::Train - a train object
version 1.101330
This class models a train object that moves on the rails.
The node from where the train is coming (a Games::RailRoad::Vector object).
The node where the train is headed (a Games::RailRoad::Vector object).
A number between 0 and 1 indicating where exactly the train is between its from and to nodes.
Create and return a new train object. One can pass a hash reference with the available attributes.
Request $train to draw itself on $canvas, assuming that each square has a length of $tilelen.
$train
$canvas
$tilelen
Jerome Quelin
This software is copyright (c) 2008 by Jerome Quelin.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install Games::RailRoad, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Games::RailRoad
CPAN shell
perl -MCPAN -e shell install Games::RailRoad
For more information on module installation, please visit the detailed CPAN module installation guide.