-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathcave_target_on_off.lua
35 lines (32 loc) · 1.01 KB
/
cave_target_on_off.lua
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
-- TOGGLE ICONS FOR CAVEBOT AND TARGETBOT
-- vBot Scripting Services: F.Almeida#8019
local cIcon = addIcon("cI",{text="Cave\nBot",switchable=false,moveable=true}, function()
if CaveBot.isOff() then
CaveBot.setOn()
else
CaveBot.setOff()
end
end)
cIcon:setSize({height=30,width=50})
cIcon.text:setFont('verdana-11px-rounded')
local tIcon = addIcon("tI",{text="Target\nBot",switchable=false,moveable=true}, function()
if TargetBot.isOff() then
TargetBot.setOn()
else
TargetBot.setOff()
end
end)
tIcon:setSize({height=30,width=50})
tIcon.text:setFont('verdana-11px-rounded')
macro(50,function()
if CaveBot.isOn() then
cIcon.text:setColoredText({"CaveBot\n","white","ON","green"})
else
cIcon.text:setColoredText({"CaveBot\n","white","OFF","red"})
end
if TargetBot.isOn() then
tIcon.text:setColoredText({"Target\n","white","ON","green"})
else
tIcon.text:setColoredText({"Target\n","white","OFF","red"})
end
end)