From a4e8c201077e389e71b4a0fa9a63ffe666481c42 Mon Sep 17 00:00:00 2001 From: Jesse Luehrs Date: Sun, 25 May 2014 10:45:06 -0400 Subject: don't allow fusing bosses that haven't been beaten yet --- lib/Games/SMTNocturne/Demons/Demon.pm | 3 +++ 1 file changed, 3 insertions(+) (limited to 'lib/Games/SMTNocturne/Demons') diff --git a/lib/Games/SMTNocturne/Demons/Demon.pm b/lib/Games/SMTNocturne/Demons/Demon.pm index 41b689a..1185f2d 100644 --- a/lib/Games/SMTNocturne/Demons/Demon.pm +++ b/lib/Games/SMTNocturne/Demons/Demon.pm @@ -40,6 +40,9 @@ sub from_fusion_stats { @possible = grep { $_->fusion_type eq $options->{fusion_type} } @possible if $options->{fusion_type}; + my %bosses = map { $_ => 1 } @{ $options->{bosses} || [] }; + @possible = grep { !$_->boss || $bosses{$_->name} } @possible; + my $found; for my $demon (@possible) { $found = $demon; -- cgit v1.2.3-54-g00ecf