Go Back   EQEmulator Home > EQEmulator Forums > Development > Development: Custom Code

Development: Custom Code This is for code thatdoes not emulate live and wont be added to the official code.

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #3  
Old 05-02-2012, 10:19 AM
sorvani
Dragon
 
Join Date: May 2010
Posts: 965
Default

You are using the wrong command or the wrong arguments.
Quote:
quest::movepc(zoneid,x,y,z,[heading]) - Moves the user that triggered the Event to the provided zone and loc. Heading is optional.
quest::gmmove(x,y,z) - Moves the user that triggered the Event to the provided loc.
quest::MovePCInstance(zoneid, instanceid, x, y, z) - Moves a player to an instance
Is your NPC already in PoTimeB? If so use quest::gmmove.
If they are not, then you can not just move the plaver to an instance with quest::movepc as it does not take an argument for instance id. That is what questMovePCInstance is for. I added the instance logic and put it in the fire response as an example for you. Otherwise I changed the rest to be gmmove.

Code:
my $InstID = 0;

sub EVENT_SAY {
  $InstID = quest::GetInstanceID("potimeb",0);
  if ($text =~/Hail/i) {
    quest::say("How could YOU defeat ME, $name? I have no choice but to send you to the next battle! Perhaps, you will taste death soon! Which way would you like to die? [Fire], [Water], [Undead], [Air] or [Earth]?");
  }
  elsif ($text =~/Fire/i) {
    quest::shout ("$name , go forth and DIE!!");
    quest::emote ("waves his boney finger in a circle...");
    quest::MovePCInstance(223,$InstID,-60,565,494); 
  }
  elsif ($text =~/Water/i) {
    quest::shout ("$name , go forth and DIE!! ");
    quest::emote ("waves his boney finger in a circle...");
    quest::gmmove(-60,852,494);
  }
  elsif ($text =~/Undead/i) {
    quest::shout ("$name , go forth and DIE!! ");
    quest::emote ("waves his boney finger in a circle...");
    quest::gmmove(-33,1107,494);
  }
  elsif ($text =~/Air/i) {
    quest::shout ("$name , go forth and DIE!! ");
    quest::emote ("waves his boney finger in a circle...");
    quest::gmmove(-54,1344,494);
  }
  elsif ($text =~/Earth/i) {
    quest::shout ("$name , go forth and DIE!! ");
    quest::emote ("waves his boney finger in a circle...");
    quest::gmmove(-53,1630,494);
  }
}

sub EVENT_SPAWN {
  quest::settimer("depop",3600); 
}

sub EVENT_TIMER {
  if ($timer eq "depop") {
    quest::depop();
  }
}
Reply With Quote
 


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 10:18 AM.


 

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