View Single Post
12-06-17, 10:20 AM   #1
vis781
A Fallenroot Satyr
Join Date: Dec 2017
Posts: 27
Dynamic frame resize, whilst in combat?

Hi there, first post here and a newbie member so thank you for taking the time to read this..

I am an experienced asm/c/c++ programmer that loves wow and am having a go at writing my first addon. I have no problems with events, frames, textures and understanding coding in general.

The problem I have is this.. I am creating a target unit frame ( a simple one ) and all I want it to do right now is dynamically change its width based on the width of the targets name. I have the frame with some text for the name of the target all doing what it should except for combat... now you see my problem, I can't change the width of the frame whilst in combat to match the width of the new targets name, not allowed and I get why.

Thing is I have seen frames dynamically resize whilst in combat.. i.e raid frames, so it must be possible...

Now I think I need to be involved with RegisterStateDriver and secure frame wrapscript etc.. I mean I have a secure frame, that's easy, and I understand setting attributes, however I don't know how to respond to a change of target in the frames secure environment. I do hope this makes sense.. or you get the idea of what i'm trying to do.... should be simple to do I think, but I just can't see it.

Thank you all for reading

Kind regards

v

p.s I have posted this in the wrong forum, I'm very sorry, could a mod please move it for me? Thank you.

Last edited by vis781 : 12-06-17 at 10:23 AM. Reason: typo, posted in wrong forum ( sorry )
  Reply With Quote