i need like a Commandbox
for an autoit script
i got me something but it doesnt seem to work could anybody pleas check why itt doenst work
pleas fix it cause i really need it
code of KiLLer.toc
Code:
## Interface: 24100
## Title: KiLLer's Commandbox
## Notes: KiLLer's Commandbox Addon For Auto assist Server
## DefaultState: enabled
KiLLer.xml
code of KiLLer.xml
Code:
<Ui xmlns="http://www.blizzard.com/wow/ui/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.blizzard.com/wow/ui/ ..FrameXMLUI.xsd">
<Script file="KiLLer.lua"/>
<Frame name="KiLLer_frame" parent="UIParent">
<Size><AbsDimension x="10" y="10"/></Size>
<Anchors>
<Anchor point="TOPLEFT" relativeTo="UIParent"/>
</Anchors>
<Layers>
<Layer level="OVERLAY">
<Texture name="KiLLer_color">
<Color r="0.0" g="0.0" b="0.0" a="1.0"/>
</Texture>
</Layer>
</Layers>
<Scripts>
<OnLoad>
KiLLer.OnLoad();
KiLLer_color.TimeSinceLastUpdate = 0
</OnLoad>
<OnEvent>
KiLLer_Event()
</OnEvent>
</Scripts>
</Frame>
</Ui>
code of KiLLer.lua
Code:
KiLLer_update_time = 2.5;
function KiLLer.OnLoad()
this:RegisterEvent("PLAYER_DEAD");
this:RegisterEvent("PLAYER_ALIVE");-- shouldnt be the case but he who knows
this:RegisterEvent("PLAYER_UNGHOST");
this:RegisterEvent("PLAYER_REGEN_DISABLED");
this:RegisterEvent("PLAYER_REGEN_ENABLED");
this:RegisterEvent("PLAYER_TARGET_CHANGED");
this:RegisterEvent("PLAYER_FLAGS_CHANGED");
DEFAULT_CHAT_FRAME:AddMessage("KiLLer Addon loaded.");
end
function KiLLer_update(elapsed)
KiLLer_color.TimeSinceLastUpdate = KiLLer_color.TimeSinceLastUpdate + elapsed;
if (KiLLer_color.TimeSinceLastUpdate > KiLLer_update_time) then
KiLLer_color:SetTexture(0, 0, 0)
KiLLer_color.TimeSinceLastUpdate = 0;
end
end
function KiLLer_Event()
if (event == "PLAYER_DEAD") then
KiLLer_color:SetTexture(255, 255, 255)
elseif (event == "PLAYER_ALIVE") then
KiLLer_color:SetTexture(100, 100, 100)
elseif (event == "PLAYER_UNGHOST") then
KiLLer_color:SetTexture(0, 0, 0)
elseif (event == "PLAYER_REGEN_DISABLED") then
KiLLer_color:SetTexture(255, 0, 0)
elseif (event == "PLAYER_REGEN_ENABLED") then
KiLLer_color:SetTexture(0, 0, 0)
elseif (event == "PLAYER_TARGET_CHANGED") then
KiLLer_color:SetTexture(0, 0, 255)
elseif (event == "PLAYER_FLAGS_CHANGED") then
KiLLer_color:SetTexture(0, 0, 0)
end
end