Log in

View Full Version : help change players target?


spider661
11-09-2008, 04:51 PM
i want to change the players target on my buffer to ither nothing or to the player so that could buffs using the selfbuff command will work

i tried this
$client->RemoveFromTargets($npc);

bu it does not work.. any thoughts?

trevius
11-09-2008, 05:28 PM
I think it depends on exactly what you are trying to do. But, if you just want a player to cast a buff on themselves, this command should work:

quest::selfcast(spellid);


I haven't tested this, but if you want to change a target, maybe something like this would work:

my $cname = $client->GetCleanName();

my $get_client = $entity_list->GetClientByName($cname);

$client->SetTarget($get_client);

spider661
11-09-2008, 07:43 PM
when you buff with selfcast and your a war for say it don't always group buff your group because your targeting the npc not yourself or a group member.

so im trying to get the npc to make you cast the spells but make you target yourself or clear your target.

and that did not work just stopped at that pint and no buffs fired off.

spider661
11-09-2008, 07:45 PM
sorry that did work thanks.