Go Back   EQEmulator Home > EQEmulator Forums > Quests > Quests::Plugins & Mods

Quests::Plugins & Mods Completed plugins for public use as well as modifications.

Reply
 
Thread Tools Display Modes
  #1  
Old 08-26-2014, 09:34 PM
Asylum
Sarnak
 
Join Date: Jun 2013
Posts: 81
Default New plugins and scripts, feel free to use/share/modify.

New plugins:

check_hasitemonhead.pl (plugins folder):
Code:
#checks to see if player has item on head only
#usage plugin::check_hasitemonhead($client, itemid);

sub check_hasitemonhead {
    my $client = shift;
    my $itmchk = shift;
    my $slot1;
    my $itemid1;

#Check head
    for($slot1=2) {
        $itemid1=$client->GetItemIDAt($slot1);
        if($itemid1==$itmchk) {
            return 1;
        }
    }
  return 0;
}

1;
check_hasitemoncursor.pl (plugins folder):
Code:
#checks to see if player has item on cursor only
#usege plugin::check_hasitemoncursor($client, itemid);

sub check_hasitemoncursor {
    my $client = shift;
    my $itmchk = shift;
    my $slot1;
    my $itemid1;

#Check cursor
    for($slot1=30) {
        $itemid1=$client->GetItemIDAt($slot1);
        if($itemid1==$itmchk) {
            return 1;
        }
    }
  return 0;
}

1;
New scripts:

Treasure_Goblin.pl (placed in quests\global) "Think Diablo3 goblins"
Code:
#Treasure Goblin NPCIDs: *1380-1385
#For 1% chance to spawn a Treasure Goblin, place the following lines (without #) in triggering_npc.pl file and place this file in same zone quest folder
#The NPCID 1380 can be replaced with 1380-1385 for appropriate level (see below).

#####
#sub EVENT_DEATH_COMPLETE {
#	$roll = int(rand(100));
#	if($roll >= 99) {
#		quest::spawn2(1380,0,0,$x,$y,$z,$h);
#	}
#}
#####

sub EVENT_SPAWN {
	$npc->SetAppearance(4);
	$roll = int(rand(100)) + 1;
	quest::emote("appears from a golden portal and begins searching the corpse for valuables.");
	if($roll >= 90) {
		quest::npcfeature("size", 120); #set size to gigantic(for a goblin) if $roll is >=90
	}
}

sub EVENT_AGGRO {
	$npc->SetAppearance(0);
	quest::settimer("despawn",180); #180 sec timer for despawn
}

sub EVENT_TIMER {
	if($timer eq "despawn") {
		quest::emote("conjures a dark portal and disappears into it.");
		quest::depop();
	}
}
sub EVENT_DEATH_COMPLETE {
    #quest::say("I die."); #for testing purposes
	if($roll >= 90) {
		$client->Message(15, "You have been granted a temporary surname!");
		$client->ReadBook("Volume IX of 'How to Hurt a Goblin's Feelings: You Stole My Stuff!'  

Stacker`Salvanna`Trelous`Flyingwolf`Junebugg`Pureangel`Brudal`Chirrok`Treehugrdill`Xtad`Norakor`
$name the Covetous`
-- Norrathian Federation of Treasure Goblins", 1);
		quest::surname(the_Covetous); #changes player surname to "the Covetous"
	}
}
Chrysopeleia.pl (PoK): "pay attention to line 50: quest::movepc(78,937,565,178,96);"

Code:
sub EVENT_SAY
{
 if ($text =~/Hail/i)
 {
quest::say ("Hello, $name.  Come, shade yourself below my branches.  What brings you to my place of residence in this plane of enlightenment?");
 }
 if ($text =~/weapon/i)
 {
quest::say ("A weapon of great power you say?  Only those adventurers of extraordinary [skill] shall possess such weapons.");
 }
 if ($text =~/skill/i)
 {
quest::say ("A test of skill awaits you $class.  I can [send] you to your fate if you can prove your worth.");
 }
 if ($text =~/send/i)
 {
quest::say ("If you are a properly prepared and seasoned $class, to your fate you shall go.  Prove your worthiness by showing to me a weapon befitting a true $class.");
 }
 if ($text =~/knowledge/i)
 {
quest::say ("A deep understanding is required to create your weapon, $name the $race.  [Portions] of twelve godly beings are needed along with their [blessings].");
 }
 if ($text =~/portions/i)
 {
quest::say ("Norrath's gods of influence have unimaginable power but sometimes they are willing to part with tiny portions of it, imparting demigod status on deserving individuals, or imbuing it into objects such as statues constructed in their image.  Rumors abound of twelve living statues, originally made of stone by devout worshippers but now animated by the gods they honor.");
 }
 if ($text =~/blessings/i)
 {
quest::say ("The god's power that resides in an imbued object is inaccessable to mortals without that god's blessing.  Perhaps this could be obtained at an ancient temple or shrine.  Be warned, some worshippers are not fond of outsiders using their sacred worship [sites].");
 }
 if ($text =~/sites/i)
 {
quest::say ("Thirty such sites were known to exist when I was but a shrub... er, young fairy.  Only two sites remain intact: one with silver runes and one with gold runes.  Place all twelve blessed statues in the appropriate cases, seal them, and return both to me.");
quest::summonitem(6308); #combine 6 blessed statues (each made by turning in a statue to a shrine to get blessed statue) in this box for item 6314.
 }
}

######## Begin Common Ending for Epic 0.5 Weapon Quest, required level 30 ########

my %weapon = ("Warrior" => 7007, "Rogue" => 0, "Monk" => 0, "Berserker" => 0, "Shadowknight" => 0, "Paladin" => 0, "Ranger" => 7007, "Bard" => 0, "Beastlord" => 0, "Cleric" => 0, "Druid" => 0, "Shaman" => 0, "Wizard" => 0, "Magician" => 0, "Enchanter" => 0, "Necromancer" => 0);
my %weapon3 = ("Warrior" => 7008, "Rogue" => 0, "Monk" => 0, "Berserker" => 0, "Shadowknight" => 0, "Paladin" => 0, "Ranger" => 7008, "Bard" => 0, "Beastlord" => 0, "Cleric" => 0, "Druid" => 0, "Shaman" => 0, "Wizard" => 0, "Magician" => 0, "Enchanter" => 0, "Necromancer" => 0);
my %epic = ("Warrior" => 4694, "Rogue" => 0, "Monk" => 0, "Berserker" => 0, "Shadowknight" => 0, "Paladin" => 0, "Ranger" => 7762, "Bard" => 0, "Beastlord" => 0, "Cleric" => 0, "Druid" => 0, "Shaman" => 0, "Wizard" => 0, "Magician" => 0, "Enchanter" => 0, "Necromancer" => 0);

sub EVENT_ITEM {
if ($class eq 'Warrior' || $class eq 'Rogue' || $class eq 'Monk' || $class eq 'Berserker' || $class eq 'Shadowkight' || $class eq 'Paladin' || $class eq 'Ranger' || $class eq 'Bard' || $class eq 'Beastlord' || $class eq 'Cleric' || $class eq 'Druid' || $class eq 'Shaman' || $class eq 'Wizard' || $class eq 'Magician' || $class eq 'Enchanter' || $class eq 'Necromancer') {
	if (plugin::check_handin(\%itemcount, ($weapon{$class}) => 1)) {
		  quest::summonitem($weapon{$class}); #returns the weapon in case of failure at the next event (fight future self).
          quest::emote("whispers into the weapon a phrase you cannot make out and your world fades to black.");
		  $client->Message(15, "The world stretches and twists around you as you feel yourself being pulled from reality.");
		  quest::movepc(78,937,565,178,96); #moves player to top of Kurn's Tower in fieldofbone, normally inaccessable area.
	}
	if (plugin::check_handin(\%itemcount, ($weapon3{$class}) => 1)) {
          quest::doanim(43);
          quest::emote("moves to inspect the new weapon and you hear several branches of the nearby tree groan.");
          quest::say("Your [knowledge] grows, $name.");
          quest::exp(1000);
		  quest::summonitem(6279); #combine 6 blessed statues (each made by turning in a statue to a shrine to get blessed statue) in this box for item 6280.
	}
	if (plugin::check_handin(\%itemcount, (6280) => 1, (6314) => 1)) {
          quest::doanim(43);
          quest::emote("'s wings begin to flutter and her eyes glow a brilliant green as the leaves on the tree behind her rustle in the absence of any wind.");
          quest::emote("opens the cases and deftly merges the statues with the weapon in a glowing metallic aura, within which you can faintly hear the voices of the gods.");
          quest::say("One last step remains.  The weapon needs to be cured in the fires controlled by an infamous efreeti.  Bring it to him and he shall return to you a shard of the pantheon.");
          quest::say("It is beyond our understanding why the gods have permitted a portion of their power to reside in this weapon.  It is less understood why they have chosen $name to wield it.  Use it wisely, $race.");
		  quest::ding();
          quest::exp(1000);
          quest::summonitem($epic{$class});
	}
	else  {
 	    quest::say ("This is not of the appropriate material, perhaps you should seek another.");
		plugin::return_items(\%itemcount);
	}
 }
}
Temporal_Reflection.pl (fieldofbone):
Code:
sub EVENT_SAY {
if($text=~/Hail/i && $ulevel > 29) {
 if ($class eq 'Warrior' || $class eq 'Rogue' || $class eq 'Monk' || $class eq 'Berserker' || $class eq 'Shadowkight' || $class eq 'Paladin' || $class eq 'Ranger' || $class eq 'Bard' || $class eq 'Beastlord' || $class eq 'Cleric' || $class eq 'Druid' || $class eq 'Shaman' || $class eq 'Wizard' || $class eq 'Magician' || $class eq 'Enchanter' || $class eq 'Necromancer') {
	$client->Message(15, "A [challenge] of the body and mind awaits you, $name.  Through the time-transcending power of Luclin I see what you are to become and the power you are to wield is impressive.  You must conquer your own future to continue on this quest.");
	quest::emote("transforms into a future version of yourself.");
####make npc look like player
		$GotRace = $client->GetRace();
		quest::npcfeature("race", $GotRace);
		$GotGender = $client->GetGender();
		quest::npcfeature("gender", $GotGender);
		$GotTexture = $client->GetTexture();
		quest::npcfeature("texture", $GotTexture);
		$GotHelmTexture = $client->GetHelmTexture();
		quest::npcfeature("helm", $GotHelmTexture);
		$GotHairColor = $client->GetHairColor();
		quest::npcfeature("haircolor", $GotHairColor);
		$GotBeardColor = $client->GetBeardColor();
		quest::npcfeature("beardcolor", $GotBeardColor);
		$GotEyeColor1 = $client->GetEyeColor1();
		quest::npcfeature("eyecolor1", $GotEyeColor1);
		$GotEyeColor2 = $client->GetEyeColor2();
		quest::npcfeature("eyecolor2", $GotEyeColor2);
		$GotHairStyle = $client->GetHairStyle();
		quest::npcfeature("hair", $GotHairStyle);
		$GotLuclinFace = $client->GetLuclinFace();
		quest::npcfeature("face", $GotLuclinFace);
		$GotBeard = $client->GetBeard();
		quest::npcfeature("beard", $GotBeard);
		$GotDrakkinHeritage = $client->GetDrakkinHeritage();
		quest::npcfeature("heritage", $GotDrakkinHeritage);
		$GotDrakkinTattoo = $client->GetDrakkinTattoo();
		quest::npcfeature("tattoo", $GotDrakkinTattoo);
		$GotDrakkinDetails = $client->GetDrakkinDetails();
		quest::npcfeature("details", $GotDrakkinDetails);
		$GotSize = $client->GetSize() * 10;
		quest::npcfeature("size", $GotSize);
####make npc look like player
	}
 }
 elsif($text=~/Hail/i && $ulevel <= 29) {
    $client->Message(13, "The voice booms angrily in your mind.  Be gone from this place.  You waste my time!");
 }
 elsif($text=~/challenge/i && $ulevel > 29) {
	quest::say("It is strange looking upon myself, $name.  You are as I once was, and the gods compel me to test you.");
    quest::attack($name);
 }
 else {
	return 0;
 }
}

sub EVENT_DEATH_COMPLETE {
 if ($ulevel > 29) {
	my %weapon3 = ("Warrior" => 0, "Rogue" => 0, "Monk" => 0, "Berserker" => 0, "Shadowknight" => 0, "Paladin" => 0, "Ranger" => 7008, "Bard" => 0, "Beastlord" => 0, "Cleric" => 0, "Druid" => 0, "Shaman" => 0, "Wizard" => 0, "Magician" => 0, "Enchanter" => 0, "Necromancer" => 0);
	quest::summonitem($weapon3{$class});
	quest::movepc(202,-170,455,-157,128);
 }
}
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 06:25 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