View Single Post
  #12  
Old 02-25-2022, 11:14 AM
deanalee
Fire Beetle
 
Join Date: Feb 2022
Posts: 1
Default

I know it could be tweaked better by an expert, but this works.

Just change the ids to the range of items you want for the zone.

My default.pl from the zone warrens that drops crude defiant weapons and armor.

Its a modified version from this link.

Code:
http://www.eqemulator.org/forums/showthread.php?t=38286
Code:
sub EVENT_SPAWN {
  $roll = int(rand(100)) + 1;
  
  $roll_chance = $roll - 70;
  $roll2_chance = $roll - 85;
  $WPlower_limit = 50500;
  $WPupper_limit = 50519;
  $ARlower_limit = 50005;
  $ARupper_limit = 50033;
	
  if($roll >= 85)
  {
       my $itemid = int(rand($WPupper_limit-$WPlower_limit)) + $WPlower_limit;
		#quest::shout("I rolled a $roll have an extra item at $roll_chance percent. Number 1 statement");
        $npc->AddItem($itemid);
		if($roll >= 75 && $mlevel >= 15)
		{
		my $itemid2 = int(rand($ARupper_limit-$ARlower_limit)) + $ARlower_limit;
		#quest::shout("I have rolled higher than 85 an extra item at $roll2_chance percent chance. Number 2 statement");
		$npc->AddItem($itemid2);
		}
	}
	
}
__________________
AMC Lighting and Decor Inc.
Reply With Quote