Last active
September 28, 2017 11:41
-
-
Save t00n/0f479bbe658aa31e053b81c90dbc5c56 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- sends a message on several channels at once --- | |
--- channels can be either a name or a number --- | |
/script m,cs="what you want to send",{"1","world","LookingForGroup"}; | |
/script for _,c in ipairs(cs) do i,n=GetChannelName(c);SendChatMessage(m,"CHANNEL",nil,i);end | |
--- toggles join/leave a channel --- | |
/script c="channel_name";i,n=GetChannelName(c);if i==0 then JoinChannelByName(c);ChatFrame_AddChannel(ChatFrame1,c);else LeaveChannelByName(c);end | |
--- swaps weapons with first 2 slots of last bag, works with 2H,1H+shield, not tested with 2 weapons --- | |
/script local a,b,c=CursorHasItem,PickupInventoryItem,PickupContainerItem;CloseMerchant();b(17);if (not a()) then c(4,1);b(16);c(4,2);b(17);else c(4,2);b(16);c(4,1);end | |
--- cast several spells when clicked several times. number is the position of the spell in the spell book --- | |
/script function c(l) s,d,e=GetSpellCooldown(l, "BOOKTYPE_SPELL");if d == 0 then CastSpell(l,"spell") end end | |
/script c(27);c(4) | |
-- cast several spells or use items when clicked several times --- | |
--- l is the position of the spell in the spell book or the inventory slot id | |
--- t is 1 if spell else item | |
/script function c(l,t) if t ==1 then CastSpell(l,"spell") else UseInventoryItem(l) end end | |
/script c(27,1);c(4,1);c(14,0) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment