魔兽怎么使用raiseevent如何使用命令

魔兽世界的动作指令_百度知道[福利] 给鱼不如学捕鱼
宏命令改界面命令大全
=== 03:17===5.2版本号 50200
其实直接过期插件就行 没区别=== 17:42===[color=red][b]5.1版本号写 50100[/b][/color]=== 17:41===5.1版本号写 50100=== 10:15===[url]/v_show/id_XNDUyMzE3Mjg0.html[/url] [color=red]教程视频[/color]AKF一年后回来 不知道有人做过这个没 我看过很多这方面的 但是好像都不太全
所以就有了这帖 希望懂的人 来补充 把修改界面参数的补全我在AJ美服论坛 PVP区看到一个专门介绍修改界面的参数大全
所以我想 为什么我们不来一个这样的置顶贴呢?做一个自己的宏命令插件 只占用10-50 K 左右的插件内存 能最大话的使电脑流畅 而且界面更清晰
需要监视的技能 和 徽章也可以监视 以前玩CS的时候 就喜欢研究config 文件 各种参数
现在把这份热情也带到了魔兽世界里我主要目的是抛砖引玉
希望懂的达人能出一份力
给想自己修改界面的玩家做到想改什么就改什么什么?你对插件一点概念也没有?好吧
一步步来首先 在X:\World of Warcraft\Interface\AddOns 下 建立一个文件夹 名字随便 比如 autoexec
在这里面建立2个文件 分别是autoexec.tocautoexec.luaautoexec.toc 文件内容## Interface: 50001
(版本号 这个就是解决插件过期的问题 但是里面的参数不是最新的话 有时候会报错 所以也不是说改个版本号就完美兼容了)& && && &## Title: Autoexec
( 插件名)## Notes: Automatically runs scripts on loginAutoexec.lua
(意思是 载入 Autoexec.lua )把想改的插件内容放到
autoexec.lua 里 就行了[color=red]以下所有命令都可以加入到 lua文件里 做个属于自己的脚本插件吧重点注意!用/run 可以使用的宏命令 比如这样的& && &TargetFrameToT:ClearAllPoints()
& && &TargetFrameToT:SetPoint(&BOTTOMRIGHT&,TargetFrame,-15,-10) & && &FocusFrameToT:ClearAllPoints()& && &FocusFrameToT:SetPoint(&BOTTOMRIGHT&,FocusFrame,-15,-10)
& && &FocusFrameSpellBar:SetScale(1.1)
& && &TargetFrameSpellBar:SetScale(1.1)
& && &MainMenuBarLeftEndCap:Hide()
& && &MainMenuBarRightEndCap:Hide()很好分辨的可以加入到 我帖子第一个的中间位置来实现 也就是我发的这些命令的中间加入他们一行一行的
其他的 脚本类的 比如if for (i=0) 这种乱七八糟的 把他们放到最下面 [/color][color=royalblue][[size=150%]我自己的设置[/size]][/color]----------------------------------------------------[code]local frame = CreateFrame(&Frame&)frame:RegisterEvent(&PLAYER_LOGIN&)frame:RegisterEvent(&ADDON_LOADED&)frame:RegisterEvent(&PLAYER_ENTERING_WORLD&)SLASH_AF1 = &/af&local function eventHandler(self,event,arg1)& &if event == &PLAYER_LOGIN& then& && &TargetFrameToT:ClearAllPoints()
& && &TargetFrameToT:SetPoint(&BOTTOMRIGHT&,TargetFrame,-15,-10) & && &FocusFrameToT:ClearAllPoints()& && &FocusFrameToT:SetPoint(&BOTTOMRIGHT&,FocusFrame,-15,-10)
& && &FocusFrameSpellBar:SetScale(1.1)
& && &TargetFrameSpellBar:SetScale(1.1)
& && &MainMenuBarLeftEndCap:Hide()
& && &MainMenuBarRightEndCap:Hide()
& && &UIErrorsFrame:UnregisterEvent(&UI_ERROR_MESSAGE&)
& &endendframe:SetScript(&OnEvent&,eventHandler)[/code]像这样的命令 只要在聊天窗口加入 /run 也是可以实现的
这个命令的意思是 移动目标的目标坐标
正常的目标的目标是挡BUFF的 通过这个改后正好不挡 15和10是坐标可以自己修改到喜欢的位置& && &FocusFrameToT:SetPoint(&BOTTOMRIGHT&,FocusFrame,-15,-10)
焦点目标的目标 位置& && &FocusFrameSpellBar:SetScale(1.1)
焦点施法条大小& && &TargetFrameSpellBar:SetScale(1.1)
目标施法条大小& && &MainMenuBarLeftEndCap:Hide()
隐藏动作条左边鹰& && &MainMenuBarRightEndCap:Hide()
隐藏动作条右边鹰& && &UIErrorsFrame:UnregisterEvent(&UI_ERROR_MESSAGE&)
屏蔽错误提示红字[color=royalblue][size=150%][职业头像 不包括NPC][/size][/color]------------------------------------------------------------[code]hooksecurefunc(&UnitFramePortrait_Update&,function(self)
if self.portrait then
if UnitIsPlayer(self.unit) then
local t = CLASS_ICON_TCOORDS[select(2, UnitClass(self.unit))]
self.portrait:SetTexture(&Interface\\TargetingFrame\\UI-Classes-Circles&)
self.portrait:SetTexCoord(unpack(t))
self.portrait:SetTexCoord(0,1,0,1)
end end)[/code][color=royalblue][size=150%][默认竞技场框体监视徽章 输入/baf 测试位置][/size][/color]-----------------------------------------------[code]local trinkets = {} local events = CreateFrame(&Frame&) function events:ADDON_LOADED(addonName)
if addonName ~= &Blizzard_ArenaUI& then
local arenaFrame, trinket
for i = 1, MAX_ARENA_ENEMIES do
arenaFrame = &ArenaEnemyFrame&..i
trinket = CreateFrame(&Cooldown&, arenaFrame..&Trinket&, ArenaEnemyFrames)
trinket:SetPoint(&Right&, arenaFrame, 29, -5)
trinket:SetSize(30, 30)
trinket.icon = trinket:CreateTexture(nil, &BACKGROUND&)
trinket.icon:SetAllPoints()
trinket.icon:SetTexture(&Interface\\Icons\\inv_jewelry_trinketpvp_01&)
trinket:Hide()
trinkets[&arena&..i] = trinket
self:UnregisterEvent(&ADDON_LOADED&) end function events:UNIT_SPELLCAST_SUCCEEDED(unitID, spell, rank, lineID, spellID)
if not trinkets[unitID] then
if spellID == 59752 or spellID == 42292 then
CooldownFrame_SetTimer(trinkets[unitID], GetTime(), 120, 1)
SendChatMessage(&Trinket used by: &..GetUnitName(unitID, true), &PARTY&)
elseif spellID == 7744 then
CooldownFrame_SetTimer(trinkets[unitID], GetTime(), 45, 1)
SendChatMessage(&WotF used by: &..GetUnitName(unitID, true), &PARTY&)
end end function events:PLAYER_ENTERING_WORLD()
local _, instanceType = IsInInstance()
if instanceType == &arena& then
self:RegisterEvent(&UNIT_SPELLCAST_SUCCEEDED&)
elseif self:IsEventRegistered(&UNIT_SPELLCAST_SUCCEEDED&) then
self:UnregisterEvent(&UNIT_SPELLCAST_SUCCEEDED&)
for _, trinket in pairs(trinkets) do
trinket:SetCooldown(0, 0)
trinket:Hide()
end end SLASH_BAF1 = &/baf& SlashCmdList[&BAF&] = function(msg, editBox)
if not IsAddOnLoaded(&Blizzard_ArenaUI&) then
LoadAddOn(&Blizzard_ArenaUI&)
ArenaEnemyFrames:Show()
local arenaFrame
for i = 1, MAX_ARENA_ENEMIES do
arenaFrame = _G[&ArenaEnemyFrame&..i]
arenaFrame.classPortrait:SetTexture(&Interface\\TargetingFrame\\UI-Classes-Circles&)
arenaFrame.classPortrait:SetTexCoord(unpack(CLASS_ICON_TCOORDS[&WARRIOR&]))
arenaFrame.name:SetText(&Dispelme&)
arenaFrame:Show()
CooldownFrame_SetTimer(trinkets[&arena&..i], GetTime(), 120, 1)
end end events:SetScript(&OnEvent&, function(self, event, ...) return self[event](self, ...) end) events:RegisterEvent(&ADDON_LOADED&) events:RegisterEvent(&PLAYER_ENTERING_WORLD&)[/code][color=royalblue][size=150%][生命显示方式以K为单位][/size][/color]-------------------------------------------------------------------------[code]local function HealthBarText(statusFrame, textString, value, valueMin, valueMax)
if string.find(textString:GetName(), &Health&) or string.find
if valueMax ~= 0 then
local percent = tostring(math.ceil((value / valueMax) * 100))
value = HealthBarText_CapDisplayOfNumericValue(value)
valueMax = HealthBarText_CapDisplayOfNumericValue(valueMax)
textString:SetText(value..&&)
endendhooksecurefunc(&TextStatusBar_UpdateTextStringWithValues&, HealthBarText)function HealthBarText_CapDisplayOfNumericValue(value)
local strLen = strlen(value);
local retString =
if ( strLen & 9 ) then
retString = string.sub(value, 1, -9)..SECOND_NUMBER_CAP;
elseif ( strLen & 4 ) then
retString = string.sub(value, 1, -4)..&K&;
return retSend[/code]这里的2个9 代表亿
这个 SECOND_NUMBER_CAP 的意思 是中文“亿”这里的2个4 代表 到达4位数的时候 比如1000 以K的方式显示 你也可以把2个4 改成2个5 把K改成W 也就是1万显示了 但是 建议以K 也就是千 为单位 不然你打人平砍都看不到数字变化的其实这个改血量单位的 很多北美盗贼玩家都有改 reckful neilyo woundman 但是这么普遍的东西 我在百度NGA找了一宿。[color=royalblue][size=150%][头像上显示小型职业图标][/size][/color]------------------------------------------------------------------------------------------ TargetClassButton by 狂飙@cwdg(.cn) -- 添加到暴雪目标头像上的按钮,左键查看目标装备、右键与目标交易、中键密语、鼠标按键4跟随、鼠标按键5比较成就、到可观察装备距离时职业图标由灰白变彩色。[code]local targeticon = CreateFrame(&Button&, &TargetClass&, TargetFrame)targeticon:Hide()targeticon:SetWidth(32)targeticon:SetHeight(32)targeticon:SetPoint(&TOPLEFT&, TargetFrame, &TOPLEFT&, 119, 3)targeticon:SetHighlightTexture(&Interface\\Minimap\\UI-Minimap-ZoomButton-Highlight&)local bg = targeticon:CreateTexture(&TargetClassBackground&, &BACKGROUND&)bg:SetTexture(&Interface\\Minimap\\UI-Minimap-Background&)bg:SetWidth(20)bg:SetHeight(20)bg:SetPoint(&CENTER&)bg:SetVertexColor(0, 0, 0, 0.7)local icon = targeticon:CreateTexture(&TargetClassIcon&, &ARTWORK&)icon:SetTexture(&Interface\\WorldStateFrame\\Icons-Classes&)icon:SetWidth(20)icon:SetHeight(20)icon:SetPoint(&CENTER&)local lay = targeticon:CreateTexture(&TargetClassBorder&, &OVERLAY&)lay:SetTexture(&Interface\\Minimap\\MiniMap-TrackingBorder&)lay:SetWidth(54)lay:SetHeight(54)lay:SetPoint(&CENTER&, 11, -12)RaiseFrameLevel(targeticon)targeticon:SetScript(&OnUpdate&, function(self)& &if (not UnitCanAttack(&player&,&target&) and UnitIsPlayer(&target&) and CheckInteractDistance(&target&,1)) then& && &targeticon:Enable()& &--& &TargetClassIcon:SetDesaturated(false)& && &SetDesaturation(TargetClassIcon, false)& &else& && &targeticon:Disable()& &--& &TargetClassIcon:SetDesaturated(true)& && &SetDesaturation(TargetClassIcon, true)& &endend)local havedown = falselocal function TargetClassIconDown()& &local point, relativeTo, relativePoint, offsetX, offsetY = TargetClassIcon:GetPoint()& &TargetClassIcon:SetPoint(point, relativeTo, relativePoint, offsetX+1, offsetY-1)& &return trueend-- targeticon:RegisterForClicks(&AnyDown&)targeticon:SetScript(&OnMouseDown&, function(self, button)& &if (not UnitCanAttack(&player&,&target&) and UnitIsPlayer(&target&)) then& && &if button == &LeftButton& then& && && &if CheckInteractDistance(&target&,1) then& && && && &havedown = TargetClassIconDown()& && && && &InspectUnit(&target&)& && && &end& && &elseif button == &RightButton& then& && && &if CheckInteractDistance(&target&,2) then& && && && &havedown = TargetClassIconDown()& && && && &InitiateTrade(&target&)& && && &end& && &elseif button == &MiddleButton& then& && && && &havedown = TargetClassIconDown()& && && && &local server =& && && && &local name, server = UnitName(&target&);& && && && &local fullname =& && && && &if ( server and (not &target& or not UnitIsSameServer(&player&, &target&)) ) then& && && && && &fullname = name..&-&..& && && && &end& && && && &ChatFrame_SendTell(fullname)& && && &--& &StartDuel(&target&)& && &elseif button == &Button4& then& && && &if CheckInteractDistance(&target&,4) then& && && && &havedown = TargetClassIconDown()& && && && &FollowUnit(fullname, 1);& && && &end& && &else& && && &if CheckInteractDistance(&target&,1) then& && && && &havedown = TargetClassIconDown()& && && && &InspectAchievements(&target&)& && && &end& && &end& &endend)local function TargetClassIconUp()& &local point, relativeTo, relativePoint, offsetX, offsetY = TargetClassIcon:GetPoint()& &TargetClassIcon:SetPoint(point, relativeTo, relativePoint, offsetX-1, offsetY+1)& &return falseend-- targeticon:RegisterForClicks(&AnyUp&)targeticon:SetScript(&OnMouseUp&, function(self)& &if havedown then& && &havedown = TargetClassIconUp()& &endend)hooksecurefunc(&TargetFrame_Update&, function()& &if UnitIsPlayer(&target&) then& &--& &local _, class = UnitClass(&target&)& &--& &local coord = CLASS_BUTTONS[class]& &--& &TargetClassIcon:SetTexCoord(coord[1], coord[2], coord[3], coord[4])& && &local coord = CLASS_BUTTONS[select(2, UnitClass(&target&))]& && &TargetClassIcon:SetTexCoord(unpack(coord))& && &targeticon:Show()& &else& && &targeticon:Hide()& &endend)[/code][color=royalblue][size=150%][各种框体大小设置][/size][/color]-----------------------------------------------[code]MainMenuBar:SetScale(1.3)
PlayerFrame:SetScale(1.3)& && &TargetFrame:SetScale(1.3)& && &FocusFrame:SetScale(1.3)& && &ComboFrame:SetScale(1.3)& && &FocusFrameSpellBar:SetScale(1.2)& &TargetFrameSpellBar:SetScale(1.2)& &ArenaEnemyFrames:SetScale(1.2)[/code]前半段是框体名 后半段setscale代表大小 (1.3) 是你想改多大MainMenuBar:SetScale(1.3)
动作条大小PlayerFrame:SetScale(1.3)& && &玩家框体大小TargetFrame:SetScale(1.3)& && &目标框体大小FocusFrame:SetScale(1.3)& && &焦点框体大小ComboFrame:SetScale(1.3)& && &目标连击点大小FocusFrameSpellBar:SetScale(1.2)& &焦点施法条大小TargetFrameSpellBar:SetScale(1.2)& &目标施法条大小ArenaEnemyFrames:SetScale(1.2)
竞技场敌人目标[color=royalblue][size=150%][动作条透明][/size][/color]------------------------------[code]MainMenuBarTexture0:Hide()& &MainMenuBarTexture1:Hide()& &MainMenuBarTexture2:Hide()MainMenuBarTexture3:Hide()[/code][color=royalblue][size=150%][焦点施法条在上方][/size][/color]-----------------------------------[code]FocusFrameSpellBar:ClearAllPoints()FocusFrameSpellBar:SetPoint(&TOPLEFT&,FocusFrame,&TOPLEFT&,15,6)FocusFrameSpellBar.SetPoint = function() end[/code][color=royalblue][size=150%][自动调节延迟容许值][/size][/color] --------------------------------------local ALTTimer = CreateFrame(&Frame&);ALTTimer:Hide();local ALTEventFrame = CreateFrame(&Frame&);ALTEventFrame:RegisterEvent(&VARIABLES_LOADED&);local CurVersion = 0.6;-- DefaultsAutoLagToleranceDB_Defaults = {& &Version = 0.6,& &Offset = 0,& &Interval = 30,& &Threshold = 5,& &Min = nil,& &Max = nil,};-- Varslocal MinLatency, MaxLlocal LatencyIlocal OldLatency = -9999;-- InitializeALTEventFrame:SetScript(&OnEvent&, function(self)& &SetCVar(&reducedLagTolerance&, 1);& && &-- Get Min/Max latency values& &MinLatency = CombatPanelOptions[&MaxSpellStartRecoveryOffset&].minValue or 0;& &MaxLatency = CombatPanelOptions[&MaxSpellStartRecoveryOffset&].maxValue or 400;& && &-- Defaults& &if not AutoLagToleranceDB then& && &AutoLagToleranceDB = AutoLagToleranceDB_D& &end& &if not AutoLagToleranceDB.Version then& && &AutoLagToleranceDB = AutoLagToleranceDB_D& &end& &if AutoLagToleranceDB.Version ~= CurVersion then& && &AutoLagToleranceDB = AutoLagToleranceDB_D& &end& &AutoLagToleranceDB.Version = CurV& && &-- Start timer& &LatencyInterval = 1;& &ALTTimer:Show();end);local UpdatedCount = 0;-- TimerALTTimer:SetScript(&OnUpdate&, function(self, elapsed)& &LatencyInterval = LatencyInterval -& &if LatencyInterval &= 0 then& && &-- Get Latency& && &local _,_,_,Latency = GetNetStats();& && &if Latency ~= OldLatency then& && && && && && &if not Latency then Latency = 0; end& && && &Latency = Latency + AutoLagToleranceDB.O& && && && && && &-- Set Latency to be within Min/Max boundaries& && && &if AutoLagToleranceDB.Min then Latency = max(Latency, AutoLagToleranceDB.Min); end& && && &if AutoLagToleranceDB.Max then Latency = min(Latency, AutoLagToleranceDB.Max); end& && && &if Latency & MinLatency then Latency = MinL end& && && &if Latency & MaxLatency then Latency = MaxL end& && && && && && &-- If Latency changed and greater than the change threshold, then update& && && &if ((Latency & OldLatency) and ((Latency + AutoLagToleranceDB.Threshold) &= OldLatency)) or ((Latency & OldLatency) and ((Latency - AutoLagToleranceDB.Threshold) &= OldLatency)) then& && && && &SetCVar(&MaxSpellStartRecoveryOffset&, Latency);& && && && &OldLatency = L& && && &end& && && && && && &-- Search for first real Latency update, so we can find the beginning of GetNetStats()'s 30sec update cycle& && && &if UpdatedCount & 2 then& && && && &UpdatedCount = UpdatedCount + 1;& && && &end& && &end& && && && &-- Reset timer& && &if UpdatedCount & 2 then& && && &-- Still looking for first real Latency update& && && &LatencyInterval = 1;& && &elseif UpdatedCount & 5 then& && && &-- Run 3 more passes at 1sec each, so we can get 3sec ahead of the GetNetStats() update cycle& && && &LatencyInterval = 1;& && && &UpdatedCount = UpdatedCount + 1;& && &else& && && &-- Update cycle determined, set to normal updates from now on& && && &LatencyInterval = AutoLagToleranceDB.I& && &end& &endend);-- Slash optionsSLASH_AUTOLAG1, SLASH_AUTOLAG2 = &/autolag&, &/autolagtolerance&;local function handler(msg, editbox)& &local command, val = msg:match(&^(%S*)%s*(.-)$&);& && &if command == &offset& then& &-- Change Offset& && &if val == && then return end& && &local NewLatencyOffset = tonumber(val);& && &if not NewLatencyOffset then NewLatencyOffset = 0; end& && && && &AutoLagToleranceDB.Offset = floor(NewLatencyOffset);& && && && &print(&New ALT offset = &..tostring(AutoLagToleranceDB.Offset));& &elseif command == &interval& then& &-- Change Interval& && &if val == && then return end& && &local NewLatencyInterval = tonumber(val);& && && &if not NewLatencyInterval then NewLatencyInterval = 3; end& && &if NewLatencyInterval & 1 then NewLatencyInterval = 1; end& && && && &AutoLagToleranceDB.Interval = NewLatencyI& && && && &print(&New ALT interval = &..tostring(AutoLagToleranceDB.Interval));& &elseif command == &threshold& then& &-- Change Threshold& && &if val == && then return end& && &local NewThreshold = tonumber(val);& && && &if not NewThreshold then NewThreshold = 0; end& && &if NewThreshold & 0 then NewThreshold = 0; end& && && && &AutoLagToleranceDB.Threshold = floor(NewThreshold);& && && && &print(&New ALT threshold = &..tostring(AutoLagToleranceDB.Threshold));& &elseif command == &min& then& &-- Change Min& && &local NewMin =& && &if val == && then & && && &NewMin =& && && &AutoLagToleranceDB.Min = NewM& && && &print(&ALT minimum is now disabled and will use the default WoW value.&);& && &else& && && &NewMin = tonumber(val);& && && && &if not NewMin then NewMin = 0; end& && && &if NewMin & MinLatency then& && && && &NewMin = MinL& && && && &print(&Note: Min can't be lower than the WoW minimum Lag Tolerance value (&..tostring(MinLatency)..&).&);& && && &end& && && &if NewMin & MaxLatency then & && && && &NewMin = MaxL& && && && &print(&Note: Min can't be greater than the WoW maximum Lag Tolerance value (&..tostring(MaxLatency)..&).&);& && && &end& && && &if AutoLagToleranceDB.Max then& && && && &if NewMin & AutoLagToleranceDB.Max then& && && && && &NewMin = min(MaxLatency, AutoLagToleranceDB.Max);& && && && && &print(&Note: Min can't be greater than Max (&..tostring(AutoLagToleranceDB.Max)..&).&);& && && && &end& && && &end& && && && && && &AutoLagToleranceDB.Min = floor(NewMin);& && && && && && &print(&New ALT minimum = &..tostring(AutoLagToleranceDB.Min));& && &end& &elseif command == &max& then& &-- Change Max& && &local NewMax =& && &if val == && then & && && &NewMax =& && && &AutoLagToleranceDB.Max = NewM& && && &print(&ALT maximum is now disabled and will use the default WoW value.&);& && &else& && && &NewMax = tonumber(val);& && && && &if not NewMax then NewMax = 0; end& && && &if NewMax & MinLatency then& && && && &NewMax = MinL& && && && &print(&Note: Max can't be lower than the WoW minimum Lag Tolerance value (&..tostring(MinLatency)..&).&);& && && &end& && && &if NewMax & MaxLatency then & && && && &NewMax = MaxL& && && && &print(&Note: Max can't be greater than the WoW maximum Lag Tolerance value (&..tostring(MaxLatency)..&).&);& && && &end& && && &if AutoLagToleranceDB.Min then& && && && &if NewMax & AutoLagToleranceDB.Min then& && && && && &NewMax = max(MinLatency, AutoLagToleranceDB.Min);& && && && && &print(&Note: Max can't be lower than Min (&..tostring(AutoLagToleranceDB.Min)..&).&);& && && && &end& && && &end& && && && && && &AutoLagToleranceDB.Max = floor(NewMax);& && && && && && &print(&New ALT maximum = &..tostring(AutoLagToleranceDB.Max));& && &end& &elseif command == &reset& then& &-- Reset& && &AutoLagToleranceDB = AutoLagToleranceDB_D& && &LatencyInterval = AutoLagToleranceDB.I& && &print(&ALT settings have been reset to their default values.&);& &else& &-- Help& && &local MinValue, MaxV& && &print(&-- AutoLagTolerance: Command Line help --&);& && &print(&-&)& && &print(&|cffffff00Syntax:|r /autolag command value&);& && &print(&-&);& && &print(&|cffffff00Command listing:|r&);& && &print(&|cff50c0ffoffset|r|cffffffa0 (Current = &..tostring(AutoLagToleranceDB.Offset)..&ms)|r: How much latency to add or subtract to your actual latency in milliseconds. Use to fine tune your Lag Tolerance. Example: |cff90ff90[/autolag offset -5]|r will add a negative 5ms offset to your Lag Tolerance.&);& && &print(&|cff50c0ffinterval|r|cffffffa0 (Current = &..tostring(AutoLagToleranceDB.Interval)..&s)|r: How often to update your Lag Tolerance in seconds. Min = 1. Example: |cff90ff90[/autolag interval 5]|r will update the Lag Tolerance every 5 seconds.&);& && &print(&|cff50c0ffthreshold|r|cffffffa0 (Current = &..tostring(AutoLagToleranceDB.Threshold)..&s)|r: The difference rquired between your latency and the current Lag Tolerance value in order to set a new Lag Tolerance value. Min = 0. Example: |cff90ff90[/autolag threshold 5]|r will make it so that ALT will only change your Lag Tolerance if your current latency differs from it by 5ms or more.&);& && && && &if AutoLagToleranceDB.Min then& && && &MinValue = &Current = &..tostring(AutoLagToleranceDB.Min)..&ms&;& && &else& && && &MinValue = &Disabled&;& && &end& && &print(&|cff50c0ffmin|r|cffffffa0 (&..MinValue..&)|r: The minimum value to set your Lag Tolerance to. Min = &..tostring(MinLatency)..&. Example: |cff90ff90[/autolag min 50]|r will make it so that ALT will never set your Lag Tolerance below 50ms. Type |cff90ff90[/autolag min]|r to reset it to default.&);& && && && &if AutoLagToleranceDB.Max then& && && &MaxValue = &Current = &..tostring(AutoLagToleranceDB.Max..&ms&);& && &else& && && &MaxValue = &Disabled&;& && &end& && &print(&|cff50c0ffmax|r|cffffffa0 (&..MaxValue..&)|r: The maximum value to set your Lag Tolerance to. Max = &..tostring(MaxLatency)..&. Example: |cff90ff90[/autolag max 100]|r will make it so that ALT will never set your Lag Tolerance above 100ms. Type |cff90ff90[/autolag max]|r to reset it to default.&);& && &print(&|cff50c0ffreset|r: Reset ALT settings to their default values.&);& && &print(& &);& && &print(&|cffffff00Current Lag Tolerance = |r|cff50c0ff&..tostring(GetCVar(&MaxSpellStartRecoveryOffset&))..&|r&);& &endendSlashCmdList[&AUTOLAG&] = [color=royalblue][size=150%][动作条技能CD 数字显示 类是Omincc][/size][/color]-------------------------------------------------------------------------------------[code]cs=20;ps=1;ctp=&CENTER&ptp=&BOTTOMRIGHT&cp=5;ct=UNIT_NAME_FONT;crt=2;cDB={}action={}ccf=CreateFgac=GetActionCol=&OUTLINE&cpe=&PLAYER_ENTERING_WORLD&cau=&ACTIONBAR_UPDATE_COOLDOWN&co=&OnUpdate&function rt(f)f.e=nil f.t:SetText(&&)f:SetScript(co,nil)end function sf(f,v)f.t:SetFont(ct,f.s*v,ol)end function acv(b)local x=b.cooldown x.a=b.action action[x]=x end function scv(p,f,po,s)if(s&1)then f.t:SetPoint(po,p)end f.s=s;endfunction sr(f,e)if(e&60)then sf(f,0.7)if(f.s==cs)then return&%d:%02d&,e,e else return&%dm&,e+60,e end elseif(e&=cp)then sf(f,1)f.t:SetTextColor(1,1,0,1)return&%d&,e elseif(e&0)then sf(f,0.9)f.t:SetTextColor(1,0,0,1)return&%d&,e else return end endfunction suc(f)if not f.e then f.e=1;f:SetScript(co,function(s,e)f.c=f.c+e;local fo,v1,v2=sr(f,f.r-f.c)if not fo then rt(f)elseif not v2 then f.t:SetFormattedText(fo,v1)else f.t:SetTextColor(1,1,1,1)f.t:SetFormattedText(fo,v1/60,v2%60)end end)end endfunction scs(p,f)if(p:GetSize()&35)then scv(p,f,ptp,ps)else scv(p,f,ctp,cs)end end function gict(f)local c=ccf(&Frame&,nil,f)c:SetFrameLevel(f:GetFrameLevel()+5)c.t=c:CreateFontString(nil,&OVERLAY&)c.t:SetAllPoints(c)scs(f:GetParent(),c)endfunction gct(f)if not cDB[f]then local c=gict(f)c:SetSize(c.s*crt,c.s*crt)sf(c,1)cDB[f]=c;end return cDB[f]end function cvf(f,s,d)local c=gct(f)if(s and d)then c.b=s;c.d=d;if(s&0 and d&1.5)then c.c=0;c.r=d-(GetTime()-s);suc(c)else rt(c)end end endfunction cvc(DB)for c in pairs(DB)do if c.a then local s,d=gac(c.a)cvf(c,s,d)end end end function pcv(_,e)if e==cau then cvc(action)else cvc(cDB)end end for _,b in pairs(ActionBarButtonEventsFrame.frames)do acv(b)endvc=ccf(&Frame&)vc:SetScript(&OnEvent&,pcv)vc:RegisterEvent(cpe)vc:RegisterEvent(cau)hooksecurefunc(getmetatable(ActionButton1Cooldown).__index,&SetCooldown&,cvf)hooksecurefunc(&SetActionUIButton&,acv)[/code]
[color=royalblue][size=150%][超出技能距离范围 技能框体变红][/size][/color]-------------------------------------------------------------------------------------------[code]hooksecurefunc(&ActionButton_OnEvent&,function(self, event, ...) if ( event == &PLAYER_TARGET_CHANGED& ) then self.newTimer = self.rangeTimer end end) hooksecurefunc(&ActionButton_UpdateUsable&,function(self) local icon = _G[self:GetName()..&Icon&] local valid = IsActionInRange(self.action) if ( valid == 0 ) then icon:SetVertexColor(1.0, 0.1, 0.1) end end) RATM=rangeTimer hooksecurefunc(&ActionButton_OnUpdate&,function(self, elapsed) local RATM = self.newTimer if ( RATM ) then RATM = RATM - elapsed if ( RATM &= 0 ) then ActionButton_UpdateUsable(self) RATM = TOOLTIP_UPDATE_TIME end self.newTimer = RATM end end)[/code][color=royalblue][size=150%][目标 和 焦点 是否进入战斗 图标显示][/size][/color]-------------------------------------------------------------------------------------------其中的 Right 代表在头像的右边显示 如果改成 Left 代表在头像左边显示 top 代表上面显示 -11 是平行左边 9是上下的垂直坐标 25,25 是图标的大小 你可以按照你的意愿来修改[code]z=CreateFrame(&Frame&)z:SetParent(TargetFrame)z:SetPoint(&Right&,TargetFrame,-11,9)z:SetSize(25,25)z.t=z:CreateTexture(nil,BORDER)z.t:SetAllPoints()z.t:SetTexture(&Interface\\Icons\\ABILITY_DUALWIELD&)z:Hide() local function FrameOnUpdate(self) if UnitAffectingCombat(&target&) then self:Show() else self:Hide() end end local g = CreateFrame(&Frame&) g:SetScript(&OnUpdate&, function(self) FrameOnUpdate(z) end) y=CreateFrame(&Frame&)y:SetParent(FocusFrame)y:SetPoint(&Right&,FocusFrame,-11,9)y:SetSize(25,25)y.t=y:CreateTexture(nil,BORDER)y.t:SetAllPoints()y.t:SetTexture(&Interface\\Icons\\ABILITY_DUALWIELD&)y:Hide() local function FrameOnUpdate(self) if UnitAffectingCombat(&focus&) then self:Show() else self:Hide() end end local h = CreateFrame(&Frame&) h:SetScript(&OnUpdate&, function(self) FrameOnUpdate(y) end) [/code]
[img]./mon_/189_a6.jpg[/img]
比如有时候 你焦点目标盲了
有时候治疗加血 是把目标带进战斗 这就很好的帮助了你判断 要不要进行一个影舞闷棍 或者消失闷棍
在我的分辨率下()我发现上面的版本 会挡住一些东西
发现了吗?我通过修改 下面的 Left
19 19 来改变位置和大小 你也可以做出你自己的位置[code]z=CreateFrame(&Frame&)z:SetParent(TargetFrame)z:SetPoint(&Left&,TargetFrame,-16,-5)z:SetSize(19,19)z.t=z:CreateTexture(nil,BORDER)z.t:SetAllPoints()z.t:SetTexture(&Interface\\Icons\\ABILITY_DUALWIELD&)z:Hide() local function FrameOnUpdate(self) if UnitAffectingCombat(&target&) then self:Show() else self:Hide() end end local g = CreateFrame(&Frame&) g:SetScript(&OnUpdate&, function(self) FrameOnUpdate(z) end) y=CreateFrame(&Frame&)y:SetParent(FocusFrame)y:SetPoint(&Left&,FocusFrame,-16,-5)y:SetSize(19,19)y.t=y:CreateTexture(nil,BORDER)y.t:SetAllPoints()y.t:SetTexture(&Interface\\Icons\\ABILITY_DUALWIELD&)y:Hide() local function FrameOnUpdate(self) if UnitAffectingCombat(&focus&) then self:Show() else self:Hide() end end local h = CreateFrame(&Frame&) h:SetScript(&OnUpdate&, function(self) FrameOnUpdate(y) end)[/code] [img]./mon_/189_e0817.jpg[/img] 左下版本
[color=royalblue][size=150%][监视自身buff][/size][/color]--------------------------------------------------------------------------------------------------------bl 是技能ID 可以去魔兽世界数据库 点技能 打开的网页上面有技能ID第二行 bs 是图标大小 xb 是平行坐标 yb是垂直坐标 br是每行图标数量[code]bl={,,,32645}bs=30;xb=-10;yb=-50;br=4;bdr=&BORDER&be=&UNIT_AURA&cbf=CreateFgi=GetSpellIbm=math.fm=math.st=STANDARD_TEXT_FONT;function cu(s) return UnitBuff(&player&,gi(s))endfunction Cb(i,s)local _,_,t3=gi(s)local f=cbf(&Frame&)f:SetSize(bs,bs)f.t=f:CreateTexture(nil,bdr)f.t:SetAllPoints(true)f.t:SetTexture(t3)f.f=f:CreateFontString(nil,bdr)f.f:SetFont(st,12,&OUTLINE&)f.f:SetPoint(&BOTTOMRIGHT&,0,0)endfunction vb(s,i,row)local b1,_,_,b4=cu(s)local f=_G[&B&..i]if b1 then f:Show()f:SetPoint(&CENTER&,xb-(bs+5)*bm((row-1)%br),yb-(bs+10)*bm(row/br))if(b4&1)then f.f:SetText(b4)end row=row+1;endfunction ub()for i,s in ipairs(bl)do local b,_,_,_,_,_,k=cu(s)if b then local vt=fm(k-GetTime())if (vt&=60)then vt=bm(vt/60)_G[&B&..i].c:SetText(vt..&m&)elseif vt &= 0 then _G[&B&..i].c:SetText(vt..&s&)end end end endfunction Cc(f)f.c=f:CreateFontString(nil,bdr)f.c:SetFont(st,12,&OUTLINE&)f.c:SetPoint(&CENTER&,0,-20)end function db()for i in ipairs(bl)do _G[&B&..i]:Hide()end endfor i,s in ipairs(bl)do _G[&B&..i]=Cb(i,s)Cc(_G[&B&..i])_G[&B&..i]:Hide()end function bb()db()local bw=1;for i,s in ipairs(bl)do bw=vb(s,i,bw)end end bk=cbf(&Frame&)bk:SetScript(&OnEvent&,bb)bk:SetScript(&OnUpdate&,ub)bk:RegisterEvent(be)[/code] [img]./mon_/189_54.jpg[/img]
[color=royalblue][size=150%][目标buff debuff大小][/size][/color]------------------------------------------------------------------------------------------LARGE_AURA_SIZE = 是目标debuff的大小SMALL_AURA_SIZE = 目标buff大小[code]local function UpdateTargetAuraPositions(self, auraName, numAuras, numOppositeAuras, largeAuraList, updateFunc, maxRowWidth, offsetX)
local AURA_OFFSET_Y = 3;
local LARGE_AURA_SIZE = 30;
local SMALL_AURA_SIZE = 20;
local offsetY = AURA_OFFSET_Y;
local rowWidth = 0;
local firstBuffOnRow = 1;
for i=1, numAuras do
if ( largeAuraList[i] ) then
size = LARGE_AURA_SIZE;
offsetY = AURA_OFFSET_Y + AURA_OFFSET_Y;
size = SMALL_AURA_SIZE;
if ( i == 1 ) then
rowWidth =
self.auraRows = self.auraRows + 1;
rowWidth = rowWidth + size + offsetX;
if ( rowWidth & maxRowWidth ) then
updateFunc(self, auraName, i, numOppositeAuras, firstBuffOnRow, size, offsetX, offsetY);
rowWidth =
self.auraRows = self.auraRows + 1;
firstBuffOnRow =
offsetY = AURA_OFFSET_Y;
updateFunc(self, auraName, i, numOppositeAuras, i - 1, size, offsetX, offsetY);
hooksecurefunc(&TargetFrame_UpdateAuraPositions&, UpdateTargetAuraPositions) --[[crapcleaner]] local f = CreateFrame(&Frame&) f:SetScript(&OnEvent&, function()
local c = 0
for b=0,4 do
for s=1,GetContainerNumSlots(b) do
local l = GetContainerItemLink(b, s)
local p = select(11, GetItemInfo(l))*select(2, GetContainerItemInfo(b, s))
if select(3, GetItemInfo(l))==0 and p&0 then
UseContainerItem(b, s)
PickupMerchantItem()
if c&0 then
local g, s, c = math.floor(c/10000) or 0, math.floor((c%1) or 0, c%100
DEFAULT_CHAT_FRAME:AddMessage(&Your vendor trash has been sold and you earned&..& |cffffffff&..g..&|cffffc125g|r&..& |cffffffff&..s..&|cffc7c7cfs|r&..& |cffffffff&..c..&|cffeda55fc|r&..&.&,255,255,255)
--&Your vendor trash has been sold and you earned&
end end) f:RegisterEvent(&MERCHANT_SHOW&)[/code][img]./mon_/189_f.jpg[/img]
[color=royalblue][size=150%][在聊天窗口输入以下 显示竞技场框体 用来测试位置 也可做成宏][/size][/color]----------------------------------------------------------------------------------------[code]/run LoadAddOn(&Blizzard_ArenaUI&) ArenaEnemyFrames:Show() ArenaEnemyFrame1:Show() ArenaEnemyFrame2:Show() ArenaEnemyFrame3:Show() ArenaEnemyFrame1CastingBar:Show() ArenaEnemyFrame2CastingBar:Show() ArenaEnemyFrame3CastingBar:Show()[/code][color=royalblue][size=150%][移动竞技场框体][/size][/color]-----------------------------------------------------------------------------------------50 是平行坐标 -295应该是垂直坐标 但是我改了没效果[code]LoadAddOn(&Blizzard_ArenaUI&)ArenaEnemyFrame1:SetPoint(&TOPRIGHT&, -50, -295)ArenaEnemyFrame2:SetPoint(&TOPRIGHT&, -50, -295)ArenaEnemyFrame3:SetPoint(&TOPRIGHT&, -50, -295)ArenaEnemyFrame4:SetPoint(&TOPRIGHT&, -50, -295)ArenaEnemyFrame5:SetPoint(&TOPRIGHT&, -50, -295)[/code]
[color=royalblue][size=150%][屏蔽 浮动伤害 治疗][/size][/color]----------------------------------------------------------------------------------------[code]LoadAddOn(&Blizzard_CombatText&)COMBAT_TEXT_TYPE_INFO[&PERIODIC_HEAL&] = {var = nil, show = nil}COMBAT_TEXT_TYPE_INFO[&HEAL_CRIT&] = {var = nil, show = nil}COMBAT_TEXT_TYPE_INFO[&HEAL&] = {var = nil, show = nil}COMBAT_TEXT_TYPE_INFO[&PERIODIC_HEAL_ABSORB&] = {var = nil, show = nil}COMBAT_TEXT_TYPE_INFO[&HEAL_CRIT_ABSORB&] = {var = nil, show = nil}COMBAT_TEXT_TYPE_INFO[&HEAL_ABSORB&] = {var = nil, show = nil}COMBAT_TEXT_TYPE_INFO[&DAMAGE_CRIT&] = {var = nil, show = nil}COMBAT_TEXT_TYPE_INFO[&DAMAGE&] = {var = nil, show = nil}COMBAT_TEXT_TYPE_INFO[&SPELL_DAMAGE_CRIT&] = {var = nil, show = nil}COMBAT_TEXT_TYPE_INFO[&SPELL_DAMAGE&] = {var = nil, show = nil}[/code]有的人想只显示进入战斗 脱离战斗
就算在界面里 只点进入战斗 还是会显示 伤害和 治疗
这个就是屏蔽伤害和治疗的必须开启浮动文本 如下图[img]./mon_/189_505ab85d7f669.jpg[/img]
[color=royalblue][size=150%][屏蔽 中间红色错误提示][/size][/color]----------------------------------------------------------------------------------------[code]UIErrorsFrame:SetAlpha(0)[/code]
[color=royalblue][size=150%][目标 焦点 名称背景透明][/size][/color]----------------------------------------------------------------------------------------[code]local f=function(v)if(v&=1e4) then return ('%.1fk'):format(v/1e3):gsub('%.?0+([km])$','%1') else return v end end& && &hooksecurefunc(&TextStatusBar_UpdateTextString&,function(s)
& && &if not GetCVarBool(&statusTextPercentage&) then
& && &if s.TextString and s.currValue then
& && &s.TextString:SetText(f(s.currValue))& && && &
& & endend)local frame = CreateFrame(&FRAME&)frame:RegisterEvent(&PLAYER_ENTERING_WORLD&)frame:RegisterEvent(&PARTY_MEMBERS_CHANGED&)frame:RegisterEvent(&PLAYER_TARGET_CHANGED&)frame:RegisterEvent(&PLAYER_FOCUS_CHANGED&)frame:RegisterEvent(&UNIT_FACTION&)frame:RegisterEvent(&ARENA_OPPONENT_UPDATE&)frame:RegisterEvent(&PLAYER_CO***OL_GAINED&)frame:RegisterEvent(&PLAYER_CO***OL_LOST&)frame:RegisterEvent(&ADDON_LOADED&);
local function eventHandler(self, event, arg, ...)
if (event == &UNIT_FACTION& and arg ~= &target& and arg ~= &focus&) then return end
& && && &if UnitExists(&target&) then
TargetFrameNameBackground:SetVertexColor(0.0, 0.0, 0.0, 0.5)
if UnitExists(&focus&) then
FocusFrameNameBackground:SetVertexColor(0.0, 0.0, 0.0, 0.5)
endframe:SetScript(&OnEvent&, eventHandler)[/code] [img]./mon_/189_505b5d967efdf.jpg[/img][color=royalblue][size=150%][目标 焦点 名称 血量显示职业颜色][/size][/color]----------------------------------------------------------------------------------------[code]local UnitIsPlayer,UnitIsConnected, UnitClass, RAID_CLASS_COLORS = UnitIsPlayer,UnitIsConnected,UnitClass, RAID_CLASS_COLORSlocal _, class, clocal function colour(statusbar, unit, name)
if UnitIsPlayer(unit) and UnitIsConnected(unit) and unit == statusbar.unit and UnitClass(unit) then
_, class = UnitClass(unit) c = CUSTOM_CLASS_COLORS and CUSTOM_CLASS_COLORS[class] or RAID_CLASS_COLORS[class]
statusbar:SetStatusBarColor(c.r, c.g, c.b)& && &
statusbar = _G[&PlayerFrame&..&HealthBar&]:SetStatusBarColor(0.1, 1.0, 0.1)--playerframe fix& &
endhooksecurefunc(&UnitFrameHealthBar_Update&, colour)hooksecurefunc(&HealthBar_OnValueChanged&, function(self)colour(self, self.unit)end)local sb = _G.GameTooltipStatusBarlocal addon = CreateFrame(&Frame&, &StatusColour&)addon:RegisterEvent(&UPDATE_MOUSEOVER_UNIT&)addon:SetScript(&OnEvent&, function()colour(sb, &mouseover&) end)hooksecurefunc(&UnitFrame_Update&, function(self)
if UnitClass(self.unit) then
local c = (CUSTOM_CLASS_COLORS or RAID_CLASS_COLORS)[select(2,UnitClass(self.unit))]
self.name:SetTextColor(c.r,c.g,c.b,1) end end)[/code][color=royalblue][size=150%][盗贼控制剃减图标显示505新版][/size][/color]----------------------------------------------------------------------------------------我插件一直报lua 错误 一顿测试 测试了2个多小时 真崩溃
后来查看lua 错误 终于弄明白了原来这个 跟上面 Omnicc 的设置冲突
如果你开 显示LUA错误 你会发现这个跟上面Omincc冲突 建议别一起用 屏蔽插件错误 是可以 但是影响性能 这个版本跟neilyo 的一样 只是剃减结束后 自动隐藏 不显示了
neilyo 的是一直显示[code]USD=&UNIT_SPELLCAST_SUCCEEDED&;OT=&OnEvent&;FR=&Frame&;RF=CreateFRD=&Border&;UE=UnitNameCS=RF(FR) CS.c=RF(&Cooldown&,&CST&,CS.t) CS:RegisterEvent(USD)CS.c:SetAllPoints(CS) CS:SetPoint(&TOPRIGHT&,PlayerFrame,-2,4)CS:SetSize(22,22)CS:Hide()CS.t=CS:CreateTexture(nil,RD)CS.t:SetAllPoints()CS.t:SetTexture(&Interface\\Icons\\ability_cheapshot&)CS:SetScript(OT,function(self,event,...)if UE(select(1,...))==UE(&player&)and select(5,...)==1833 then CST:SetCooldown(GetTime(),23)CS:Show()CS.elapsed = 0 CS:SetScript('OnUpdate', function(self, elapsed)if self.elapsed & 24 then self:SetScript('OnUpdate', nil) self:Hide() else self.elapsed = self.elapsed + elapsed end end)end if UE(select(1,...))==UE(&player&)and select(5,...)==408 then CST:SetCooldown(GetTime(),25)CS:Show() CS.elapsed = 0 CS:SetScript('OnUpdate', function(self, elapsed)if self.elapsed & 26 then self:SetScript('OnUpdate', nil) self:Hide()else self.elapsed = self.elapsed + elapsed end end)end end)SP=RF(FR) SP.c=RF(&Cooldown&,&SAP&,SP.t) SP:RegisterEvent(USD) SP.c:SetAllPoints(SP) SP:SetPoint(&TOPRIGHT&,PlayerFrame,-25,4)SP:Hide()SP:SetSize(22,22)SP.t=SP:CreateTexture(nil,RD)SP.t:SetAllPoints()SP.t:SetTexture(&Interface\\Icons\\ability_sap&)SP:SetScript(OT,function(self,event,...)if UE(select(1,...))==UE(&player&)and select(5,...)==6770 then SAP:SetCooldown(GetTime(),27)SP:Show()SP.elapsed = 0 SP:SetScript('OnUpdate', function(self, elapsed)if self.elapsed & 28 then self:SetScript('OnUpdate', nil) self:Hide()else self.elapsed = self.elapsed + elapsed end end)end if UE(select(1,...))==UE(&player&)and select(5,...)==1776 then SAP:SetCooldown(GetTime(),23)SP:Show()SP.elapsed = 0 SP:SetScript('OnUpdate', function(self, elapsed)if self.elapsed & 24 then self:SetScript('OnUpdate', nil) self:Hide()else self.elapsed = self.elapsed + elapsed end end)end end)GR=RF(FR) GR.c=RF(&Cooldown&,&GAR&,GR.t)
GR.c:SetAllPoints(GR) GR:SetPoint(&TOPRIGHT&,PlayerFrame,-47,4)GR:Hide()GR:SetSize(22,22)GR.t=GR:CreateTexture(nil,RD)GR.t:SetAllPoints()GR.t:SetTexture(&Interface\\Icons\\ability_Rogue_Garrote&)GR:SetScript(OT,function(self,event,...)if UE(select(1,...))==UE(&player&)and select(5,...)==703 then GAR:SetCooldown(GetTime(),23)GR:Show()GR.elapsed = 0 GR:SetScript('OnUpdate', function(self, elapsed)if self.elapsed & 24 then self:SetScript('OnUpdate', nil) self:Hide()else self.elapsed = self.elapsed + elapsed end end)end end) GR:RegisterEvent(USD)[/code][img]./mon_/189_505b.jpg[/img]=== 18:12===发现个牛B产物,,,去掉被控制后 技能栏转圈 [code]local f=CreateFrame(&Frame&) f:RegisterEvent(&LOSS_OF_CO***OL_ADDED&) f:RegisterEvent(&LOSS_OF_CO***OL_UPDATE&) f:SetScript(&OnEvent&,function() for b in pairs(ActionBarActionEventsFrame.frames) do b.cooldown:SetLossOfControlCooldown(0,0) end end)[/code]
楼主好人!另外楼主能否传张你的界面截图上来做参考啊啊啊!
感觉很不错的样子,能不能上个图看看效果呢,感谢
[b]Reply to [pid=]Reply[/pid] Post by 抹浅浅 ( 10:27)[/b]这是我的界面 没啥特别的
修改了监视竞技场框体徽章
职业图标 血量以K为单位 分辨率我主要的目的是给大家提供一个素材的平台
我一直很喜欢 Hoodrych 那个战士的界面
有机会我会尝试一下
他改的东西几乎帖子里都有提到 [img]./mon_/189_cfa.jpg[/img]
下面这个是 hoodrych 的界面 一直我比较喜欢
他的改动 自己头像 目标头像 改大
焦点目标施法条在上面
目标的目标头像在右边
竞技场框体改大
[img]./mon_/189_5057e3fbb20ac.jpg[/img]
mark 楼主好人,教学也很简便,多些命令就好了
有分量的技術貼,我這萬年潛水也要來頂下了
楼主我语文老师死得早,能详细点吗?“比如 autoexec 在这里面建立2个文件 分别是autoexec.tocautoexec.luaautoexec.toc 文件内容## Interface: 50001 (版本号 这个就是解决插件过期的问题 但是里面的参数不是最新的话 有时候会报错 所以也不是说改个版本号就完美兼容了)
## Title: Autoexec ( 插件名)## Notes: Automatically runs scripts on loginAutoexec.lua (意思是 载入 Autoexec.lua )”这需要新建一个TXT文档把下面文件内容复制进去再把TXT文档名称改成autoexec.toc吗?再有就是第二个文件autoexec.lua,应该怎么设置呢,可能你觉得挺简单不用说的太详细,但是,世间上还是有我这样理解动手能力差的人。抱歉打扰,能详细说说吗?
LZ最近发的技术贴都很好啊支持昨晚在另外以为大神帮助下搞定了TF-&GF血量以K显示 准备试试
[b]Reply to [pid=]Reply[/pid] Post by 潜水教主 ( 16:19)[/b]是的 可以在txt中编辑 你也可以改完文件名后 右键 用记事本 也就是txt打开编辑 LUA 格式的这个文件里 就是放插件内容了
比如我发出来的
从帖子开头的 [我自己的设置] 开始把code 代码 复制进去
比如[code]local frame = CreateFrame(&Frame&) frame:RegisterEvent(&PLAYER_LOGIN&) frame:RegisterEvent(&ADDON_LOADED&) frame:RegisterEvent(&PLAYER_ENTERING_WORLD&) SLASH_AF1 = &/af& local function eventHandler(self,event,arg1)
if event == &PLAYER_LOGIN& then
TargetFrameToT:ClearAllPoints()
TargetFrameToT:SetPoint(&BOTTOMRIGHT&,TargetFrame,-15,-10)
FocusFrameToT:ClearAllPoints()
FocusFrameToT:SetPoint(&BOTTOMRIGHT&,FocusFrame,-15,-10)
FocusFrameSpellBar:SetScale(1.1)
TargetFrameSpellBar:SetScale(1.1)
MainMenuBarLeftEndCap:Hide()
MainMenuBarRightEndCap:Hide()
UIErrorsFrame:UnregisterEvent(&UI_ERROR_MESSAGE&)
end end frame:SetScript(&OnEvent&,eventHandler) [/code]中间的参数说明 我已经写在帖子里了 有看到吗?把你不想要的功能 一行一行的删除
把你想要的功能 一行一行的加入进来有的功能是需要 一行一行加的 比如
FocusFrameSpellBar:SetScale(1.1)
TargetFrameSpellBar:SetScale(1.1) 这样的命令
是单一的宏命令 focus 等于焦点目标
target 等于目标 改到1.1倍大像后边 乱七八糟开头的
以 end 结尾的
一般都是 插件式命令
直接附近 到 LUA文件的最下面 比如这个[职业头像修改 不包括NPC][code]hooksecurefunc(&UnitFramePortrait_Update&,function(self)
if self.portrait then
if UnitIsPlayer(self.unit) then
local t = CLASS_ICON_TCOORDS[select(2, UnitClass(self.unit))]
self.portrait:SetTexture(&Interface\\TargetingFrame\\UI-Classes-Circles&)
self.portrait:SetTexCoord(unpack(t))
self.portrait:SetTexCoord(0,1,0,1)
end end) [/code]这么说你能明白了吗?
mark下,回去仔细研究,露珠长命百岁!
不错的学习帖。
为毛我血量以K显示的有,然后焦点施法条在上面显示的就不行呢?? [s:30]
[quote][pid=]Reply[/pid] [b]Post by forever_涩琪 ( 19:51):[/b]为毛我血量以K显示的有,然后焦点施法条在上面显示的就不行呢?? [s:30][/quote]把焦点施法条在上面命令FocusFrameSpellBar:ClearAllPoints() FocusFrameSpellBar:SetPoint(&TOPLEFT&,FocusFrame,&TOPLEFT&,15,6) FocusFrameSpellBar.SetPoint = function() end放在 帖子里第一个代码
[我自己的设置] 中间[code]local frame = CreateFrame(&Frame&) frame:RegisterEvent(&PLAYER_LOGIN&) frame:RegisterEvent(&ADDON_LOADED&) frame:RegisterEvent(&PLAYER_ENTERING_WORLD&) SLASH_AF1 = &/af& local function eventHandler(self,event,arg1)
if event == &PLAYER_LOGIN& then
TargetFrameToT:ClearAllPoints()
TargetFrameToT:SetPoint(&BOTTOMRIGHT&,TargetFrame,-15,-10)
FocusFrameToT:ClearAllPoints()
FocusFrameToT:SetPoint(&BOTTOMRIGHT&,FocusFrame,-15,-10)
FocusFrameSpellBar:SetScale(1.1)
TargetFrameSpellBar:SetScale(1.1)
MainMenuBarLeftEndCap:Hide()
MainMenuBarRightEndCap:Hide()
UIErrorsFrame:UnregisterEvent(&UI_ERROR_MESSAGE&)
end end frame:SetScript(&OnEvent&,eventHandler)[/code]比如
我帮你改好后的[code]local frame = CreateFrame(&Frame&) frame:RegisterEvent(&PLAYER_LOGIN&) frame:RegisterEvent(&ADDON_LOADED&) frame:RegisterEvent(&PLAYER_ENTERING_WORLD&) SLASH_AF1 = &/af& local function eventHandler(self,event,arg1)
if event == &PLAYER_LOGIN& then
TargetFrameToT:ClearAllPoints()
TargetFrameToT:SetPoint(&BOTTOMRIGHT&,TargetFrame,-15,-10)
FocusFrameToT:ClearAllPoints()
FocusFrameToT:SetPoint(&BOTTOMRIGHT&,FocusFrame,-15,-10)
FocusFrameSpellBar:SetScale(1.1)
TargetFrameSpellBar:SetScale(1.1)
MainMenuBarLeftEndCap:Hide()
MainMenuBarRightEndCap:Hide()
UIErrorsFrame:UnregisterEvent(&UI_ERROR_MESSAGE&)
FocusFrameSpellBar:ClearAllPoints()
FocusFrameSpellBar:SetPoint(&TOPLEFT&,FocusFrame,&TOPLEFT&,15,6)
FocusFrameSpellBar.SetPoint = function() end
end end frame:SetScript(&OnEvent&,eventHandler)[/code]会了吗?
简单的命令要加在中间复杂的乱码格式
[img]http://img.ngacn.cc/attachments/mon_/-bc80140e3.png[/img] 参照这个帖子把[url=http://bbs.ngacn.cc/read.php?tid=4671136&page=1][分享] BLIZZCON 欧美各队使用的脚本(Scripts)[/url]
我有看这个帖子 我里面很多也是借鉴的
但是我发现命令不全 这是我开这个帖子的目的
而且这里面有很多现在不能用的了 比如bt动作条框体
发几个自己的LUA 也是从别的帖子里面拿来的 有需要的可以拿去用-------递减图标监视USD=&UNIT_SPELLCAST_SUCCEEDED&;OT=&OnEvent&;FR=&Frame&;RF=CreateFRD=&Border&;UE=UnitName CS=RF(FR) CS.c=RF(&Cooldown&,&CST&,CS.t) CS:RegisterEvent(USD) CS.c:SetAllPoints(CS) CS:SetPoint(&TOPRIGHT&,PlayerFrame,-2,4)CS:SetSize(22,22)CS.t=CS:CreateTexture(nil,RD)CS.t:SetAllPoints()CS.t:SetTexture(&Interface\\Icons\\ability_cheapshot&) CS:SetScript(OT,function(self,event,...) if UE(select(1,...))==UE(&player&) and select(5,...)==1833 then CST:SetCooldown(GetTime(), 23)end if UE(select(1,...))==UE(&player&) and select(5,...)==408 then CST:SetCooldown(GetTime(), 25) end end) SP=RF(FR) SP.c=RF(&Cooldown&,&SAP&,SP.t) SP:RegisterEvent(USD) SP.c:SetAllPoints(SP) SP:SetPoint(&TOPRIGHT&,PlayerFrame,-21,4)SP:SetSize(22,22)SP.t=SP:CreateTexture(nil,RD)SP.t:SetAllPoints()SP.t:SetTexture(&Interface\\Icons\\ability_sap&) SP:SetScript(OT,function(self,event,...) if UE(select(1,...))==UE(&player&) and select(5,...)==6770 then SAP:SetCooldown(GetTime(), 27)end if UE(select(1,...))==UE(&player&) and select(5,...)==1776 then SAP:SetCooldown(GetTime(), 23) end end) GR=RF(FR) GR.c=RF(&Cooldown&,&GARROTE&,GR.t) GR:RegisterEvent(USD) GR.c:SetAllPoints(GR) GR:SetPoint(&TOPRIGHT&,PlayerFrame,-40,4)GR:SetSize(22,22)GR.t=GR:CreateTexture(nil,RD)GR.t:SetAllPoints()GR.t:SetTexture(&Interface\\Icons\\ability_Rogue_Garrote&) GR:SetScript(OT,function(self,event,...) if UE(select(1,...))==UE(&player&) and select(5,...)==703 then GARROTE:SetCooldown(GetTime(), 23)end if UE(select(1,...))==UE(&player&) and select(5,...)==102926 then GARROTE:SetCooldown(GetTime(), 20) end end)-------自动出售垃圾local f = CreateFrame(&Frame&)f:SetScript(&OnEvent&, function()
local c = 0
for b=0,4 do
for s=1,GetContainerNumSlots(b) do
local l = GetContainerItemLink(b, s)
local p = select(11, GetItemInfo(l))*select(2, GetContainerItemInfo(b, s))
if select(3, GetItemInfo(l))==0 and p&0 then
UseContainerItem(b, s)
PickupMerchantItem()
if c&0 then
local g, s, c = math.floor(c/10000) or 0, math.floor((c%1) or 0, c%100
DEFAULT_CHAT_FRAME:AddMessage(&Your vendor trash has been sold and you earned&..& |cffffffff&..g..&|cffffc125g|r&..& |cffffffff&..s..&|cffc7c7cfs|r&..& |cffffffff&..c..&|cffeda55fc|r&..&.&,255,255,255)
--&Your vendor trash has been sold and you earned&可以更改成中文,改好用UTF-8格式保存即可
endend)f:RegisterEvent(&MERCHANT_SHOW&)-------Tab切换聊天频道function ChatEdit_CustomTabPressed(self)
if strsub(tostring(self:GetText()), 1, 1) == &/& then return end
(self:GetAttribute(&chatType&) == &SAY&)
if (GetNumPartyMembers()&0) then
self:SetAttribute(&chatType&, &PARTY&);
ChatEdit_UpdateHeader(self);
elseif (GetNumRaidMembers()&0) then
self:SetAttribute(&chatType&, &RAID&);
ChatEdit_UpdateHeader(self);
elseif (GetNumBattlefieldScores()&0) then
self:SetAttribute(&chatType&, &BATTLEGROUND&);
ChatEdit_UpdateHeader(self);
elseif (IsInGuild()) then
self:SetAttribute(&chatType&, &GUILD&);
ChatEdit_UpdateHeader(self);
elseif (self:GetAttribute(&chatType&) == &PARTY&) then
if (GetNumRaidMembers()&0) then
self:SetAttribute(&chatType&, &RAID&);
ChatEdit_UpdateHeader(self);
elseif (GetNumBattlefieldScores()&0) then
self:SetAttribute(&chatType&, &BATTLEGROUND&);
ChatEdit_UpdateHeader(self);
elseif (IsInGuild()) then
self:SetAttribute(&chatType&, &GUILD&);
ChatEdit_UpdateHeader(self);
self:SetAttribute(&chatType&, &SAY&);
ChatEdit_UpdateHeader(self);
elseif (self:GetAttribute(&chatType&) == &RAID&) then
if (GetNumBattlefieldScores()&0) then
self:SetAttribute(&chatType&, &BATTLEGROUND&);
ChatEdit_UpdateHeader(self);
elseif (IsInGuild()) then
self:SetAttribute(&chatType&, &GUILD&);
ChatEdit_UpdateHeader(self);
self:SetAttribute(&chatType&, &SAY&);
ChatEdit_UpdateHeader(self);
elseif (self:GetAttribute(&chatType&) == &BATTLEGROUND&) then
if (IsInGuild) then
self:SetAttribute(&chatType&, &GUILD&);
ChatEdit_UpdateHeader(self);
self:SetAttribute(&chatType&, &SAY&);
ChatEdit_UpdateHeader(self);
elseif (self:GetAttribute(&chatType&) == &GUILD&) then
self:SetAttribute(&chatType&, &SAY&);
ChatEdit_UpdateHeader(self);
[b]Reply to [pid=]Reply[/pid] Post by 太孤独 ( 19:57)[/b]3克,3克,还是看帖不仔细啊,,多谢啦, [s:27]
随便问一下,我想放上面去点是不是改那个6?
好像很高端的样子。。我么这种代码文盲还是算了吧
楼主对不起,小弟太笨了
我按照楼主的回复还是没搞明白,是把文件建好了进游戏就可以自动显示了吗?还是需要进游戏/RUN一下呢?我想让楼主帮我做个头像变成职业图标的那个命令文件发给我可以吗?我自己对照着你做的研究一下,不好意思做伸手党,希望楼主能教教我

参考资料

 

随机推荐