I've been using Whisp for awhile now for the simple function of having my whisper history with a person displayed above the chat window when I'm typing a whisper to them. It's been slowly dying with each patch and it's now come to the point where the addon doesn't function at all. Is there a similar addon that doesn't have a ton of other unecessary features? I don't want something like WIM that breaks it all out, as I have enough trouble monitoring one chat window and I don't often carry on more than one conversation at a time.
I've been using Prat for everything else chat related (although at the moment none of the modules I use work in that either :P), so compatability is a must. The only exception would be if it could completely replace Prat and equal it's performance and compatability with other chat addons. I'd need button removal, copy options, chat entry replacement, and hot key options minimally.
I tried an initial search but didn't find anything.
I don't want something like WIM that breaks it all out, as I have enough trouble monitoring one chat window and I don't often carry on more than one conversation at a time.
Unfortunately, that still breaks whispers out from guild, party, general, spam... err trade, etc.
All I want is the previous whispers to/from the person I'm currently typing a tell to to appear above the chat window. Here's the addon I was using: http://wow.curseforge.com/addons/anea-whisp/
It looks a little different in my implementation because my edit box is on top (or will be, when Prat is fixed :P).
EDIT: nevermind previous edit, I gets an error. Same error a lot of chat addons are giving me.
1x Whisp-20091213\modules\EditboxPlugin.lua:92: attempt to index global 'ChatFrameEditBox' (a nil value)
CallbackHandler-1.0-5:146: in function <...ags\libs\CallbackHandler-1.0\CallbackHandler-1.0.lua:146>
<string>:"safecall Dispatcher[1]":4: in function <[string "safecall Dispatcher[1]"]:4>
<in C code>: ?
<string>:"safecall Dispatcher[1]":13: in function `?'
CallbackHandler-1.0-5:91: in function `SendMessage'
Whisp-20091213\core.lua:115: in function <Whisp\core.lua:113>
<string>:"safecall Dispatcher[14]":4: in function <[string "safecall Dispatcher[14]"]:4>
<in C code>: ?
<string>:"safecall Dispatcher[14]":13: in function `?'
CallbackHandler-1.0-5:91: in function `Fire'
AceEvent-3.0-3 (AdiBags):120: in function `OnEvent'
StopAddonMessage-1.4.1beta\core.lua:277: in function <StopAddonMessage\core.lua:210>
(tail call): ?:
---
What did they rename the chatbox frame, maybe I can fix it?
EDIT2:
Ok, so ChatFrameEditBox has become ChatFrame1EditBox. And a replace all on the appropriate module fixed the addon. Except the new chat interface has sticky channels and it doesn't turn off after typing! Now I gotta figure out how to disable those. Maybe classic chat mode.
EDIT3:
So I figured it out. The Whisp frame is attached to the edit box. In the new "IM" mode, it never hides, so Whisp doesn't hide. In the classic mode, the edit box hides when you hit enter, so so does Whisp.
Both modes feature sticky channels... I need to figure out how to get rid of that or I'm gonna end up cybering with the wrong girlfriends.
Well if you're brave enough try taking a look at that. I haven't looked at any of the code for it, but I'd like to hope it was as simple as adding in an OR with the RealID whisper event # with the normal whisper event history recording.
I have it mostly updated already including realID etc but again I can't post it because even though I am an author on it it won't authorize my patch. I will do a couple other quick fixes (that appeared last night) and just post a totally new version again.
Yeah that seems to be a problem with LibUTF8 not liking the space in people real names (I think) so I have disabled the conversion for now which could possibly cause problems with special chars in names. But I believe WOW SV are in UTF8 format now so I can probably remove that code. Currently testing.
function Whisp:BNChatEventIncoming(msg, plr, id)
Whisp:UpdateChatHistory(msg, plr, plr, true)
Whisp:SendMessage("WHISP_MESSAGE")
end
function Whisp:BNChatEventOutgoing(msg, plr, id)
Whisp:UpdateChatHistory(msg, plr, UnitName("player"), false)
Whisp:SendMessage("WHISP_MESSAGE")
end
function Whisp:UpdateChatHistory(msg, plr, snd, incoming, info)
if not plr then return end
if Whisp:HideAddonMessage(msg, plr) then return end
--plr = Whisp:ToName(plr)
--snd = Whisp:ToName(snd)
if snd == UnitName("player") then Whisp.sincereply = 0
else Whisp.sincereply = Whisp.sincereply + 1 end
-- Update player class cache
local localizedClass, class, localizedRace, englishRace, sex
if info then localizedClass, class, localizedRace, englishRace, sex = GetPlayerInfoByGUID(info) end
Whisp.db.realm.playerClass[plr] = class
Whisp.lastSender = plr
-- Insert new message
if not Whisp.db.realm.chatHistory[plr] then
Whisp.db.realm.chatHistory[plr] = {sender = {}, message = {}, time = {}, incoming = {}}
end
tinsert(Whisp.db.realm.chatHistory[plr].sender, snd)
tinsert(Whisp.db.realm.chatHistory[plr].message, msg)
tinsert(Whisp.db.realm.chatHistory[plr].incoming, incoming)
tinsert(Whisp.db.realm.chatHistory[plr].time, time())
end
local nameCache = {}
setmetatable(nameCache, {__mode = "kv"})
-- Normalise a name to capital-lower format, pick name from cache if available
function Whisp:ToName(plr)
if not nameCache[plr] then
nameCache[plr] = strutf8upper(strutf8sub(plr, 1,1))..strutf8lower(strutf8sub(plr,2))
end
return nameCache[plr] or plr
end
If I comment out the calls to Whisp:ToName() all is fine but if I let them go through any BNET name (first last) always ends up returning plr as something like f8000000. May not be UTF8 but I am not real good with metatables either *whistles*
Why do you need to do any capitalization? The names passed with chat events should already be correctly formatted.
If you're allowing users to manually type in names (the only situation where you should need to fix capitalization), you should just get rid of the ToName function entirely, use direct lookups in nameCache instead (eg. myVar = nameCache[plr]), and change your metatable to this:
local nameCache = setmetatable({}, { __index = function(self, name)
if name == nil then
-- something is wrong with your code, and you're trying to index a nil value
return ""
end
local result
if name:match("%s") then
-- there's a space in it, so it's a Battle.net first/last name
local first, last = name:match("^(.+)%s(.+)$")
result = first:utf8sub(1, 1):utf8upper() .. first:utf8sub(2):utf8lower() .. " " .. last:utf8sub(1, 1):utf8upper() .. last:utf8sub(2):utf8lower()
else
-- there's no space, so it's a WoW character name
result = name:utf8sub(1, 1):utf8upper() .. name:utf8sub(2):utf8lower()
end
self[name] = result
return result
end })
You don't need to worry about garbage-collecting your table entries (setting your metatable __mode to "kv" enables garbage collection on the keys and values in your table) since you're not dealing with potentially hundreds of thousands of entries, like RatingBuster is. In any given session, it's unlikely you'll exchange whispers with more than a few dozen people.
I've been using Prat for everything else chat related (although at the moment none of the modules I use work in that either :P), so compatability is a must. The only exception would be if it could completely replace Prat and equal it's performance and compatability with other chat addons. I'd need button removal, copy options, chat entry replacement, and hot key options minimally.
I tried an initial search but didn't find anything.
Thanks!
WIM has a tabbed mode. See here for instructions on enabling it:
http://www.wimaddon.com/wiki/WIM:Frequently_Asked_Questions
All I want is the previous whispers to/from the person I'm currently typing a tell to to appear above the chat window. Here's the addon I was using: http://wow.curseforge.com/addons/anea-whisp/
It looks a little different in my implementation because my edit box is on top (or will be, when Prat is fixed :P).
EDIT: nevermind previous edit, I gets an error. Same error a lot of chat addons are giving me.
1x Whisp-20091213\modules\EditboxPlugin.lua:92: attempt to index global 'ChatFrameEditBox' (a nil value)
CallbackHandler-1.0-5:146: in function <...ags\libs\CallbackHandler-1.0\CallbackHandler-1.0.lua:146>
<string>:"safecall Dispatcher[1]":4: in function <[string "safecall Dispatcher[1]"]:4>
<in C code>: ?
<string>:"safecall Dispatcher[1]":13: in function `?'
CallbackHandler-1.0-5:91: in function `SendMessage'
Whisp-20091213\core.lua:115: in function <Whisp\core.lua:113>
<string>:"safecall Dispatcher[14]":4: in function <[string "safecall Dispatcher[14]"]:4>
<in C code>: ?
<string>:"safecall Dispatcher[14]":13: in function `?'
CallbackHandler-1.0-5:91: in function `Fire'
AceEvent-3.0-3 (AdiBags):120: in function `OnEvent'
StopAddonMessage-1.4.1beta\core.lua:277: in function <StopAddonMessage\core.lua:210>
(tail call): ?:
---
What did they rename the chatbox frame, maybe I can fix it?
EDIT2:
Ok, so ChatFrameEditBox has become ChatFrame1EditBox. And a replace all on the appropriate module fixed the addon. Except the new chat interface has sticky channels and it doesn't turn off after typing! Now I gotta figure out how to disable those. Maybe classic chat mode.
EDIT3:
So I figured it out. The Whisp frame is attached to the edit box. In the new "IM" mode, it never hides, so Whisp doesn't hide. In the classic mode, the edit box hides when you hit enter, so so does Whisp.
Both modes feature sticky channels... I need to figure out how to get rid of that or I'm gonna end up cybering with the wrong girlfriends.
1) Run a search and replace in EditBoxPlugin.lua. Search for ChatFrameEditBox and replace it with ChatFrame1EditBox.
2) Switch to the classic chat mode -or- use a mod such as Prat to disable sticky chat for whispers.
I'm getting no further issues with Whisp after that.
First the BN events:
If I comment out the calls to Whisp:ToName() all is fine but if I let them go through any BNET name (first last) always ends up returning plr as something like f8000000. May not be UTF8 but I am not real good with metatables either *whistles*
If you're allowing users to manually type in names (the only situation where you should need to fix capitalization), you should just get rid of the ToName function entirely, use direct lookups in nameCache instead (eg. myVar = nameCache[plr]), and change your metatable to this:
You don't need to worry about garbage-collecting your table entries (setting your metatable __mode to "kv" enables garbage collection on the keys and values in your table) since you're not dealing with potentially hundreds of thousands of entries, like RatingBuster is. In any given session, it's unlikely you'll exchange whispers with more than a few dozen people.