… | |
… | |
795 | # within a 5x5 square that have something resembling |
795 | # within a 5x5 square that have something resembling |
796 | # dialogue or support on_say. |
796 | # dialogue or support on_say. |
797 | my ($map, $x, $y) = ($ob->map, $ob->x - 2, $ob->y - 2); |
797 | my ($map, $x, $y) = ($ob->map, $ob->x - 2, $ob->y - 2); |
798 | |
798 | |
799 | for my $npc ( |
799 | for my $npc ( |
800 | grep +($_->invoke (cf::EVENT_OBJECT_SAY, $ob->contr, $msg) && return) || NPC_Dialogue::has_dialogue $_, |
800 | grep +($_->invoke (cf::EVENT_OBJECT_SAY, $ob->contr, $msg) && return) || $_->has_dialogue, |
801 | map +($_, $_->inv), |
801 | map +($_, $_->inv), |
802 | grep $_, |
802 | grep $_, |
803 | map $map->at ($x + $_ % 5, $y + (int $_ / 5)), |
803 | map $map->at ($x + $_ % 5, $y + (int $_ / 5)), |
804 | 0..24 |
804 | 0..24 |
805 | ) { |
805 | ) { |