--- deliantra/Deliantra/Deliantra.pm 2007/05/09 11:44:40 1.107 +++ deliantra/Deliantra/Deliantra.pm 2007/05/23 20:21:28 1.108 @@ -349,6 +349,16 @@ } } + # check whether attachment is the same as in the archetype + if (exists $ob->{attach}) { + my $arch = $ARCH{$ob->{_name}}; + my $js = JSON::XS->new->utf8->canonical (1); + + if ($js->encode ($js->decode ($ob->{attach})) eq $js->encode ($arch->{attach})) { + delete $ob->{attach} + } + } + # color_fg is used as default for magicmap if magicmap does not exist $ob->{magicmap} ||= delete $ob->{color_fg} if exists $ob->{color_fg};