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

Comparing deliantra/Deliantra/Deliantra.pm (file contents):
Revision 1.46 by root, Thu Mar 16 01:34:01 2006 UTC vs.
Revision 1.49 by root, Thu Mar 16 22:10:25 2006 UTC

310 my ($obj) = @_; 310 my ($obj) = @_;
311 311
312 require Crossfire::Data; 312 require Crossfire::Data;
313 313
314 my $root; 314 my $root;
315 my $attr = { };
315 316
316 my $arch = $ARCH{ $obj->{_name} }; 317 my $arch = $ARCH{ $obj->{_name} };
317 my $type = $obj->{type} || $arch->{type}; 318 my $type = $obj->{type} || $arch->{type};
318 319
319 if ($type > 0) { 320 if ($type > 0) {
327 or die "internal error: ATTR0 without 'required'"; 328 or die "internal error: ATTR0 without 'required'";
328 329
329 keys %$req; 330 keys %$req;
330 while (my ($k, $v) = each %$req) { 331 while (my ($k, $v) = each %$req) {
331 next type 332 next type
332 unless $obj->{$k} eq $v || $arch->{$k} eq $v; 333 unless $obj->{$k} == $v || $arch->{$k} == $v;
333 } 334 }
334 335
335 $root = $_; 336 $root = $_;
336 } 337 }
337 } 338 }
338 339
339 my $attr = { }; 340 my @import = ($root);
340 341
341 my @import = (\%Crossfire::Data::DEFAULT_ATTR, $root); 342 unshift @import, \%Crossfire::Data::DEFAULT_ATTR
343 unless $type == 116;
344
342 my (%ignore); 345 my (%ignore);
343 my (@section_order, %section, @attr_order); 346 my (@section_order, %section, @attr_order);
344 347
345 while (my $type = shift @import) { 348 while (my $type = shift @import) {
346 push @import, @{$type->{import} || []}; 349 push @import, @{$type->{import} || []};

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines