PDA

View Full Version : EQEmu Quest TEMPLATE


mwmdragon
05-10-2005, 04:47 PM
Just copy and paste this into your favorite text editor and you off to the races making quests. This is the template I am using for the countless quests I have done with the PEQ Team.



############################################
# ZONE: zonename (zoneshortname)
# DATABASE: PEQ-Velious
# LAST EDIT DATE: May 1,2005
# VERSION: 1.0
# BASE QUEST BY: PEQ Team
# DEVELOPER: yourname
#
# *** NPC INFORMATION ***
#
# NAME:
# ID:
# TYPE:
# RACE:
# LEVEL:
#
# *** ITEMS GIVEN OR TAKEN ***
#
# itemname ID- itemid
#
# *** QUESTS INVOLVED IN ***
#
#1 - questname
#2 - questname
#3 - questname
#
# *** QUESTS AVAILABLE TO ***
#
#1 - classes_that_can_do_the_quest
#2 - classes_that_can_do_the_quest
#3 - classes_that_can_do_the_quest
#
# *** NPC NOTES ***
#
#
#
############################################

######## EVENT_SAY AREA ####################
### Called when the NPC is spoken to by a PC

sub EVENT_SAY
{
if($text=~/Hail/i)
{
quest::say("Hail");
}
}

######## EVENT_ITEM AREA ###################
### Called when the NPC is handed items

sub EVENT_ITEM
{

# itemname ID- itemid
if($itemcount{0000} == 1)
{
quest::ding();
quest::say("Thanks");
quest::exp("0");
quest::givecash("0","0","0","0");

### Random Item choosing if needed
# $random=int(rand itemid+itemid+itemid);
# quest::summonitem($randon);

# itemname ID- itemid
quest::summonitem("0000");

# factionname Faction ID - factionid
quest::faction("0","1");
}
}

######## EVENT_AGGRO AREA ##################
### Called when the NPC is aggroed

sub EVENT_AGGRO
{



}

######## EVENT_ATTACK AREA #################
### Called when the NPC is Attacked

sub EVENT_ATTACK
{



}

######## EVENT_DEATH AREA ##################
### Called when the NPC is killed

sub EVENT_DEATH
{



}

######## EVENT_ENTER AREA ##################
### Called when a PC enters the NPCs Proximity

sub EVENT_ENTER
{



}

######## EVENT_EXIT AREA ###################
### Called when a PC exits the NPCs Proximity

sub EVENT_EXIT
{



}

######## EVENT_HP AREA #####################
### Called when the HP of the NPC drop below a set level

sub EVENT_HP
{



}

######## EVENT_SIGNAL AREA #################
### Called when a signal is sent to the NPC

sub EVENT_SIGNAL
{



}

######## EVENT_SLAY AREA ###################
### Called when the NPC kills someone

sub EVENT_SLAY
{



}

######## EVENT_SPAWN AREA ##################
### Called when the NPC spawns

sub EVENT_SPAWN
{



}

######## EVENT_TIMER AREA ##################
### Called when a timer has completed its cycle

sub EVENT_TIMER
{



}

######## EVENT_WAYPOINT AREA ###############
### Called when the NPC reaches a waypoint

sub EVENT_WAYPOINT
{



}

### EQEmu Quest Template By: MWMDRAGON
### The End of this script must contain 2 empty lines for the EQ Quest System
#END of FILE Zone:shortzonename ID:npcid -- npcname

Ghost Fire
05-10-2005, 11:41 PM
Nice template :D I think I might be using this now ;) wink wink.

mwmdragon
05-11-2005, 03:37 AM
I'm working on a program that will make quest writing 1 million time easier. Not sure of the ETA but i'm working on it now.

Enjoy the template ;)

Cisyouc
05-12-2005, 06:08 AM
### The End of this script must contain 2 empty lines for the EQ Quest System Since when?

mwmdragon
05-12-2005, 04:35 PM
Try it out. Delete everything under the last line and when you compile and it will have an error when loading the script saying something like

Blahblahblah.pl is missing a square bracket or curly bracket near EOF, switching to default.pl


When I added some space to the end of the scripts they compiled perfectly in EQEmu.

There was nothing wrong with the script as it compile in PerlIDE. I added some spaces and it worked great.

phasepuma
05-13-2005, 04:05 AM
OMFG now I find out.

mystic414
05-13-2005, 07:49 AM
yeah, i had that problem too, but never did figure out what was causing it.. maybe submit that in the bugs forum so someone can take a look at it?

solid11
05-13-2005, 08:36 AM
Wow so that was the problem. When I copied your quests from the forums it didn't add the extra lines when I pasted them, and I kept getting those errors. I just deleted the very last line, with zone and mob info, and it worked. Maybe I'll recopy them again when I get a chance.

mwmdragon
05-13-2005, 05:43 PM
Glad I could help. It took me a while to figure it out :)