diff Main.lua @ 13:cc98f28b1c7c tip

remove geradd message fix issue with -- add support for console commands
author Jay Bird <a4blank@yahoo.com>
date Thu, 13 Jan 2011 20:50:34 +0300
parents d2cbfe498c4d
children
line wrap: on
line diff
--- a/Main.lua	Sat Dec 04 05:53:52 2010 +0300
+++ b/Main.lua	Thu Jan 13 20:50:34 2011 +0300
@@ -304,12 +304,15 @@
     local channel = self:GetDefaultChatChannel()
     if channel then
         for _, data in ipairs(self:GetFormData()) do
-            local str = table.concat(data, " — ")
+            local str = data.icon
+            if data.action then
+              str = str .. " — " .. data.action
+            end
+            if data.player then
+              str = str .. " — " .. data.player
+            end
             SendChatMessage(str, channel)
         end
-        if UnitName("player") == "Герадд" then
-            SendChatMessage("Герадд любит тебя!", channel)
-        end
     end
 end