Download
(246Kb)
Download
Updated: 04-06-09 02:15 AM
Pictures
File Info
Updated:04-06-09 02:15 AM
Created:unknown
Downloads:140,402
Favorites:349
MD5:

SpellAlerter  Popular! (More than 5000 hits)

Version: 2.03
by: kollektiv [More]

What it does

SpellAlerter is a basic spell alert mod based off the original SpellAlert mod. See the images for the different alert types you can setup.

Features

  • Add any spell and ability you want to be alerted to
  • Three filters: Enemy Spellcasts, Enemy Buffs, and Friendly Debuffs
  • Additional filtering for players only (reduces spam from things such as Mirror Image)
  • Each alert can have its own sound play. It's similar to making triggers in MSBT but a lot more simplified.
  • Optional minimap icon
  • Data broker plugin
  • All options are inside the GUI. Type /sa or /spellalerter to access them.

Localization

It should work with all language clients. It is currently only localized in English and Simplified Chinese. If you'd like to help translate see the Locales.lua file.

Bug Reports and Feature Requests

Please post them in the comments.

Changelog

2.03
  • Added Simplified Chinese translations
  • Localization is now done through CurseForge
  • Fixed bug with Target Only option

2.02
  • The arrow will now point to the left if the source's target is the same as the source
  • Added an option to filter players on spell casts. Helps reduce spam (ex. Frost Bolts from mirror images)
  • Added an option to toggle class colors on names. This is only 100% reliable in arenas
  • Added an option to select text font
  • Added an option to replace player name with any word
  • Added an option to toggle showing targets. Select between arrow model and text
  • Added an option to play a sound for each spell. Similiar to making MSBT triggers.
  • Added a list for spell cast ignores. These are spells you don't want showing targets (ex. Howl of Terror).
  • Added verifying and case formatting for list additions
  • Added a profile system
  • Added toggable minimap icon
  • Added localization support
  • Removed creating new anchors. I've never seen anyone use this.
  • Added a Sounds.lua file. Adding sounds is very easy. Open Sounds.lua and follow the instructions carefully.
  • Added Ace3 libraries
  • Added LibDBIcon-1.0 library
  • Added LibDataBroker-1.1 library - Hence there's support for LDB launcher display addons
  • Added LibSharedMedia-3.0 library
  • Added !ClassColors support
  • Created a FauxScrollFrame AceGUI widget for 'select' types in options

For the most recent changes, see the addon page. For a compilation of the all the changes, see the Changelog file in the zip.
Post A Reply Comment Options
Unread 03-26-08, 11:31 AM  
koraz
A Kobold Labourer

Forum posts: 0
File comments: 1
Uploads: 0
Re: Re: Re: Re: Re: Thumbs up

Originally posted by kollektiv
It's suppose to show the spell icon and the player name. Spell icons are more efficient to 'read' rather than actually having spell text.

But is it still possible to include the spell names, or at least make it an option that u can toggle on or off. Not everyone can memorize what every single icon represents what spell. I think A LOT of people will really appreciate this

EnSabahNur managed to slip in this feature in your modified addon, but for some reason, the alerts does not show up, even tho it works if you type /sa test. While your original version, shows the spell alert with icons only, but doesnt do anything when /sa test is typed ( i was trying to test it after adjusting height and fade).
Report comment to moderator  
Reply With Quote
Unread 03-26-08, 02:09 PM  
EnSabahNur
A Defias Bandit
 
EnSabahNur's Avatar
AddOn Author - Click to view AddOns

Forum posts: 3
File comments: 55
Uploads: 6
Re: Re: Re: Re: Re: Re: Thumbs up

Originally posted by koraz
But is it still possible to include the spell names, or at least make it an option that u can toggle on or off. Not everyone can memorize what every single icon represents what spell. I think A LOT of people will really appreciate this

EnSabahNur managed to slip in this feature in your modified addon, but for some reason, the alerts does not show up, even tho it works if you type /sa test. While your original version, shows the spell alert with icons only, but doesnt do anything when /sa test is typed ( i was trying to test it after adjusting height and fade).
here are my latest hack for the Great Addon:
Code:
-----------------------------------------------------
-- Spell Alerter by Kollektiv
-----------------------------------------------------

SpellAlerterDB = SpellAlerterDB or { height = 190, fade = 1, width = 0}

local select = select
local GetSpellInfo = GetSpellInfo
local band = bit.band

local CombatLog_Object_IsA = CombatLog_Object_IsA
local COMBATLOG_FILTER_HOSTILE_PLAYERS = COMBATLOG_FILTER_HOSTILE_PLAYERS

local colors = {
		[1] = {1,1,0,0},	-- heals
		[2] = {1,0,1,0},	-- cc
		[3] = {0,1,0,0},	-- dispelable
		[4] = {1,0,0,0},	-- damage
	}
	
local frame,texture,text,fade,spells
local time, fadetime, alpha, num = 0,0,0,0

-- References
local ref_GetTextColor
local ref_SetText
local ref_SetTexture
local ref_TextureSetVertexColor
local ref_TextSetVertexColor
local ref_Show
local ref_Hide
local ref_SetScript


local function SpellAlerter_CreateFrame()
	frame:SetFrameStrata("HIGH")
	frame:SetWidth(1)
	frame:SetHeight(1)
	frame:SetPoint("CENTER",UIParent,"CENTER",SpellAlerterDB.width,SpellAlerterDB.height)
	frame:Show()
	
	ref_Show = frame.Show
	ref_Hide = frame.Hide
	ref_SetScript = frame.SetScript
	
	local txt = frame:CreateFontString(ZoneTextFont,"ARTWORK")
	txt:SetFont("Fonts\\FRIZQT__.TTF",40,"THICKOUTLINE")
	txt:SetPoint("LEFT",frame,"CENTER",-45,-2)
	txt:SetJustifyH("LEFT")
	
	ref_GetTextColor = txt.GetTextColor
	ref_SetText = txt.SetText
	ref_SetTextColor = txt.SetTextColor
	ref_TextSetVertexColor = txt.SetVertexColor
	
	local txtr = frame:CreateTexture(nil,"BACKGROUND")
	txtr:SetHeight(35)
	txtr:SetWidth(35)
	txtr:SetVertexColor(1,1,1,1)
	txtr:SetPoint("RIGHT",frame,"CENTER",-50,0)
	txtr:SetTexCoord(0.07,0.9,0.07,0.90)
	
	ref_SetTexture = txtr.SetTexture
	ref_TextureSetVertexColor = txtr.SetVertexColor
	
	texture = txtr
	text = txt
end

local function SpellAlerter_OnUpdate(self, elapsed)
	local r,g,b
	return function(self, elapsed)
		time = time + elapsed
		fadetime = fadetime + elapsed
		if time > 0.05 then
			r,g,b = ref_GetTextColor(text)
			if fadetime < .1 then
				num = num + 0.5
			elseif fadetime >= 0.1 and fadetime <= (fade - 0.1) then
				num = 1
			elseif fadetime > (fade - 0.1) then
				num = num - 0.5
			end
			ref_TextSetVertexColor(text,r,g,b,num)
			ref_TextureSetVertexColor(texture,1,1,1,num)
			time = 0
			if fadetime > fade then
				ref_SetScript(self,"OnUpdate",nil)
				ref_Hide(self)
			end
		end
	end
end

SpellAlerter_OnUpdate = SpellAlerter_OnUpdate()

local function SpellAlerter_AddMessage(unit,type,icon,spell)
	ref_SetTexture(texture,icon)
	ref_TextureSetVertexColor(texture,1,1,1,0)
	ref_SetText(text,spell..","..unit)
	text:SetTextColor(unpack(colors[type]))
	time, fadetime, alpha, num = 0,0,0,0
	ref_Show(frame)
	ref_SetScript(frame,"OnUpdate",SpellAlerter_OnUpdate)
end


local function SpellAlerter_COMBAT_LOG_EVENT()
	local _, eventtype, srcName, srcFlags, dstName, dstFlags
	local unit, spellID
	local spell, icon
	return function(...)
		_, eventtype, _, srcName, srcFlags, _, dstName, dstFlags = select(1,...)
		if eventtype == ("SPELL_CAST_START" or eventtype == "SPELL_CAST_SUCCESS") and CombatLog_Object_IsA(srcFlags, COMBATLOG_FILTER_HOSTILE_PLAYERS) then
			unit = srcName
		elseif eventtype == "SPELL_AURA_APPLIED" and CombatLog_Object_IsA(dstFlags, COMBATLOG_FILTER_HOSTILE_PLAYERS) then
			unit = dstName
		else
			return
		end
		spellID = select(9,...)
		if spellID == 35223 then return end -- hack for Holy Light bug,
		spell,_,icon = GetSpellInfo(spellID)
		if spells[spell] then
			SpellAlerter_AddMessage(unit,spells[spell],icon,spell)
		end
	end
end

SpellAlerter_COMBAT_LOG_EVENT = SpellAlerter_COMBAT_LOG_EVENT()

local function SpellAlerter_Test()
	SpellAlerter_AddMessage("Kollektiv",3,"Interface\\Icons\\Spell_Nature_SkinofEarth","Test")
end

local cmdfuncs = {
	width = function(v) if not v or v < -500 or v > 500 then ChatFrame1:AddMessage("Invalid width value, enter a value between -500 and 500",0,1,0); return; end;
											 SpellAlerterDB.width = v; 
											 frame:ClearAllPoints(); 
											 frame:SetPoint("CENTER",UIParent,"CENTER",SpellAlerterDB.width,SpellAlerterDB.height); 
											 SpellAlerter_Test()
					 end,
	height = function(v) if not v or v < -500 or v > 500 then ChatFrame1:AddMessage("Invalid height value, enter a value between -500 and 500",0,1,0); return; end;
											 SpellAlerterDB.height = v; 
											 frame:ClearAllPoints(); 
											 frame:SetPoint("CENTER",UIParent,"CENTER",SpellAlerterDB.width,SpellAlerterDB.height); 
											 SpellAlerter_Test()
					 end,
	fade = function(v)   if not v or v < .5 or v > 5 then ChatFrame1:AddMessage("Invalid fade time value, enter a value between 0.5 and 5",0,1,0); return; end;
											 SpellAlerterDB.fade = v; fade = v; SpellAlerter_Test() end,
	test = function() SpellAlerter_Test() end,
}

local cmdtbl = {}
function SpellAlerter_Command(cmd)
	for k in ipairs(cmdtbl) do
		cmdtbl[k] = nil
	end
	for v in gmatch(cmd, "[^ ]+") do
  	tinsert(cmdtbl, v)
  end
  local cb = cmdfuncs[cmdtbl[1]] 
  if cb then
  	local s = tonumber(cmdtbl[2])
  	cb(s)
  else
  	ChatFrame1:AddMessage("Spell Alerter Options | /sa <option>",0,1,0)
  	ChatFrame1:AddMessage("-- width <number> | value: " .. (SpellAlerterDB.width or "none"),0,1,0)
	ChatFrame1:AddMessage("-- height <number> | value: " .. (SpellAlerterDB.height or "none"),0,1,0)
  	ChatFrame1:AddMessage("-- fade <number> | value: " .. (SpellAlerterDB.fade or "none"),0,1,0)
  	ChatFrame1:AddMessage("-- test",0,1,0)
  end
end

local function SpellAlerter_OnLoad(self)
	self:RegisterEvent("COMBAT_LOG_EVENT_UNFILTERED")
	fade = SpellAlerterDB.fade
	spells = SpellAlerter_spells
	SpellAlerter_CreateFrame(self)
	SlashCmdList["SpellAlerter"] = SpellAlerter_Command
 	SLASH_SpellAlerter1 = "/sa"
 	ChatFrame1:AddMessage("Spell Alerter by Kollektiv. Type /sa for options",0,1,0)
end
	
local function SpellAlerter_OnEvent(self, event, ...)
	if event == "VARIABLES_LOADED" then
		SpellAlerter_OnLoad(self)
	else
		SpellAlerter_COMBAT_LOG_EVENT(...)
	end
end

frame = CreateFrame("Frame",nil,UIParent)
frame:RegisterEvent("VARIABLES_LOADED")
frame:SetScript("OnEvent",SpellAlerter_OnEvent)
hope it works on non German Client
Report comment to moderator  
Reply With Quote
Unread 03-26-08, 11:08 PM  
coopo
A Kobold Labourer

Forum posts: 0
File comments: 4
Uploads: 0
Nice work Ensabahnur. One issue though with the hack is that the ability to set the height is now broken.

In another words, it's stuck in the middle... for me at least.

edit: nevermind. If you change the width first then the height parameter starts functioning again.
Last edited by coopo : 03-26-08 at 11:15 PM.
Report comment to moderator  
Reply With Quote
Unread 03-27-08, 06:34 AM  
znylol
A Kobold Labourer

Forum posts: 0
File comments: 1
Uploads: 0
Apparently in the 2.4 version there's the servername behind the player's name, I find this rather annoying tbh - Is it possible to edit the .lua somehow to remove that? Or any other suggestions to get rid of it are welcome and very much appreciated.
Last edited by znylol : 03-27-08 at 06:34 AM.
Report comment to moderator  
Reply With Quote
Unread 03-27-08, 07:17 AM  
myztikrice
A Kobold Labourer

Forum posts: 0
File comments: 30
Uploads: 0
ShardAce also uses /sa and /spellalerter doesn't work. Is there a way to fix this?
Report comment to moderator  
Reply With Quote
Unread 03-27-08, 10:31 AM  
Stoalich
A Kobold Labourer

Forum posts: 0
File comments: 1
Uploads: 0
First of all, I love this addon. I've been looking for a SpellAlert where I can choose the spells it shows for long time. I'd really love to see a few additions though.

* Option Menu
* Full editable frame (position, font, size and what it shows [Icon][Spell][Name])
* New messages shouldn't override old messages. Instead, make it use multiply lines like most addons do.

I can't seem to get Cheat Death to show on it. I'd really love such things. Also Viper Sting on friendly target etc. I think this addon can grow to a really good one once it gets more advanced. For now I'll be more than happy to use it with the functions it already has. Helps a lot as shaman
Report comment to moderator  
Reply With Quote
Unread 03-27-08, 10:35 AM  
vrna
A Kobold Labourer

Forum posts: 0
File comments: 1
Uploads: 0
Hy,
there are several lua errors since 2.4 and the announced spell/gain doesnt fade ;( I deleted the spellalert WTF .baks but still doesnt work for me equitable ;o any ideas? love this addon <3
Last edited by vrna : 03-27-08 at 10:37 AM.
Report comment to moderator  
Reply With Quote
Unread 03-28-08, 03:53 PM  
arrch
A Kobold Labourer

Forum posts: 0
File comments: 3
Uploads: 0
Originally posted by kollektiv
Ok, i'll look into this.
This is no longer a problem. It was probably, like someone else said, Blizzards fault.
Last edited by arrch : 03-28-08 at 03:53 PM.
Report comment to moderator  
Reply With Quote
Unread 03-29-08, 01:31 AM  
skyler
A Kobold Labourer

Forum posts: 0
File comments: 1
Uploads: 0
When i'm in a bg I see spell being cast from across the map is this how its suppose to be? cause in arena you want to see everything?
Report comment to moderator  
Reply With Quote
Unread 03-29-08, 02:59 AM  
kollektiv
A Kobold Labourer
AddOn Author - Click to view AddOns

Forum posts: 0
File comments: 46
Uploads: 6
Originally posted by skyler
When i'm in a bg I see spell being cast from across the map is this how its suppose to be? cause in arena you want to see everything?
The combat log catches everything you can see, so yes you'll see everything.
Last edited by kollektiv : 03-29-08 at 03:01 AM.
Report comment to moderator  
Reply With Quote
Unread 03-29-08, 06:25 PM  
Vyril
A Kobold Labourer

Forum posts: 0
File comments: 4
Uploads: 0
I am having an issue where the spell alert is showing up after the spell has been casted, has this been fixed?
Report comment to moderator  
Reply With Quote
Unread 03-29-08, 07:00 PM  
kollektiv
A Kobold Labourer
AddOn Author - Click to view AddOns

Forum posts: 0
File comments: 46
Uploads: 6
Originally posted by Vyril
I am having an issue where the spell alert is showing up after the spell has been casted, has this been fixed?
Buffs/debuffs gained by hostile players used to show up even if the they didn't originate from a hostile player. I fixed this in the latest version.
Last edited by kollektiv : 03-29-08 at 07:01 PM.
Report comment to moderator  
Reply With Quote
Unread 03-29-08, 07:13 PM  
Vyril
A Kobold Labourer

Forum posts: 0
File comments: 4
Uploads: 0
Originally posted by kollektiv
Buffs/debuffs gained by hostile players used to show up even if the they didn't originate from a hostile player. I fixed this in the latest version.
Awesome! Thank you =D, I love your mod
Report comment to moderator  
Reply With Quote
Unread 03-30-08, 08:49 AM  
Cris
A Kobold Labourer

Forum posts: 0
File comments: 2
Uploads: 0
How do i change the font size? it is way too big on my ui and i didnt find any line for it.

regards chris
Report comment to moderator  
Reply With Quote
Unread 03-31-08, 12:24 PM  
psychotic
A Kobold Labourer

Forum posts: 1
File comments: 3
Uploads: 0
Hello,

I am using the most recent version and when I get to a certain point in deleting the spells in game, the spell list disappears. It happens after the sixth spell or so.

I can get it to reappear by adding a spell that is not already on the list, I can even make up a name. I added mana burnq to test that. The problem with that is, once I get to the point where it makes the spell list disappear, and reappear, I can only delete them one at a time before it disappears again. That makes it a 1:1 ratio and I can not make any progress with deleting them if I keep adding some others.
Report comment to moderator  
Reply With Quote
Post A Reply



Category Jump: