Without doing further testing, it looks like lines 649-652 of GCGambler.lua are the problem:
Code:
function GCGambler_EditBox_OnLoad()
GCGambler_EditBox:SetNumeric("true");
GCGambler_EditBox:SetAutoFocus("false");
end
Change those lines to:
Code:
function GCGambler_EditBox_OnLoad()
GCGambler_EditBox:SetNumeric(true);
GCGambler_EditBox:SetAutoFocus(false);
end
Seems to work, for that bug anyway. Doesn't look like it actually picks up rolls in /p.
- - - Updated - - -
The remaining issues are because the addon stores names from chat, which include -ServerName, while it parses the roll emote (which does not have server names).
Because of that, it seems to work okay if we just change it to strip server information when people are added to the group.
Code:
function GCGambler_OnEvent(self, event, ...)
-- LOADS ALL DATA FOR INITIALIZATION OF ADDON --
arg1,arg2 = ...;
local strippedName = tostring(arg2):match("^(%a+)%-") or tostring(arg2)
if (event == "PLAYER_ENTERING_WORLD") then
GCGambler_EditBox:SetJustifyH("CENTER");
if(not GCGambler) then
GCGambler = {
["active"] = 1,
["chat"] = false,
["strings"] = { },
["lowtie"] = { },
["hightie"] = { },
["bans"] = { }
}
end
if(not GCGambler["lastroll"]) then GCGambler["lastroll"] = 100; end
if(not GCGambler["stats"]) then GCGambler["stats"] = { }; end
if(not GCGambler["joinstats"]) then GCGambler["joinstats"] = { }; end
if(not GCGambler["chat"]) then GCGambler["chat"] = false; end
if(not GCGambler["bans"]) then GCGambler["bans"] = { }; end
GCGambler_EditBox:SetText(""..GCGambler["lastroll"]);
if(GCGambler["chat"] == false) then
GCGambler_CHAT_Button:SetText("(Party)");
chatmethod = "PARTY";
else
GCGambler_CHAT_Button:SetText("(Raid)");
chatmethod = "RAID";
end
if(GCGambler["active"] == 1) then
GCGambler_Frame:Show();
else
GCGambler_Frame:Hide();
end
end
-- IF IT'S A RAID MESSAGE... --
if ((event == "CHAT_MSG_RAID_LEADER" or event == "CHAT_MSG_RAID") and AcceptOnes=="true" and GCGambler["chat"] == true) then
-- ADDS USER TO THE ROLL POOL - CHECK TO MAKE SURE THEY ARE NOT BANNED --
if (arg1 == "1") then
if(GCGambler_ChkBan(strippedName) == 0) then
GCGambler_Add(strippedName);
if (not GCGambler_LASTCALL_Button:IsEnabled() and totalrolls == 1) then
GCGambler_LASTCALL_Button:Enable();
end
if totalrolls == 2 then
GCGambler_AcceptOnes_Button:Disable();
GCGambler_AcceptOnes_Button:SetText("Open Entry");
end
else
SendChatMessage("Unable to accept entry. No pay, no play. Got it?", chatmethod);
end
elseif(arg1 == "-1") then
GCGambler_Remove(strippedName);
if (GCGambler_LASTCALL_Button:IsEnabled() and totalrolls == 0) then
GCGambler_LASTCALL_Button:Disable();
end
if totalrolls == 1 then
GCGambler_AcceptOnes_Button:Enable();
GCGambler_AcceptOnes_Button:SetText("Open Entry");
end
end
end
if ((event == "CHAT_MSG_PARTY_LEADER" or event == "CHAT_MSG_PARTY")and AcceptOnes=="true" and GCGambler["chat"] == false) then
-- ADDS USER TO THE ROLL POOL - CHECK TO MAKE SURE THEY ARE NOT BANNED --
if (arg1 == "1") then
if(GCGambler_ChkBan(strippedName) == 0) then
GCGambler_Add(strippedName);
if (not GCGambler_LASTCALL_Button:IsEnabled() and totalrolls == 1) then
GCGambler_LASTCALL_Button:Enable();
end
if totalrolls == 2 then
GCGambler_AcceptOnes_Button:Disable();
GCGambler_AcceptOnes_Button:SetText("Open Entry");
end
else
SendChatMessage("Unable to accept entry. No pay, no play. Got it?", chatmethod);
end
elseif(arg1 == "-1") then
GCGambler_Remove(strippedName);
if (GCGambler_LASTCALL_Button:IsEnabled() and totalrolls == 0) then
GCGambler_LASTCALL_Button:Disable();
end
if totalrolls == 1 then
GCGambler_AcceptOnes_Button:Enable();
GCGambler_AcceptOnes_Button:SetText("Open Entry");
end
end
end
if (event == "CHAT_MSG_SYSTEM" and AcceptRolls=="true") then
local temp1 = tostring(arg1);
GCGambler_ParseRoll(temp1);
end
end
That code should replace the entire GCGambler_OnEvent() function, starting at line 72. After replacement, the function ends on line 177.