View Single Post
  #7  
Old 07-14-2009, 02:02 PM
Kilralpine
Sarnak
 
Join Date: Jul 2004
Posts: 98
Default

Yea In the Past Ive Used The Trade Item In Deal - But I Wanted a Much More Cleaner Setup... Heres What I Came Up With (And Thx Trevius I Used Parts and Pieces of your Kill Credit Script)
Code:
###Zone - Guildhall###
###NPC - A lost coldain###
###Quest - Claiming Revenge###

sub EVENT_SAY {

my $hand = quest::saylink("hand");
my $claw = quest::saylink("claw");
my $Ready = quest::saylink("ready");
my $Hammer_of_the_Fallen = quest::saylink("Hammer of the Fallen");
my $Dwarvenbound_Mask = quest::saylink("Dwarvenbound Mask");
my $Choose_Hammer_of_the_Fallen = quest::saylink("Choose Hammer of the Fallen");
my $Choose_Dwarvenbound_Mask = quest::saylink("Choose Dwarvenbound Mask");
my $Time_Lost_Coldain_Wand = quest::saylink("Time-Lost Coldain Wand");
my $Choose_Time_Lost_Coldain_Wand = quest::saylink("Choose Time-Lost Coldain Wand");

  if($text=~/hail/i) {
$client->Message(2, "Hello stranger, would you like to lend an old man a [$hand]?");
}

  if($text=~/^hand$/i) {
  	$client->Message(2, "A dragon by the name Hsagra has slain an ole' friend of mine, retrieve her [$claw] by any means possible and I will reward you");
  }
  
    if ($text =~/^claw$/i) {
  	quest::itemlink(2431);
  }
 
   if($text=~/^Hammer of the Fallen$/i) {
  	quest::itemlink(2685);
  }
  
   if($text=~/^Dwarvenbound Mask$/i) {
  	quest::itemlink(2686);
  }

   if($text=~/^Time-Lost Coldain Wand$/i) {
  	quest::itemlink(2687);
  }

   if($text =~ /^ready$/i && defined($qglobals{htalisman_have})) {
  	$client->Message(13, "Choose Your Quest Reward - BE CAREFULL");
  	$client->Message(2, "--------------------------------------");
  	$client->Message(15, "[$Choose_Hammer_of_the_Fallen]");
  	$client->Message(15, "[$Choose_Dwarvenbound_Mask]");
  	$client->Message(15, "[$Choose_Time_Lost_Coldain_Wand]");
  }
  
   if($text =~ /^Choose Hammer of the Fallen$/i && defined($qglobals{htalisman_have})) {
    $client->Message(15, "You Have Recieved [$Hammer_of_the_Fallen]!");
  	quest::summonitem(2685);
		quest::delglobal("htalisman_have"); undef($qglobals{htalisman_have});
  }
  
   if($text =~ /^Choose Dwarvenbound Mask$/i && defined($qglobals{htalisman_have})) {
    $client->Message(15, "You Have Recieved [$Dwarvenbound_Mask]!");
  	quest::summonitem(2686);
		quest::delglobal("htalisman_have"); undef($qglobals{htalisman_have});
  }
  
     if($text =~ /^Choose Time-Lost Coldain Wand$/i && defined($qglobals{htalisman_have})) {
    $client->Message(15, "You Have Recieved [$Time_Lost_Coldain_Wand]!");
  	quest::summonitem(2687);
		quest::delglobal("htalisman_have"); undef($qglobals{htalisman_have});
  }
  
}
  
  sub EVENT_ITEM {
  	
my $Ready = quest::saylink("Ready");
my $Hammer_of_the_Fallen = quest::saylink("Hammer of the Fallen");
my $Dwarvenbound_Mask = quest::saylink("Dwarvenbound Mask");
my $Time_Lost_Coldain_Wand = quest::saylink("Time-Lost Coldain Wand");
  	
  if (($itemcount{2431} == 1)) {
     $client->Message(2, "You have found it! The same claw that took my friend in one fell swoop! Here are some items to choose from to compensate for your efforts!");
     $client->Message(13, "Let Me Know When You Are [$Ready] To Choose!!!");
    quest::setglobal("htalisman_have", 0, 1, "F");
     $client->Message(15, "Quest Reward Links"); 
     $client->Message(4, "------------------------"); 
     $client->Message(5, "[$Hammer_of_the_Fallen]"); 
     $client->Message(5, "[$Dwarvenbound_Mask]");
     $client->Message(5, "[$Time_Lost_Coldain_Wand]");
  } 
  
}
Btw on the new Icelance 2.0 Server im deving - I use a combination of client-> message and saylinks to keep my quests good looking, easy to manuver, and spam-free
Reply With Quote