Re: [問題] UI問題
※ [本文轉錄自 WOW 看板 #1CK1YSYP ]
作者: wa007123456 (大笨羊) 看板: WOW
標題: Re: [問題] UI問題
時間: Wed Jul 28 19:46:32 2010
: function AutoText:OnEnable()
: --[[ Store the last person to send us a whisper for use in the REPLY
: pseudo-target ]]
: self:RegisterEvent("CHAT_MSG_WHISPER", function() lastWhisperSentBy =
: arg2 end)
: end
: 請問是要修改這邊嗎
這裡的確有問題 lastWhisperSentBy 的值依然是nil
所以我把他改寫成
......
self:RegisterEvent("CHAT_MSG_WHISPER")
.......
function AutoText:CHAT_MSG_WHISPER(controller, event, sender)
lastWhisperSentBy=sender;
end
: 關於Unable to reply. Nobody has whispered you!的
: --[[ Convert pseudo-targets into real targets ]]
: if chatType == "TARGET" then
: chatType = "WHISPER"
: channel = UnitName("target")
: elseif chatType == "REPLY" then
: if self.lastWhisperSentBy then
: chatType = "WHISPER"
: channel = self.lastWhisperSentBy
: else
: self:Print("Unable to reply. Nobody has whispered you!")
: return
: end
這裡我真的很困惑....我已經弄了6.5個小時了..有再selfPrint(...)下面加入
print(lastWhisperSentBy); 名字有出來(而且還是中文)
但是不知道為什麼區塊會判定他是nil
我快要被這個UI弄到發瘋了 囧 (看來我只不過是個UI新手...)
我在追求db物件的數值 但是Debug得非常痛苦
只知道大概有幾個物件 模糊的運作原理
希望有高手相助
這是這UI的官方網站:http://wow.curseforge.com/addons/autotext/
上面有完整的UI內容
懸賞3500p!!
希望有大大可以讓這個UI的密語自動回話恢復
然後如果可以的話@@ 順便講一下原理(自動回話那部份就好)
感謝...
ps:在這個UI當中我發現了一個有趣的連鎖反應
當自己密語自己的時候 如果我讓他自動回話
便會產生一個無窮迴圈 但是 並不會造成電腦當機
因為他會依照時間慢慢的發送訊息 好像可以用來掛網
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 125.228.226.212
※ 編輯: wa007123456 來自: 125.228.226.212 (07/28 19:48)
→
07/28 20:01,
07/28 20:01
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 125.228.226.212
Programming 近期熱門文章
PTT數位生活區 即時熱門文章