Go Back   EQEmulator Home > EQEmulator Forums > Quests > Quests::Q&A

Quests::Q&A This is the quest support section

Reply
 
Thread Tools Display Modes
  #1  
Old 04-17-2009, 12:47 PM
cavedude's Avatar
cavedude
The PEQ Dude
 
Join Date: Apr 2003
Location: -
Posts: 1,988
Default

Yep, that's exactly it, except that timer is for 30 seconds.
Reply With Quote
  #2  
Old 04-17-2009, 12:50 PM
Randymarsh9
Dragon
 
Join Date: Dec 2007
Posts: 658
Default

Haha, yeah because I was planning on testing it and didn't want to wait 10 minutes to see if it ported me.
Reply With Quote
  #3  
Old 04-17-2009, 01:06 PM
cavedude's Avatar
cavedude
The PEQ Dude
 
Join Date: Apr 2003
Location: -
Posts: 1,988
Default

Yeah I do the same.
Reply With Quote
  #4  
Old 04-17-2009, 01:53 PM
Randymarsh9
Dragon
 
Join Date: Dec 2007
Posts: 658
Default

Another quick question, if I wanted a monster to spawn based on the person's class that enters the zone, would I just do something like if
Code:
if ($class eq "Warrior"){
quest::spawn(ID,0,0,x,y,z)
}
in the sub event_enterzone and repeat that for other classes using elsif?
Reply With Quote
  #5  
Old 04-17-2009, 02:57 PM
cavedude's Avatar
cavedude
The PEQ Dude
 
Join Date: Apr 2003
Location: -
Posts: 1,988
Default

I see no reason why that wouldn't work.
Reply With Quote
  #6  
Old 04-17-2009, 07:25 PM
Randymarsh9
Dragon
 
Join Date: Dec 2007
Posts: 658
Default

Alright, I don't think my timers are working. In the player.pl I made it like this
Code:
sub EVENT_ENTERZONE{
quest::settimer("zonekick",10);
quest::ze("You have 10 minutes to finish.");
if ($class eq "Warrior"){
 quest::spawn(1207, 0, 0, 0, 0, 0.50);
}
elsif ($class eq "Ranger"){
 quest::spawn(1214, 0, 0, 0, 0, 0.50);
}
}
sub EVENT_TIMER{
if ($timer eq "zonekick"){
 quest::stoptimer("zonekick");
 quest::movepc(202, -107,-190.-156);
 }
}
sub EVENT_DEATH{
quest::depopzone(1);
}
The correct monsters are spawning based on the class, which is good, but the zone-wide emote doesn't show and the timer doesn't seem to work either. I lowered it to 10 seconds just so I could test it. I have this is another quest and the timer doesn't work here either.
Code:
EVENT_SPAWN{
 quest::attack($name);
}
sub EVENT_DEATH{
 quest::summonitem(20488);
 quest::summonitem(20487);
 quest::emote("collapses to the ground.");
 quest::settimer("peaceout",5);
}
sub EVENT_TIMER{
 if ($timer eq "peaceout"){
 quest::stoptimer("peaceout");
 quest::movepc(202, -107,-190.-156);
}
}
Reply With Quote
  #7  
Old 04-17-2009, 09:17 PM
joligario's Avatar
joligario
Developer
 
Join Date: Mar 2003
Posts: 1,500
Default

Are you sure the timer isn't working? Or could it be the period instead of a comma in the movepc() commands?
Reply With Quote
  #8  
Old 04-18-2009, 02:17 PM
covou
Sarnak
 
Join Date: Jan 2006
Posts: 31
Default

Quote:
Originally Posted by Randymarsh9 View Post
Alright, I don't think my timers are working. In the player.pl I made it like this
Code:
sub EVENT_ENTERZONE{
quest::settimer("zonekick",10);
quest::ze("You have 10 minutes to finish.");
if ($class eq "Warrior"){
 quest::spawn(1207, 0, 0, 0, 0, 0.50);
}
elsif ($class eq "Ranger"){
 quest::spawn(1214, 0, 0, 0, 0, 0.50);
}
}
sub EVENT_TIMER{
if ($timer eq "zonekick"){
 quest::stoptimer("zonekick");
 quest::movepc(202, -107,-190.-156);
 }
}
sub EVENT_DEATH{
quest::depopzone(1);
}
The correct monsters are spawning based on the class, which is good, but the zone-wide emote doesn't show and the timer doesn't seem to work either. I lowered it to 10 seconds just so I could test it. I have this is another quest and the timer doesn't work here either.
Code:
EVENT_SPAWN{
 quest::attack($name);
}
sub EVENT_DEATH{
 quest::summonitem(20488);
 quest::summonitem(20487);
 quest::emote("collapses to the ground.");
 quest::settimer("peaceout",5);
}
sub EVENT_TIMER{
 if ($timer eq "peaceout"){
 quest::stoptimer("peaceout");
 quest::movepc(202, -107,-190.-156);
}
}
The timer in your monster code won't work because an npc will not set, and persist a timer if it is dead.

as for your player code... try this.

Code:
sub EVENT_ENTERZONE
{
quest::settimer("zonekick",10);
quest::ze("You have 10 minutes to finish.");
   if ($class eq "Warrior")
      {
      quest::spawn(1207, 0, 0, 0, 0, 0.50);
      }
   elsif ($class eq "Ranger")
      {
      quest::spawn(1214, 0, 0, 0, 0, 0.50);
      }
}
sub EVENT_TIMER{
if ($timer eq "zonekick"){
 quest::stoptimer("zonekick");
 quest::movepc(202, -107, -190, -156);
 }
}
sub EVENT_DEATH{
quest::stoptimer("zonekick");
quest::depopzone();
}
If it continues not to work. Can you post Error Logs?
Reply With Quote
Reply

Thread Tools
Display Modes

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 03:09 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 - 2025, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3