NPC + Target DD
Syntax of :
$npc->castSpell(9247,$client); It seems to only be able to cast "Point Blank AE" spells. Is this because it can't find a target? I've tried everything I can find and i'm finally posting. Please help. |
try using this. I think CastSpell is also case sensitive
Code:
$npc->CastSpell(9247,$userid); |
I've tried,
$npc->CastSpell(9247,$userid); $npc->CastSpell($userid,9247); $npc->CastSpell(9247,$name); $npc->CastSpell(9247,$target); $npc->CastSpell(9247,$npc->GetHateTop()); $npc->CastSpell(9247,$npc->GetTopHate()); $npc->CastSpell(9247,$npc->GetHateMost()); $npc->CastSpell(9247,$GetTarget()); $npc->CastSpell(9247,$npc->$GetTarget()); You get the idea, Also tried adding in $targ = $npc->GetHateTop(); $whohit = $entity_list->GetClientByID($targ); and then using $npc->CastSpell(9248,$whohit); And then he begins casting but interrupts, everytime. Spells are instant also. |
What sub are you calling it from? Sometimes not all the variables you are calling are passed. Maybe you should paste your code.
|
We are calling this from EVENT_TIMER, what we are trying to do, unsuccessfully, is have the mob cast a single target spell on whoever is on the top of his hate list every so often (or target, but that is prone to exploits).
We have tried numerous things, and can not get it to work. Is there any way for us to do this? |
Disregard, we got this to work.
Code:
$targ = $npc->GetTarget(); |
Yeah, the client does not trigger the timer, so userid and client would not pass. $targetname will pass through timer though.
|
All times are GMT -4. The time now is 05:44 PM. |
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.