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 12-30-2012, 02:27 PM
Davood
Discordant
 
Join Date: Jan 2005
Posts: 488
Default

then this shold work right?

Code:
my $npc_target = $client->GetTarget();
my $mon_target = $npc_target->GetMobID();
$client->CastSpell($a_cast_buff,$mon_target,10,0,0);
it doesn't i'm not sure why

$a_cast_buff is some spell id value (i outputted it to make sure it was valid)

casting on $clientid works with the same $client->Cast. etc code
__________________
----------
Demon Overlord of Alakamin
skype @ davoodinator
Reply With Quote
  #2  
Old 12-30-2012, 02:39 PM
c0ncrete's Avatar
c0ncrete
Dragon
 
Join Date: Dec 2009
Posts: 719
Default

i'd start by testing the return value of GetTarget(). this should evaluate to true if you've got anything targeted:

Code:
ref($client->GetTarget()) =~ /Mob/i
if it's false, then GetTarget() isn't returning a Mob object
Reply With Quote
  #3  
Old 12-30-2012, 02:52 PM
c0ncrete's Avatar
c0ncrete
Dragon
 
Join Date: Dec 2009
Posts: 719
Default

i think i know what the problem is. GetMobID() isn't what you want. you should be using GetID(). GetMobID() returns a Mob object (don't ask me why, because it doesn't make any sense to me either) and is an $entity_list method, not a $mob method.

EDIT: i updated the QuestObject method list on the wiki at revision 2264, so some things have been moved/removed/added fairly recently. i used python scripts to parse the information so i didn't have to do it all by hand. i'll likely be updating it this way every few weeks and adding additional information to each entry when i have time (and motivation).

Quote:
Originally Posted by Davood View Post
then this shold work right?

Code:
my $npc_target = $client->GetTarget();
my $mon_target = $npc_target->GetMobID();
$client->CastSpell($a_cast_buff,$mon_target,10,0,0);
it doesn't i'm not sure why

$a_cast_buff is some spell id value (i outputted it to make sure it was valid)

casting on $clientid works with the same $client->Cast. etc code
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 01:58 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