Usually it's easiest to just look at what modders have put together already. I spent a few hours debugging and working on this problem a few months ago. Here's the player window I made for someone:
http://www.eq2interface.com/forums/s...ead.php?t=8066
I wrote an explanation of the scripting steps there too.