Go Back   EQEmulator Home > EQEmulator Forums > Quests > Quests::Q&A

Quests::Q&A This is the quest support section

Reply
 
Thread Tools Display Modes
  #1  
Old 01-23-2010, 06:50 PM
Tilar
Sarnak
 
Join Date: Oct 2009
Posts: 35
Default Looking for suggestions... And some help

I'm toying with the idea of a vender that gives the epic 1.0, but he also gives a quest for some good armor depending on the class. Here is what I have so far. He responds to everything except the turn ins. He'll take anything but give nothing in return and he won't return anything regardless of if it's wrong or not.


Code:
sub EVENT_SPAWN
{
$x = $npc->GetX();
$y = $npc->GetY();
quest::set_proximity($x - 100, $x + 100, $y - 100, $y + 100);
}

sub EVENT_ENTER
{
quest::say ("Hey you, $race... Come here. I have a deal for you. Around behind the building.");
}

sub EVENT_SAY 
{

if ($text =~/Hail/i){
quest::say ("Shhh, Not so loud $name. I'm looking for a brave soul to gather a few items for me. In return I will give you something I 'found' that might be of use to you. Are you up to the [challenge]? If not, I can send you to New Tannon if you [wish]."); 
}

if ($text =~/wish/i){
quest::movepc(202, 314.84, 264.41, -125.87);
}


if ($text =~/challenge/i){
quest::say ("I'm not used to this cold weather. I don't know how these barbarians can stand it in this God forsaken place. There are a few items I'd like to have to help keep me warm. A pair of 'Wolf Fur Slippers' from Permafrost, A 'Bloodstained Tunic', 'Split Paw Hide Gloves' and a pair of 'Gossamer Leggings' for the wife. THIS QUEST IS BROKE FOR NOW."); 
}
}

sub EVENT_ITEM {
	if((plugin::check_handin(\%itemcount, 1314 => 1)) ||
		(plugin::check_handin(\%itemcount, 3308 => 1)) ||
		(plugin::check_handin(\%itemcount, 2280 => 1)) ||
		(plugin::check_handin(\%itemcount, 1368 => 1))) 
    	quest::say("Thank you, $name.");#Text made up
	quest::summonitem(2418); #Hoop of the Traveler just for testing
}
  else {
   quest::say(" Here $name, I don't need this."); #text made up
   plugin::return_items(\%itemcount);
   return 1;
  }

}


I think in order to keep it fairly simple, at least from my limited knowledge would be once he gets the items he wants, he gives the player a single item that can be turned in and exchanged for class specific items, Maybe from another quest npc. Right now I'd like to get this part working.
Reply With Quote
  #2  
Old 01-24-2010, 08:59 PM
neiv2
Hill Giant
 
Join Date: Mar 2009
Location: CO
Posts: 183
Default

Looks like you're missing an open bracket "{" after the final plugin statement and before the quest::say().
Reply With Quote
  #3  
Old 01-24-2010, 09:03 PM
neiv2
Hill Giant
 
Join Date: Mar 2009
Location: CO
Posts: 183
Default

Meant to specify, in the EVENT_ITEM.
Reply With Quote
  #4  
Old 01-25-2010, 07:11 AM
trevius's Avatar
trevius
Developer
 
Join Date: Aug 2006
Location: USA
Posts: 5,946
Default

You also shouldn't need the "return 1;" at the end of your return item part of the script.
__________________
Trevazar/Trevius Owner of: Storm Haven
Everquest Emulator FAQ (Frequently Asked Questions) - Read It!
Reply With Quote
  #5  
Old 01-25-2010, 06:45 PM
Tilar
Sarnak
 
Join Date: Oct 2009
Posts: 35
Default

I messed with this thing all weekend and finally got it. I did take out the "return 1" part, Also I couldnt get it to work using this format for the items,
Code:
	if((plugin::check_handin(\%itemcount, 1314 => 1)) ||
		(plugin::check_handin(\%itemcount, 3308 => 1)) ||
		(plugin::check_handin(\%itemcount, 2280 => 1)) ||
		(plugin::check_handin(\%itemcount, 1368 => 1)))
I used the following and it worked.

Code:
 if (plugin::check_handin(\%itemcount, 1314=>1, 3308=>1, 2280=>1, 1368=>1))
No idea why but I'm not going to question it. I read another post, here where someone was having a similar issue with a class specific rewards quest and I actually used part of what I had started, part of his final script and part of another one from POK and somehow it worked. This is definitely a learning curve for this old man.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

   

All times are GMT -4. The time now is 07:32 PM.


 

Everquest is a registered trademark of Daybreak Game Company LLC.
EQEmulator is not associated or affiliated in any way with Daybreak Game Company LLC.
Except where otherwise noted, this site is licensed under a Creative Commons License.
       
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3