I got this little plugin i'm mucking around, this is just a snippet, but the idea is still there:
The problem: quest::say always just says "Requires " once, and never iterates/echos anything of note.
pastebin probably easier to read.
http://pastebin.com/NGwDt2Rj
Code:
sub DoArmorHandin {
my $armor_list;
$tmp_zone = 113;
$tmp_class = 9;
$armor_list[$tmp_zone][$tmp_class][6] = {slot => 19, item => 24938, reward => 31014}; #boots
foreach my $entry ($armor_list[$zoneid][$class]) {
quest::say("Requires ".$entry);
if (plugin::check_handin(\%itemcount,$entry{item}) => 1 &&
$cash >= (plugin::DoPricingBySlot($entry{slot})*1000)) {
quest::summonitem($entry{reward});
return 1;
}
}
return 0;
}