ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/server/ext/Jeweler.pm
(Generate patch)

Comparing deliantra/server/ext/Jeweler.pm (file contents):
Revision 1.5 by elmex, Wed Jan 31 15:53:17 2007 UTC vs.
Revision 1.6 by elmex, Thu Feb 1 01:46:45 2007 UTC

328 cf::POTION => 'potions', 328 cf::POTION => 'potions',
329 cf::SCROLL => 'scrolls', 329 cf::SCROLL => 'scrolls',
330 ); 330 );
331 331
332 for ($self->{cauldron}->inv) { 332 for ($self->{cauldron}->inv) {
333 if (!$_->flag (cf::FLAG_IDENTIFIED) && $_->need_identify) {
334 die "unidentified";
333 if ($_->flag (cf::FLAG_CURSED) || $_->flag (cf::FLAG_DAMNED)) { 335 } elsif ($_->flag (cf::FLAG_CURSED) || $_->flag (cf::FLAG_DAMNED)) {
334 die "cursed"; 336 die "cursed";
335 } 337 }
336 338
337 if (my $k = $type_to_key{$_->type}) { 339 if (my $k = $type_to_key{$_->type}) {
338 push @{$ingreds->{$k}}, $_; 340 push @{$ingreds->{$k}}, $_;
764sub to_object { 766sub to_object {
765 my ($self) = @_; 767 my ($self) = @_;
766 768
767 my $obj = cf::object::new $self->{hash}->{arch}; 769 my $obj = cf::object::new $self->{hash}->{arch};
768 770
771 $obj->item_power ($self->power_to_level); # there have to be strings attached!
772
769 $obj->face ($self->{hash}{face}); 773 $obj->face ($self->{hash}{face});
770 774
771 my $stats = $obj->stats; 775 my $stats = $obj->stats;
772 776
773 $stats->hp ($self->{hash}{spec}{regen}); 777 $stats->hp ($self->{hash}{spec}{regen});

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines