Allows you to create your own IF THEN statements that will dynamically change the function of a button.
This addon is intended for people that have a basic understanding of programming. Specifically conditional If-Then statements.
The addon allows you to write your own if-then statements that will be evaluated and run whenever you press a button, or they can trigger on certain events ingame.
It provides a simple text editor, a fully documented API and some simple If-Then syntax so that you can string together almost anything you want to react to.
Examples:
IF HasOpenQuest("My daily fishing quest") AND InZone("Stormwind") THEN Cast("Fishing");
OnEvent("GroupInvite") AND InLFGQueue() THEN DeclineInvite() AND Reply("Sorry, I am already in the LFG queue");
Look at the FAQ page for the most asked questions, and the Examples page for examples.
Please post bugreports and feature requests on the Curseforge.com project page
Facts
- Date created
- Oct 06, 2011
- Categories
- Last update
- May 20, 2013
- Development stage
- Release
- Language
- enUS
- License
- All Rights Reserved
- Curse link
- IfThen
- Downloads
- 4,297
- Recent files
- R: IfThen v1.8.2 for 5.3.0 May 20, 2013
- R: IfThen v1.8.1 for 5.2.0 Apr 25, 2013
- R: IfThen v1.8.0 for 5.2.0 Mar 05, 2013
- R: IfThen v1.7.9 for 5.1.0 Feb 07, 2013
- R: IfThen v1.7.8 for 5.1.0 Dec 07, 2012
- Reply
- #67
Jarod24 Apr 25, 2013 at 09:01 UTC - 0 likesVersion 1.8.2 is out.
See the changelog for the changes.
Author of IfThen, LinkTranslator, SetGuildRank, CompressMacro
- Reply
- #66
Jarod24 Mar 05, 2013 at 23:10 UTC - 0 likesVersion 1.8.0 is released.
See the changelog for a complete list.
- Reply
- #65
Pekesino Feb 26, 2013 at 22:22 UTC - 0 likes@Jarod24: Go
Ok, I understand. I`ll be waiting for another version to see the improvement. Thanks a lot.
- Reply
- #64
Jarod24 Feb 24, 2013 at 12:21 UTC - 0 likes@Pekesino: Go
hmmm. Global cooldown you say.
HaveCooldown() looks at a spell's or item's cooldown. That means the time until you can use it again (i.e your heartstone got x minutes left until you can use it).
However when i dived deeper into the subject it also seems that the blizzard functions used for this will include the GDC when query'ing for cooldown on
-items/spells (as you pointed out).One solution i can think of just now would be to add a extra argument to HaveCooldown() so that it will ignore values below a certain threshold and still return true (hardcoding in a GCD value dosent make sense since it varies with the player's stats and some spells dont use GCD).Update:
The only outstanding issue is if you call the function too fast after the actual cast then it can return false even when you have a cooldown. This should however not be a problem in practice, since even the Tick-event only occurs every 1 seconds. This is because the blizzard function initially returns the GCD value for all spells until the GCD is done, after that it will return the spell's specific cooldown.
In effect, i cant trust the values since they might be spell-specific or global.
- Reply
- #63
Pekesino Feb 23, 2013 at 10:53 UTC - 0 likesHi Jarod,
Glad to see active your addon. I need your advice. Using HasCooldown() I got a false both on GCD and the spell cooldown. I'm trying to figure out a way to distinghish among the Global Cooldown and the real spell cooldown. Any hint please? Thanks anyway.
- Reply
- #62
Jarod24 Feb 22, 2013 at 13:29 UTC - 0 likes@diejetty: Go
Nope.
You got to write multiple statements.
- Reply
- #61
diejetty Feb 22, 2013 at 05:21 UTC - 0 likes@diejetty: Go
Hey Jarod,
Is there a way to have an event trigger on every form of chat; guild, group, whisper, say, etc ? Without having to make multiple lines for each type. OnEvent("Chat","Group","","hello")
Thx.
- Reply
- #60
Jarod24 Feb 07, 2013 at 18:44 UTC - 0 likesOk, lots of changes in version 1.7.9
See the changelog for a complete list.
- Reply
- #59
Delvai Feb 06, 2013 at 20:17 UTC - 0 likes@Jarod24: Go
Awesome! Thanks a lot. Love your addon btw! Keep up the great work :)
Delv
- Reply
- #58
Jarod24 Feb 05, 2013 at 22:24 UTC - 0 likes@Delvai: Go
Done.
The next version will support "system" as a channel argument for the OnEvent("Chat") event.
I got no estimate for when the next version is released though.
Lots of changes have been done and i need time to make sure stuff dosent break/implode.