PDA

View Full Version : First Quest. Please be gentle.


skorch
05-10-2004, 07:51 AM
This is my first quest I have written up. It is the plate portion of the elemental armor quest (http://everquest.allakhazam.com/db/quest.html?quest=2267) from the Plane of Tranquility. I do not know the ID of the mob, but I believe everything else is correct.

If someone could please point out any errors I made or if you have suggestions to make the quest better please dont heisatate to tell me.


sub EVENT_SAY {
if($text=~/Hail/i){
quest::say("'Greetin's t'ye #name! Isn't the area 'round 'ere so nice an' quiet?
Such a departure from me old days; slaving o'er the forge t'create masterpieces! T'be 'onest, at times I do miss the old forge, but after I created me finest breastplate, it seemed as if nothing else I made could ever live up t'it. So I left me home to'wander the land an' see what I could learn o'the world. I 'ave learned quite a bit from the elders 'ere an' the skilled craftspeople in New Tanaan. I 'ave even devised a type o'emblem that will impart the magic o'tranquility into the user t'create planar armors from pieces o'energy found in the planes.'"); }

if($text=~/'what emblem/i{
quest::say("'Well, the emblems dinnae be easy t'craft but I will gladly give ye one fer the price of 500 platinum pieces. They allow a planes traveler with no craftin' skills t'create many fine pieces o'planar armor in a special, magical kit I also 'ave an' will throw in with the price. The kit acts as a focal point fer the wild magic energy o'the Planes. Ye will only be able t'use each emblem an' kit once when ye create the piece, 'owever I dinnae be goin' anywhere soon! Just venture back when ye need another an' dinnae ferget the coin!"); }

if($text=~/'what plate/i{
quest::say("'Ahhhhh Radric! The fine rigid armor that can stop a shaft from piercing yer heart! Too bad it be so cumbersome an' difficult t'move about in. To construct a piece o'plate armor, ye need t'combine a plate mold, an emblem, various amounts o'sheet metal an' use one o'those crafty Tanaan smithin' 'ammers all within a furnace touched by Ro. Ethereal metal sheet construction is another matter. Ye will need t'combine two bricks o'ethereal energy, an ethereal temper an' a Tanaan smithin' 'ammer within a Tanaan forge. I would seek a skilled craftsperson t'make the metal sheets fer ye; the emblem will enable ye t'craft the final armor piece no matter what yer skill be. "); }
}

sub EVENT_ITEM{
if($platinum == 500){
quest::summonitem("17184");
if($class == BARD){
quest::summonitem("16268"); }
if($class == WARRIOR)
quest::summonitem("16267"); }
if($class == PALADIN)
quest::summonitem("16269"); }
if($class == SHADOWKNIGHT)
quest::summonitem("16270"); }
if($class == CLERIC)
quest::summonitem("16271"); }
}
}

#END of FILE Zone:potranquility ID:???? -- Bor Wharhammer


Edit: After posting this I realized that Bor Wharhammer takes care of all the elmental armors. So I guess I have to go through and add more to the quest. But before I do that. I would like to know if the class check is correct.

cofruben
05-10-2004, 08:38 AM
sub EVENT_SAY {
if($text=~/Hail/i){
quest::say("'Greetin's t'ye #name! Isn't the area 'round 'ere so nice an' quiet?
Such a departure from me old days; slaving o'er the forge t'create masterpieces! T'be 'onest, at times I do miss the old forge, but after I created me finest breastplate, it seemed as if nothing else I made could ever live up t'it. So I left me home to'wander the land an' see what I could learn o'the world. I 'ave learned quite a bit from the elders 'ere an' the skilled craftspeople in New Tanaan. I 'ave even devised a type o'emblem that will impart the magic o'tranquility into the user t'create planar armors from pieces o'energy found in the planes.'"); }

if($text=~/'what emblem/i){
quest::say("'Well, the emblems dinnae be easy t'craft but I will gladly give ye one fer the price of 500 platinum pieces. They allow a planes traveler with no craftin' skills t'create many fine pieces o'planar armor in a special, magical kit I also 'ave an' will throw in with the price. The kit acts as a focal point fer the wild magic energy o'the Planes. Ye will only be able t'use each emblem an' kit once when ye create the piece, 'owever I dinnae be goin' anywhere soon! Just venture back when ye need another an' dinnae ferget the coin!"); }

if($text=~/'what plate/i){
quest::say("'Ahhhhh Radric! The fine rigid armor that can stop a shaft from piercing yer heart! Too bad it be so cumbersome an' difficult t'move about in. To construct a piece o'plate armor, ye need t'combine a plate mold, an emblem, various amounts o'sheet metal an' use one o'those crafty Tanaan smithin' 'ammers all within a furnace touched by Ro. Ethereal metal sheet construction is another matter. Ye will need t'combine two bricks o'ethereal energy, an ethereal temper an' a Tanaan smithin' 'ammer within a Tanaan forge. I would seek a skilled craftsperson t'make the metal sheets fer ye; the emblem will enable ye t'craft the final armor piece no matter what yer skill be. "); }
}

you forgot to add last ')' for conditionals.Also check the item event,I dont think that something like if($class==CLERIC) can be done.Check syntax :)

skorch
05-10-2004, 09:48 AM
Really? I thought I had read somewhere you could. Hmm may have to come up with something new then. Is there anyway possiable that you can do class checks?

smogo
05-10-2004, 10:31 AM
you can check the $class :

if($class eq "Cleric"){ quest::foo();}

Class string is provided by EQEMu internal naming of classes. See code for details.

variables (mostly up to date) there (http://quests.eqemulator.net/cgi-bin/variables.cgi)

Yeormom
05-25-2004, 04:31 PM
if($class eq "Cleric"){ quest::foo();}


How would you do an if statement where it does not equal cleric then since your using eq as the operator?

m0oni9
05-25-2004, 05:21 PM
How would you do an if statement where it does not equal cleric then since your using eq as the operator?

Probably something like:
unless ($class eq 'Cleric') { quest::foo();}
or
if (!($class eq 'Cleric') { quest::foo(); }

Rogean
05-25-2004, 10:35 PM
if ($Class == "Cleric"){ quest::say("High"); }

or..

if ($Class != "Cleric"){ quest::say("Not a Cleric! GO AWAY!"); }

Charmy
05-31-2004, 05:36 PM
#name needs to be $name. don't think #name registers in the perl system as a variable, # is used to comment out sections. and although it is inside quotes, i think when this is run you will see


'Greetin's t'ye #name! Isn't the area 'round 'ere so nice an' quiet?
Such a departure from me old days; slaving o'er the forge t'create masterpieces! T'be 'onest, at times I do miss the old forge, but after I created me finest breastplate, it seemed as if nothing else I made could ever live up t'it. So I left me home to'wander the land an' see what I could learn o'the world. I 'ave learned quite a bit from the elders 'ere an' the skilled craftspeople in New Tanaan. I 'ave even devised a type o'emblem that will impart the magic o'tranquility into the user t'create planar armors from pieces o'energy found in the planes.


instead of seeing

'Greetin's t'ye Joe! Isn't the area 'round 'ere so nice an' quiet?
Such a departure from me old days; slaving o'er the forge t'create masterpieces! T'be 'onest, at times I do miss the old forge, but after I created me finest breastplate, it seemed as if nothing else I made could ever live up t'it. So I left me home to'wander the land an' see what I could learn o'the world. I 'ave learned quite a bit from the elders 'ere an' the skilled craftspeople in New Tanaan. I 'ave even devised a type o'emblem that will impart the magic o'tranquility into the user t'create planar armors from pieces o'energy found in the planes



sub EVENT_ITEM{
if($platinum == 500){
quest::summonitem("17184");
if($class == BARD){
quest::summonitem("16268"); }
if($class == WARRIOR)
quest::summonitem("16267"); }
if($class == PALADIN)
quest::summonitem("16269"); }
if($class == SHADOWKNIGHT)
quest::summonitem("16270"); }
if($class == CLERIC)
quest::summonitem("16271"); }


changing the classes as said above.


if($class eq "Cleric")
{
quest::summonitem(16271,0);
}


don't need quotes when summoning items just need (ItemID,Charges) charges can also be number of items if they stack.

also $platinum is not defined you need to define it at the begging of your sub EVENT_ITEM. e.g.


sub EVENT_ITEM
{
$myplatnium = $platinum
<events>
}


just the same you could replace all the $platinum with $myplatinum =P.
so lets re write the EVENT_ITEM sub.


sub EVENT_ITEM
{
$myplatinum = $platinum;
if($platinum == 500)
{
if($class eq "Bard")
{
quest::summonitem(17184,0);
}
elsif($class eq "Warrior")
{
quest::summonitem(16268,0);
}
elsif($class eq "Paladin")
{
quest::summonitem(16296,0);
}
}
}


Just continue on with the elsif($class eq "Class") etc....


if i missed anything sorry i am tired. good luck with the script.