changeset 1:cf3106134425

Initial upload.
author Farmbuyer of US-Kilrogg <farmbuyer@gmail.com>
date Sat, 30 Oct 2010 19:13:05 +0000
parents 14be231b69e6
children 4d9949e554ef
files .pkgmeta WhatJustProcced.toc main.lua
diffstat 3 files changed, 67 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.pkgmeta	Sat Oct 30 19:13:05 2010 +0000
@@ -0,0 +1,17 @@
+package-as: WhatJustProcced
+
+externals:
+  libs/LibStub:
+    url: svn://svn.wowace.com/wow/libstub/mainline/trunk
+    tag: latest
+  libs/CallbackHandler-1.0:
+    url: svn://svn.wowace.com/wow/callbackhandler/mainline/trunk/CallbackHandler-1.0
+    tag: latest
+  libs/AceAddon-3.0:
+    url: svn://svn.wowace.com/wow/ace3/mainline/trunk/AceAddon-3.0
+  libs/AceEvent-3.0:
+    url: svn://svn.wowace.com/wow/ace3/mainline/trunk/AceEvent-3.0
+  libs/AceConsole-3.0:
+    url: svn://svn.wowace.com/wow/ace3/mainline/trunk/AceConsole-3.0
+
+# vim: et
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/WhatJustProcced.toc	Sat Oct 30 19:13:05 2010 +0000
@@ -0,0 +1,16 @@
+## Interface: 40000
+## Title: What Just Procced
+## Notes: Provides training reminders to help decipher the Blizzard Spell Alerts.
+## Author: Farmbuyer of Kilrogg
+## OptionalDeps: Ace3
+
+#@no-lib-strip@
+libs\LibStub\LibStub.lua
+libs\CallbackHandler-1.0\CallbackHandler-1.0.xml
+libs\AceAddon-3.0\AceAddon-3.0.xml
+libs\AceEvent-3.0\AceEvent-3.0.xml
+libs\AceConsole-3.0\AceConsole-3.0.xml
+#@end-no-lib-strip@
+
+main.lua
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/main.lua	Sat Oct 30 19:13:05 2010 +0000
@@ -0,0 +1,34 @@
+local nametag, addon = ...
+
+
+-----------------------------------------------------------------------------
+-- other locals
+local on = false
+
+
+-----------------------------------------------------------------------------
+addon = LibStub("AceAddon-3.0"):NewAddon(addon, nametag,
+		        "AceConsole-3.0", "AceEvent-3.0")
+
+function addon:OnInitialize()
+	self:RegisterChatCommand("wjp", "ToggleEnable")
+	self.OnInitialize = nil
+end
+
+function addon:ToggleEnable()
+	on = not on
+	if on then
+		self:RegisterEvent("SPELL_ACTIVATION_OVERLAY_SHOW")
+	else
+		self:UnregisterEvent("SPELL_ACTIVATION_OVERLAY_SHOW")
+	end
+	self:Print(on and "Activated" or "Deactivated")
+end
+
+function addon:SPELL_ACTIVATION_OVERLAY_SHOW(...)
+	local _,spellID,_,positions = ...
+	local spell = GetSpellLink(spellID) or GetSpellInfo(spellID) or spellID
+	self:Printf("%s at position:  %s.", spell, positions)
+end
+
+-- vim:noet