Go Back   EQEmulator Home > EQEmulator Forums > Quests > Quests::Submissions

Quests::Submissions This is where you submit your quests for review

Reply
 
Thread Tools Display Modes
  #1  
Old 07-18-2006, 01:43 AM
Angelox
AX Classic Developer
 
Join Date: May 2006
Location: filler
Posts: 2,049
Default Nadox instant respawn solution

Here's an effective solution to my "instant respawn" dilemma in the LoY zone, Nadox;

Code:
# Captain_Krakskull's instant respawn on a sanctum sentinel death - list favors another sanctum sentinel
# 88% of the time
# note: the only random number that means anything, is the last one; 227097
# Angelox

sub EVENT_DEATH
{
 my $a = quest::ChooseRandom(227031,227031,227031,227031,227035,227035,227035,227097);
 my $x = $npc->GetX();
 my $y = $npc->GetY();
 my $z = $npc->GetZ(); 
 my $h = $npc->GetHeading();
 if ($a =~ /227097/)
  {
  quest::say("Surprise! Time to die, fool!");
  quest::spawn2($a,0,0,$x,$y,$z,$h);
  }
 else
  {
  quest::say("Lord Nadox will avenge me!");
  }
}

# EOF zone: nadox
The quest::say text added in there does not follow live ( I can't remember what the original was) - they are there to verify the script is working.
This script can be renamed and fixed for all the "spawn on death" mobs in Nadox which are many.
Reply With Quote
  #2  
Old 07-22-2006, 05:53 AM
Angelox
AX Classic Developer
 
Join Date: May 2006
Location: filler
Posts: 2,049
Default

here's a little "fix" to these Pl's;

This eliminates the quest::ChooseRandom numbers that don't really exist, and might be a little more accurate-

Code:
# respawn random mob on a sanctum sentinel death - list favors another sanctum sentinel
# 90% of the time

sub EVENT_DEATH
{
 my $random_result = int(rand(100));
 my $x = $npc->GetX();
 my $y = $npc->GetY();
 my $z = $npc->GetZ(); 
 my $h = $npc->GetHeading();
 my $a = 227097;
 if ($random_result<=10)
  {
  quest::say("Surprise! Time to die, fool!");
  quest::spawn2($a,0,0,$x,$y,$z,$h);
  }
 else
  {
  quest::say("Lord Nadox will avenge me!");
  }
}

# EOF zone: nadox NPC: a_sanctum_sentinel, Captain_Krakskull
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 01:36 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 - 2024, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3