Mercurial > boosterpack
view Rule.pm @ 5:e91d6f908222 boosterpack
[svn r7] finished!
author | robert |
---|---|
date | Tue, 08 Sep 2009 06:55:23 -0400 |
parents | d7dd496a4fa6 |
children | 8c6d2ce90677 |
line wrap: on
line source
1 package Rule;2 use List::Util qw(first max maxstr min minstr reduce shuffle sum);4 sub new5 {6 my $class = shift;8 my $hashREF =9 {10 _rarity_map => {"Rare" , 1 , "Uncommon" , 3 , "Common" , 6},11 _sets => ("Base Set")15 };17 $objectREF = bless($hashREF, $class);19 return $objectREF;21 }24 sub getRarityMap { return @_[0]->{'_rarity_map'}; };25 sub getSets { return @_[0]->{'_sets'}; }28 sub setRarityMap { $_[0]->{_rarity_map} = $_[1]; }29 sub setSets { $_[0]->{_sets} = $_[1]; }32 1;