View Single Post
12-19-11, 07:07 AM   #4
Sniffles
A Black Drake
 
Sniffles's Avatar
AddOn Author - Click to view addons
Join Date: Aug 2010
Posts: 86
Originally Posted by SDPhantom View Post
You need your RelPoint to the be "BOTTOMLEFT" of nil, which is the screen itself, otherwise your buttons are likely to draw offscreen. Also, the offsets seem to be multiplied by 100 which would throw the buttons offscreen too.


Here's a snip of a cursor-target feature of a HUD addon I was working on that managed the position of the targeting reticule.
Code:
local scale,x,y=frame:GetEffectiveScale(),GetCursorPosition();
frame:SetPoint("CENTER",nil,"BOTTOMLEFT",x/scale,y/scale);
Works perfect!!
Thank you very much SDPhantom.
__________________
Hi!
  Reply With Quote