Skip to content

Commit

Permalink
Add files via upload
Browse files Browse the repository at this point in the history
  • Loading branch information
fadichmn authored Aug 14, 2019
0 parents commit eae36a7
Show file tree
Hide file tree
Showing 3 changed files with 44 additions and 0 deletions.
30 changes: 30 additions & 0 deletions DismountMe.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
ShaguMount = CreateFrame("Frame")
ShaguMount:RegisterEvent("UI_ERROR_MESSAGE")

ShaguMount.Buffs = { "spell_nature_swiftness", "_mount_", "_qirajicrystal_",
"ability_racial_bearform", "ability_druid_catform", "ability_druid_travelform",
"spell_nature_forceofnature", "ability_druid_aquaticform", "spell_nature_spiritwolf" }

ShaguMount.Errors = { SPELL_FAILED_NOT_MOUNTED, ERR_ATTACK_MOUNTED, ERR_TAXIPLAYERALREADYMOUNTED,
SPELL_FAILED_NOT_SHAPESHIFT, SPELL_FAILED_NO_ITEMS_WHILE_SHAPESHIFTED, SPELL_NOT_SHAPESHIFTED,
SPELL_NOT_SHAPESHIFTED_NOSPACE, ERR_CANT_INTERACT_SHAPESHIFTED, ERR_NOT_WHILE_SHAPESHIFTED,
ERR_NO_ITEMS_WHILE_SHAPESHIFTED, ERR_TAXIPLAYERSHAPESHIFTED,ERR_MOUNT_SHAPESHIFTED }

ShaguMount:SetScript("OnEvent", function()
for id, errorstring in pairs(ShaguMount.Errors) do
if arg1 == errorstring then
for i=0,15,1 do
currBuffTex = GetPlayerBuffTexture(i);
if (currBuffTex) then

for id, bufftype in pairs(ShaguMount.Buffs) do
if string.find(string.lower(currBuffTex), bufftype) then
CancelPlayerBuff(i);
end
end
end
end
end
end
end)

6 changes: 6 additions & 0 deletions DismountMe.toc
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
## Interface: 11302
## Title: DismountMe
## Author: Fadi (Kund) Chamoun - 2019/08/14
## Notes: Unmounts the Player whenever a action is used which cannot be done mounted. (11200)
## Version: 1.0
DismountMe.lua
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# DismountMe
A WoW Classic Addon that automatically unmounts the player when using an action. It is quite similar to ezDismount, as it unmounts the Player whenever a action is used which cannot be done mounted or shapeshifted, however tt's written minimal and designed to work on every localized gameclient.

## Installation
1. Download
2. Unpack the Zip file
3. Copy "DismountMe" into Wow-Directory\Interface\AddOns
4. Restart Wow

0 comments on commit eae36a7

Please sign in to comment.