Download
(2Kb)
Download
Updated: 08-16-16 12:39 AM
Pictures
File Info
Compatibility:
Legion (7.0.3)
Minor patch (6.2.4)
Minor patch (6.2.3)
Fury of Hellfire (6.2)
The Adventure Continues (6.1)
Warlords of Draenor (6.0.3)
Warlords of Draenor Pre-Patch (6.0.2)
Updated:08-16-16 12:39 AM
Created:10-30-10 12:54 PM
Downloads:2,590
Favorites:3
MD5:
Categories:Group, Guild & Friends, Chat Mods

SayGMOTD

Version: 160815
by: bitbyte [More]

A lightweight and simple mod that displays a pop-up window with the GMOTD on login, and whenever it changes.

Helps keep you updated with the latest GMOTD. Great for guilds that uses their GMOTD to communicate with their members regularly.


Check out my other mods:
- SaySapped
- SayGMOTD
- SayMassRez

2016-08-15: updated toc for 7.0
2014-10-15: updated toc for 6.0
2013-10-01: updated toc for 5.4
2013-05-22: updated toc for 5.3
2012-10-01: updated toc
2012-05-01: updated toc; Happy Loyalty Day!
2011-07-01: updated toc
2010-10-30: Initial public release
Post A Reply Comment Options
Unread 11-30-10, 11:58 AM  
Chigerian
A Kobold Labourer

Forum posts: 0
File comments: 20
Uploads: 0
This is a great addon however, I've seem to notice that it will always popup even the motd doesn't change
Report comment to moderator  
Reply With Quote
Unread 11-10-12, 08:43 AM  
Xruptor
A Flamescale Wyrmkin
 
Xruptor's Avatar
AddOn Author - Click to view AddOns

Forum posts: 133
File comments: 640
Uploads: 22
Originally Posted by Chigerian
This is a great addon however, I've seem to notice that it will always popup even the motd doesn't change
Replace the code in the .lua file with this. I've gone ahead and made changes so that it will properly get the MOTD on GUILD_ROSTER_UPDATE. This is much better then GUILD_MOTD. I also made it so that it only displays once per new guild MOTD. So if the Guild MOTD hasn't changed you won't get notified. It will now only notify you if the MOTD has changed. I hope this helps

Code:
local SayGMOTD = CreateFrame("Frame", nil, UIParent)
SayGMOTD:SetPoint("CENTER", 0, GetScreenHeight()/5)
SayGMOTD:SetWidth(300)
SayGMOTD:SetHeight(65)
SayGMOTD:SetToplevel(true)
SayGMOTD:SetMovable(true)
SayGMOTD:EnableMouse(true)
SayGMOTD:SetScript("OnMouseDown", SayGMOTD.StartMoving)
SayGMOTD:SetScript("OnMouseUp", SayGMOTD.StopMovingOrSizing)
SayGMOTD:SetBackdrop({ 
  bgFile = "Interface\\DialogFrame\\UI-DialogBox-Background", 
  edgeFile = "Interface\\DialogFrame\\UI-DialogBox-Border",
  insets = { left = 5, right = 5, top = 5, bottom = 5 }
})

SayGMOTD.button = CreateFrame("Button", nil, SayGMOTD, "UIPanelCloseButton")
SayGMOTD.button:SetPoint("TOPRIGHT", -7, -7)
SayGMOTD.button:SetScript("OnClick", function()
   SayGMOTD:Hide()
end)

SayGMOTD.header = SayGMOTD:CreateFontString(nil, "OVERLAY", "GameFontNormal")
SayGMOTD.header:SetPoint("TOPLEFT", SayGMOTD, "TOPLEFT", 0, -20)
SayGMOTD.header:SetWidth(SayGMOTD:GetRight() - SayGMOTD:GetLeft())
SayGMOTD.header:SetText("Guild Message Of The Day")

SayGMOTD.text = SayGMOTD:CreateFontString(nil, "OVERLAY", "GameFontWhite")
SayGMOTD.text:SetPoint("TOPLEFT", SayGMOTD, "TOPLEFT", 22, -42)
SayGMOTD.text:SetWidth(SayGMOTD:GetRight() - SayGMOTD:GetLeft() - 40)
SayGMOTD.text:SetJustifyH("LEFT")

SayGMOTD:SetScript("OnEvent", function(self, event, arg1)
  local getMOTD = ""
  if not GMOTD then GMOTD = "" end
  if (event == "GUILD_MOTD") then
	if arg1 ~= GMOTD and arg1 ~= "" then getMOTD = arg1 end
  else
	local chkMsg = IsInGuild() and GetGuildRosterMOTD() or ""
	if chkMsg ~= GMOTD and chkMsg ~= "" then getMOTD = chkMsg end
  end
  if (getMOTD ~= "" and getMOTD ~= GMOTD and IsInGuild()) then
	GMOTD = getMOTD
    SayGMOTD.text:SetText(GMOTD)
    SayGMOTD:SetHeight(SayGMOTD.text:GetHeight() + 65)
    SayGMOTD:Show()
  else
    SayGMOTD:Hide()
  end
end)

SayGMOTD:RegisterEvent("PLAYER_LOGIN")
SayGMOTD:RegisterEvent("GUILD_MOTD")
SayGMOTD:RegisterEvent("GUILD_ROSTER_UPDATE")
__________________
Click HERE for the ultimate idiot test.

if (sizeof(sadness) > sizeof(happiness)) { initDepression(); }
Report comment to moderator  
Reply With Quote
Post A Reply



Category Jump: