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-17-2010, 10:40 PM
jkennedy
Hill Giant
 
Join Date: Dec 2009
Posts: 175
Default

kk ill fix that but atm i got it so they take the item and give one credit but if i have 2 of the items it takes both and still only 1 credit
Reply With Quote
  #2  
Old 01-18-2010, 12:45 PM
Akkadius's Avatar
Akkadius
Administrator
 
Join Date: Feb 2009
Location: MN
Posts: 2,072
Default

I think you're looking for this, I had this on my server...

The syntax you'll notice has for example $coinages * 10 or 100 or etc, that is the item * whatever value you want it to hold when you want it to return into how many LDON points it returns back to you.

Code:
sub EVENT_SAY
{
   my $coinages = quest::collectitems(1381,0);
   my $coinages1 = quest::collectitems(1384,0);
   my $coinages2 = quest::collectitems(1385,0);
   my $link1 = quest::saylink("exchange", 1);
   my $link2 = quest::saylink("Tokens of Reborn", 1);
   my $link3 = quest::saylink("Small Tokens", 1);
   my $link4 = quest::saylink("Dark Tokens", 1);
   my $link5 = quest::saylink("Dark Tokens of Rebirth", 1);
      if($text=~/hail/i)
            {
            quest::say("Hello $name! are you here to [$link1] your [$link2] for points?.");
            }
      if($text=~/Tokens of Reborn/i)
            {
            quest::say("Yes, there are many ways to find the Dark Tokens, they are scattered out in the lands");
            }
		if($text=~/exchange/i)
            {
            quest::say("Yes, I can exchange [$link3], [$link4], and [$link5].");
            }	
			
      if($text=~/Dark Tokens of Rebirth/i && $coinages > 0) ####DARK TOKENS OF REBIRTH####

				{
               quest::collectitems(1381,1);
               quest::addldonpoints($coinages * 100,2);
               quest::say("$coinages Dark Tokens of Rebirth? Very well, I have embedded Mir in your soul.");
				}
				elsif($text=~/Dark Tokens of Rebirth/i && $coinages < 1)
				{
				quest::say("Are you trying to cheat me you ridiculous $race? You don't have any Tokens!");
				}
		if($text=~/Small Tokens/i && $coinages1 > 0)  ####SMALL TOKENS####
				{
               quest::collectitems(1384,1);
               quest::addldonpoints($coinages1 * 1,2);
               quest::say("$coinages1 Small Tokens? Very well, I have embedded Mir in your soul.");
			  
				}
					elsif($text=~/Small Tokens/i && $coinages1 < 1)
						{
						quest::say("Are you trying to cheat me you ridiculous $race? You don't have any Tokens!");
						}
		if($text=~/Dark Tokens/i && $coinages2 > 0) ####DARK TOKENS####
				{
               quest::collectitems(1385,1);
               quest::addldonpoints($coinages2 * 10,2);
               quest::say("$coinages2 Dark Tokens? Very well, I have embedded Mir in your soul.");
				}
      elsif($text=~/Dark Tokens/i && $coinages2 < 1)
        {
        quest::say("Are you trying to cheat me you ridiculous $race? You don't have any Tokens!");
        }
      }

sub EVENT_ITEM
{		my $numcoins = $itemcount{1381};
		my $numcoins1 = $itemcount{1384};
		my $numcoins2 = $itemcount{1385};
		  my $link1 = quest::saylink("exchange", 1);
         if ($numcoins > 0)
            {
               quest::summonitem(1381,$numcoins);
               quest::say("Well I appreciate the tokens, but why don't you try saying [$link1] to me instead.");
            }
			if ($numcoins1 > 0)
            {
               quest::summonitem(1384,$numcoins1);
               quest::say("Well I appreciate the tokens, but why don't you try saying [$link1] to me instead.");
            }
			if ($numcoins2 > 0)
            {
               quest::summonitem(1385,$numcoins2);
               quest::say("Well I appreciate the tokens, but why don't you try saying [$link1] to me instead.");
            }
				 
				  }
I apologize for how some of my code is structured it's a little sloppy in some areas, that should help!
Reply With Quote
  #3  
Old 01-18-2010, 01:27 PM
jkennedy
Hill Giant
 
Join Date: Dec 2009
Posts: 175
Default

thank you so very much akkadius was exactly what i neede
Reply With Quote
Reply

Thread Tools
Display Modes

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:59 AM.


 

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