Thread Tools Display Modes
05-30-08, 11:03 PM   #1
Isagard
A Defias Bandit
Join Date: May 2008
Posts: 2
Hooking TargetLastTarget()?

Would it be possible to hook the protected function TargetLastTarget() to target your last target after an if statement? If so, how? Would you have to use secure frames?
  Reply With Quote
05-31-08, 01:31 AM   #2
Tekkub
A Molten Giant
 
Tekkub's Avatar
AddOn Author - Click to view addons
Join Date: Dec 2005
Posts: 960
No, it is not possible.
  Reply With Quote
05-31-08, 06:18 AM   #3
Isagard
A Defias Bandit
Join Date: May 2008
Posts: 2
Is it possible to hook any target function in such a way? Or what about hooking RunMacro() or RunMacroText() in the same way?
  Reply With Quote
05-31-08, 09:11 AM   #4
Slakah
A Molten Giant
 
Slakah's Avatar
AddOn Author - Click to view addons
Join Date: Aug 2007
Posts: 863
You can do hooksecurefunc() to try and avoid taint, which will do a post hook.
  Reply With Quote
05-31-08, 10:57 AM   #5
Shirik
Blasphemer!
Premium Member
WoWInterface Super Mod
AddOn Author - Click to view addons
Join Date: Mar 2007
Posts: 818
Originally Posted by Slakah View Post
You can do hooksecurefunc() to try and avoid taint, which will do a post hook.
I would like to stress the comment "post hook" which implies that you can't selectively call the original function. Thus, you can't hook it to make decisions on whether or not to comply with the request. This is intentional.
__________________
たしかにひとつのじだいがおわるのお
ぼくはこのめでみたよ
だけどつぎがじぶんおばんだってことわ
しりたくなかったんだ
It's my turn next.

Shakespeare liked regexes too!
/(bb|[^b]{2})/
  Reply With Quote

WoWInterface » Developer Discussions » Lua/XML Help » Hooking TargetLastTarget()?


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off