View Single Post
  #4  
Old 02-26-2008, 09:38 PM
AndMetal
Developer
 
Join Date: Mar 2007
Location: Ohio
Posts: 648
Default

Quote:
Originally Posted by shaznito View Post
Please let me know what you think and make sure I'm not overlooking anything.
Just a few tweaks...

Code:
#############
#Quest Name:Cleric Supplies
#Author:Shaznito
#NPCs Involved:Beek Guinders
#Items Involved:Berries, Black Wolf Skin, Ruined Wolf Pelt
#################


sub EVENT_SAY { 
	if($text=~/hail/i) {quest::emote("waves enthusiastically and says, 'Hay, ho, there, young Halfling!  I'd love to yak it up with you but I'm a bit busy at the moment, trying to find some [help].");}
		if($text=~/what help/i) {quest::say("Well, we're experimenting with some tanning methods but we're running low on supplies. We need to find someone to go out and [gather some things]. Seems no one wants to do an honest day's work any more. I'd do it myself but, errrr, my, uhhh, foot hair has been hurting lately... yes, that's it.");}
			if($text=~/I will gather some things/i) {quest::say("Ahhh, excellent! Okay, first, we'll need a couple of wolf pelts. They don't have to be perfect, completely ruined would work just fine, hehe. I'll also need a black wolf skin and a handful of berries. The berries you should be able to find out in the Thicket. I hear they grow in a small canyon near the lone tower. Hurry, hurry!");}
}

sub EVENT_ITEM {
	if (plugin::check_handin(\%itemcount, 13045 => 1, 13782 => 2, 13758 => 1) && $race eq "Halfling") {
		quest::say("Hey, great! You found the materials! We'll get to work right away. If you find any more, please come by again. Here's a little something for your troubles, friend.");
		quest::summonitem(15207);
		quest::faction(259,10);
		quest::faction(208,10);
		quest::faction(133,10);
		quest::exp(50);
		quest::givecash(23,13,0,0);
	} else {
		quest::say("Whoooops! I'll need the two ruined wolf pelts along with the berries and black wolf skin before I can reward you, $name. Don't dawdle");
		plugin::return_items(\%itemcount);
	}
}

#END of FILE Zone:rivervale  ID:19111 -- Beek_Guinders
  • Fewer spaces = easier to read.
  • Changed 1st say to an emote, otherwise it will say "says 'waves enthusiastically and says '...'".
  • Using plugin::check_handin removes the items from itemcount, and only gives back unused items. You may want to test this to make sure it's giving the desired result.
  • Added check to see if you're a Halfling. Might need some more dialogue & tweaking for what happens when you're not a Halfling. Right now it gives the dialogue about what you need, and will return the items.
  • If you don't have all the items, gives the dialogue about the items he needs.

Code:
INSERT INTO `forage`(`id`,`zoneid`,`Itemid`,`level`,`chance`) values (429,33,13045,0,100)
INSERT INTO `forage`(`id`,`zoneid`,`Itemid`,`level`,`chance`) values (430,202,13045,0,100)
INSERT INTO `forage`(`id`,`zoneid`,`Itemid`,`level`,`chance`) values (431,3,13045,0,100)
INSERT INTO `forage`(`id`,`zoneid`,`Itemid`,`level`,`chance`) values (432,224,13045,0,100)
Need to make sure each of the IDs are unique (as was mentioned in the 2nd post ).

Other than that, you should be good to go.
__________________
GM-Impossible of 'A work in progress'
A non-legit PEQ DB server
How to create your own non-legit server

My Contributions to the Wiki
Reply With Quote