|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Quests::Custom Custom Quests here |
|
|
|
02-05-2008, 01:09 AM
|
|
Developer
|
|
Join Date: Aug 2006
Location: USA
Posts: 5,946
|
|
Armor Upgrade Quest from Elemental Set to GoD Set for all Classes
Code:
my %chest = ("Warrior" => 47642, "Rogue" => 47648, "Monk" => 47650, "Berserker" => 55511, "Shadowknight" => 47645, "Paladin" => 47644, "Ranger" => 47647, "Bard" => 47643, "Beastlord" => 47652, "Cleric" => 47646, "Druid" => 47651, "Shaman" => 47649, "Wizard" => 47654, "Magician" => 47655, "Enchanter" => 47656, "Necromancer" => 47653);
my %legs = ("Warrior" => 16693, "Rogue" => 16717, "Monk" => 16727, "Berserker" => 55512, "Shadowknight" => 16763, "Paladin" => 16757, "Ranger" => 16777, "Bard" => 16771, "Beastlord" => 16787, "Cleric" => 16797, "Druid" => 16811, "Shaman" => 16803, "Wizard" => 19027, "Magician" => 19021, "Enchanter" => 16931, "Necromancer" => 19024);
my %bracer = ("Warrior" => 11138, "Rogue" => 11141, "Monk" => 11146, "Berserker" => 55510, "Shadowknight" => 11173, "Paladin" => 11163, "Ranger" => 11193, "Bard" => 11178, "Beastlord" => 11196, "Cleric" => 11199, "Druid" => 11281, "Shaman" => 11278, "Wizard" => 11309, "Magician" => 11303, "Enchanter" => 11298, "Necromancer" => 11306);
my %helm = ("Warrior" => 9629, "Rogue" => 9806, "Monk" => 9809, "Berserker" => 55513, "Shadowknight" => 9815, "Paladin" => 9812, "Ranger" => 9821, "Bard" => 9818, "Beastlord" => 9824, "Cleric" => 9827, "Druid" => 9833, "Shaman" => 9830, "Wizard" => 9950, "Magician" => 9944, "Enchanter" => 9836, "Necromancer" => 9947);
my %arms = ("Warrior" => 11429, "Rogue" => 11432, "Monk" => 11435, "Berserker" => 55508, "Shadowknight" => 11441, "Paladin" => 11438, "Ranger" => 11447, "Bard" => 11444, "Beastlord" => 11450, "Cleric" => 32012, "Druid" => 11575, "Shaman" => 11529, "Wizard" => 11876, "Magician" => 11598, "Enchanter" => 11578, "Necromancer" => 11618);
my %gloves = ("Warrior" => 12595, "Rogue" => 12598, "Monk" => 12624, "Berserker" => 55514, "Shadowknight" => 12637, "Paladin" => 12627, "Ranger" => 12816, "Bard" => 12664, "Beastlord" => 13553, "Cleric" => 13563, "Druid" => 13603, "Shaman" => 13579, "Wizard" => 13627, "Magician" => 13619, "Enchanter" => 13614, "Necromancer" => 13623);
my %boots = ("Warrior" => 19440, "Rogue" => 19443, "Monk" => 19446, "Berserker" => 55509, "Shadowknight" => 19546, "Paladin" => 19449, "Ranger" => 19838, "Bard" => 19549, "Beastlord" => 20032, "Cleric" => 20074, "Druid" => 20422, "Shaman" => 20078, "Wizard" => 20434, "Magician" => 20428, "Enchanter" => 20425, "Necromancer" => 20431);
my %upgrade = ("Warrior" => 1807, "Shadowknight" => 1807, "Paladin" => 1807, "Bard" => 1807, "Cleric" => 1807, "Rogue" => 1809, "Berserker" => 1809, "Ranger" => 1809, "Shaman" => 1809, "Monk" => 1811, "Beastlord" => 1811, "Druid" => 1811, "Wizard" => 1813, "Magician" => 1813, "Enchanter" => 1813, "Necromancer" => 1813);
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 'Mage' || $class eq 'Enchanter' || $class eq 'Necromancer') {
if(defined($helm{$class}),($upgrade{$class})) {
if (plugin::check_handin(\%itemcount, ($upgrade{$class}) => 1, ($helm{$class}) => 1)) {
my %rewards = (
"Warrior" => 68850, "Rogue" => 68875, "Monk" => 68895, "Berserker" => 68890, "Shadowknight" => 68865, "Paladin" => 68860, "Ranger" => 68880, "Bard" => 68870, "Beastlord" => 68905, "Cleric" => 68855, "Druid" => 68900, "Shaman" => 68885, "Wizard" => 68910, "Mage" => 68915, "Enchanter" => 68925, "Necromancer" => 68920
);
if(defined($rewards{$class})) {
quest::emote("grips your armor in his claws and replaces the old parts with the new material" );
quest::say("Ahh, $name, here is your upgraded armor piece!");
quest::exp(45000);
quest::summonitem($rewards{$class});
}
}
}
if(defined($arms{$class}),($upgrade{$class})) {
if (plugin::check_handin(\%itemcount, ($upgrade{$class}) => 1, ($arms{$class}) => 1)) {
my %rewards = (
"Warrior" => 68851, "Rogue" => 68876, "Monk" => 68896, "Berserker" => 68891, "Shadowknight" => 68866, "Paladin" => 68861, "Ranger" => 68881, "Bard" => 68871, "Beastlord" => 68906, "Cleric" => 68856, "Druid" => 68901, "Shaman" => 68886, "Wizard" => 68911, "Mage" => 68916, "Enchanter" => 68926, "Necromancer" => 68921
);
if(defined($rewards{$class})) {
quest::emote("grips your armor in his claws and replaces the old parts with the new material" );
quest::say("Ahh, $name, here is your upgraded armor piece!");
quest::exp(45000);
quest::summonitem($rewards{$class});
}
}
}
if(defined($gloves{$class}),($upgrade{$class})) {
if (plugin::check_handin(\%itemcount, ($upgrade{$class}) => 1, ($gloves{$class}) => 1)) {
my %rewards = (
"Warrior" => 68852, "Rogue" => 68877, "Monk" => 68897, "Berserker" => 68892, "Shadowknight" => 68867, "Paladin" => 68862, "Ranger" => 68882, "Bard" => 68872, "Beastlord" => 68907, "Cleric" => 68857, "Druid" => 68902, "Shaman" => 68887, "Wizard" => 68912, "Mage" => 68917, "Enchanter" => 68927, "Necromancer" => 68922
);
if(defined($rewards{$class})) {
quest::emote("grips your armor in his claws and replaces the old parts with the new material" );
quest::say("Ahh, $name, here is your upgraded armor piece!");
quest::exp(45000);
quest::summonitem($rewards{$class});
}
}
}
if(defined($boots{$class}),($upgrade{$class})) {
if (plugin::check_handin(\%itemcount, ($upgrade{$class}) => 1, ($boots{$class}) => 1)) {
my %rewards = (
"Warrior" => 68853, "Rogue" => 68878, "Monk" => 68898, "Berserker" => 68893, "Shadowknight" => 68868, "Paladin" => 68863, "Ranger" => 68883, "Bard" => 68873, "Beastlord" => 68908, "Cleric" => 68858, "Druid" => 68903, "Shaman" => 68888, "Wizard" => 68913, "Mage" => 68918, "Enchanter" => 68928, "Necromancer" => 68923
);
if(defined($rewards{$class})) {
quest::emote("grips your armor in his claws and replaces the old parts with the new material" );
quest::say("Ahh, $name, here is your upgraded armor piece!");
quest::exp(45000);
quest::summonitem($rewards{$class});
}
}
}
if(defined($bracer{$class}),($upgrade{$class})) {
if (plugin::check_handin(\%itemcount, ($upgrade{$class}) => 1, ($bracer{$class}) => 1)) {
my %rewards = (
"Warrior" => 68854, "Rogue" => 68879, "Monk" => 68899, "Berserker" => 68894, "Shadowknight" => 68869, "Paladin" => 68864, "Ranger" => 68884, "Bard" => 68874, "Beastlord" => 68909, "Cleric" => 68859, "Druid" => 68904, "Shaman" => 68889, "Wizard" => 68914, "Mage" => 68919, "Enchanter" => 68929, "Necromancer" => 68924
);
if(defined($rewards{$class})) {
quest::emote("grips your armor in his claws and replaces the old parts with the new material" );
quest::say("Ahh, $name, here is your upgraded armor piece!");
quest::exp(45000);
quest::summonitem($rewards{$class});
}
}
}
if(defined($chest{$class}),($upgrade{$class})) {
if (plugin::check_handin(\%itemcount, ($upgrade{$class}) => 1, ($chest{$class}) => 1)) {
my %rewards = (
"Warrior" => 68960, "Rogue" => 68970, "Monk" => 68978, "Berserker" => 68976, "Shadowknight" => 68966, "Paladin" => 68964, "Ranger" => 68972, "Bard" => 68968, "Beastlord" => 68982, "Cleric" => 68962, "Druid" => 68980, "Shaman" => 68974, "Wizard" => 68984, "Mage" => 68986, "Enchanter" => 68988, "Necromancer" => 68990
);
if(defined($rewards{$class})) {
quest::emote("grips your armor in his claws and replaces the old parts with the new material" );
quest::say("Ahh, $name, here is your upgraded armor piece!");
quest::exp(45000);
quest::summonitem($rewards{$class});
}
}
}
if(defined($legs{$class}),($upgrade{$class})) {
if (plugin::check_handin(\%itemcount, ($upgrade{$class}) => 1, ($legs{$class}) => 1)) {
my %rewards = (
"Warrior" => 68961, "Rogue" => 68971, "Monk" => 68979, "Berserker" => 68977, "Shadowknight" => 68967, "Paladin" => 68965, "Ranger" => 68973, "Bard" => 68969, "Beastlord" => 68983, "Cleric" => 68963, "Druid" => 68981, "Shaman" => 68975, "Wizard" => 68985, "Mage" => 68987, "Enchanter" => 68989, "Necromancer" => 68991
);
if(defined($rewards{$class})) {
quest::emote("grips your armor in his claws and replaces the old parts with the new material" );
quest::say("Ahh, $name, here is your upgraded armor piece!");
quest::exp(45000);
quest::summonitem($rewards{$class});
}
}
else {
plugin::return_items(\%itemcount);
# quest::say ("I have no use for this item, $name.");
}
}
}
}
|
|
|
|
|
|
|
02-05-2008, 01:27 AM
|
|
Developer
|
|
Join Date: Aug 2006
Location: USA
Posts: 5,946
|
|
The first post is the beef of the quest itself, the event_item. The first part of the quest is below if you wish to use the exact one I use.
Code:
#############
#Quest Name: Elemental Set to GoD Armor Set Upgrade and Teleport to Potimeb
#Author: Trevius
#NPC's Involved: Kliz Watchoo
#Items Involved: 1807, 1809, 1811, 1813 all are custom made quest drops.
# All other item IDs are from PEQ for Elemental Armor Sets
# and GoD Armor Sets.
#############
###NPC 1
#Name: Kliz_Watchoo
#Race 469 (Newevileyemodel), Texture of 1, Size 6, gender of 2
#Location: -166.5,54,55.8 of the Nexus
#Level: 70
#Type: Quest NPC
#Loot: N/A
#############
###ItemID 1807
#Name: Magic Steel Plate Upgrade
#Stats: Magic, No drop
###
###ItemID 1809
#Name: Magic Chain Link Upgrade
#Stats: Magic, No drop
###
###ItemID 1811
#Name: Magic Leather Pattern Upgrade
#Stats: Magic, No drop
###
###ItemID 1813
#Name: Magic Cloth Linen Upgrade
#Stats: Magic, No drop
###
sub EVENT_SAY
{
if ($text =~/Hail/i)
{
quest::say ("Ahh yes, $name. Time is of the essence. I watch the seconds tick by with every waking breath I can spare. You might say it is an obsession of mine to watch things. But, time in particular fascinates me. Would you like to hear [more]?");
}
if ($text =~/more/i)
{
quest::say ("I have studied the subject of time for years and yet there is so much to learn. As of now, my research has proven that time is a dimension of it's own, which you may even call the Plane of Time. Would you like to know about the [plane]?");
}
if ($text =~/plane/i)
{
quest::say ("The plane of [time] is not for the faint of heart. It is only recommended for the most experienced of travelers. I think 70 seasons should do it. I can send you to the [time] plane now if you wish. I can also [upgrade] your armor if you gather the right materials.");
}
if ($text =~/upgrade/i)
{
quest::say ("It takes great skill and precision to upgrade armor, and no one is more precise than myself. Hand me an armor set piece from Delve along with a [material] upgrade and I will begin working.");
}
if ($text =~/material/i)
{
quest::say ("Upgrade material is no easy thing to come by. You will need to gather an Essence of Magic and a Magic Material Upgrade that suites your class type from the Plane of Time. And then combine the 2 items in a forge. Do you [understand] that?");
}
if ($text =~/understand/i)
{
quest::say ("If you want to see exactly what you are looking for, go to the forge and search the recipes for the word [upgrade] and you will see examples of what you require.");
}
{
if (($text=~/time/i)&&($ulevel >= 65))
{
quest::say ("By the second hand, may your journey begin!");
quest::emote ("swings a pocket watch before your eyes as if to hypnotize you.");
quest::movepc(223, -54,581,494);
}
elsif (($text=~/time/i)&&($ulevel <= 64))
{
quest::say ("I don't think you have what it takes to handle that place just yet. Come see me when you have gained more experience.");
}
}
}
Simply put, this is a quest for all classes to upgrade Elemental Armor to GoD armor. It has all armor pieces from both sets with accurate itemids for PEQ database.
|
|
|
|
|
|
|
02-05-2008, 09:48 PM
|
|
Developer
|
|
Join Date: Aug 2006
Location: USA
Posts: 5,946
|
|
Noticed a minor correction I needed to make to get this working properly. I had always used "==" instead of "eq", but I was getting a log message error in my server logs saying something about one of my quests having "==" instead of "eq", because the "==" is only for numbers.
Apparently, "==" isn't only for numbers and "eq" does NOT work for this quest, so you need to replace this line in the quest:
Code:
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 'Mage' || $class eq 'Enchanter' || $class eq 'Necromancer') {
with this:
Code:
if ($class == 'Warrior' || $class == 'Rogue' || $class == 'Monk' || $class == 'Berserker' || $class == 'Shadowkight' || $class == 'Paladin' || $class == 'Ranger' || $class == 'Bard' || $class == 'Beastlord' || $class == 'Cleric' || $class == 'Druid' || $class == 'Shaman' || $class == 'Wizard' || $class == 'Mage' || $class == 'Enchanter' || $class == 'Necromancer') {
And it works flawlessly!
I thought it was working perfectly when I posted the quest originally, but I had only tested it with a warrior. I guess because warrior is the first class on the list, it accepted the "eq" for that class, but any other class was getting their items eaten when they did the turn in. I changed it back to "==" and tested it again with a few classes and it is working perfect now
|
|
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -4. The time now is 04:56 AM.
|
|
|
|
|
|
|
|
|
|
|
|
|