DispelFrames插件分析

时间:2014-12-22 15:41:34   收藏:0   阅读:279

功能:Shows new frames for dispellable buffs for target and focus, and a bright border around default buff frames.

使用了Ace3库

分析:

1、xml定义了两个框体:DispelFrames_TargetFrame和DispelFrames_FocusFrame

2、这两个框体设置了同一个脚本OnUpdate函数:DispelFrames_OnUpdate

3、DispelFrames_OnUpdate函数主要用于控制显示性能,也就是刷框体内容的时间间隔,插件核心功能放在了下一级函数DispelFrames_UpdateAuras

4、DispelFrames_UpdateAuras里,使用了WOW API函数UnitBuff ,用它可以枚举出指定单位的所有buffs,一次返回一个buff,返回名字、图标、时间、法术ID等等信息,

其中返回的 isStealable数据表明了该buff是否可以被偷取(驱散)

 

原文:http://www.cnblogs.com/yuyuyu/p/4178165.html

评论(0
© 2014 bubuko.com 版权所有 - 联系我们:wmxa8@hotmail.com
打开技术之扣,分享程序人生!