|Go to Page...|
|Thread Tools||Display Modes|
|02-25-06, 12:13 AM||#11|
And more Section 8
Q. I got my UI set up the way I want, log out and back in, and nothing is saved, I have to do it all over again. Why?
A. Make sure that you don't have copies of any of the files listed above anywhere else in your WoW folders. Also, make sure that none of the above files are set to "read-only".
Q. I lost all my addon data! Is it possible to retrieve it somehow?
A. Unless you've made a backup of your SavedVariables.lua file, no, sorry, it's not.
If you *have* made a backup, you should be able to simply overwrite your current SavedVariables.lua file with the old (backup) version.
However, there's a tool that exists to make this process easier, AND it will allow you to MERGE (rather than overwrite) your new data with your old. That tool is called SVEdit, and it can be found here: http://www.wowinterface.com/download...fo.php?id=4047
Q. My UI is all messed up. My bag slots don't line up properly with the bag themselves, how do I fix it? I dragged X thing off the screen, how do I get it back?
A. Go to your:
../World of Warcraft/WTF/Account/<Account Name>/<Character Name>
folder and delete your:
file. That will reset all visible UI elements to the default Blizzard locations. A bit of a pain, as you'll have to set your layout back up the way you want, but at least problem X will be fixed.
Q. I messed up my chat settings, I can't see X messages any more, my channels are all messed up. How do I fix it?
A. Go to your:
../World of Warcraft/WTF/Account/<Account Name>/<Character Name>
folder. Delete the:
file. That will reset all chat windows, channels & chat options to the default Blizzard setup. You'll have to re-do any changes you made to layout and channels that you want to keep.
Q. How do I make it so I can see both my chat and my combat window at the same time? How do I make a new chat window?
A. Go to the main in-game menu (esc or the little computer icon). Go to Interface Options. Make sure "Lock Chat Settings" is turned off. Make sure "Simple Chat" is turned off. Go back to the main game window. Hover your mouse over your chat window. A tab will appear at the top of your window. Right click on it. At the top, choose "Unlock". Move it to the location you want it by dragging on the tab. Resize it to the size you want by dragging on the edges of the chat window. Re-lock when you get it to the location and size you want.
For additional Chat Information and Troubleshooting visit http://www.wowwiki.com/chat
Q. I'm getting an error message saying my AddOns are using more than 32 mg memory and it dumps me out of game. How do I fix it?
A. Log in as far as your character select screen. Use the AddOns button in the lower left hand corner to bring up the list. There is a spot in the top right hand corner to allocate UI memory. Try setting it to 64. If it still isn't enough (unlikely, but possible), set it to 0 (zero), that means "unlimited" (but it will still only use what it needs, it won't suck up all your computer's memory).
Q: How do I connect to our guild's website in an addon (to get DKP info/access guild rosters/Thottbot/etc)?
A: The user interface LUA environment is "sandboxed" and it is not possible to get data in or out of the game in realtime while the game is playing. The only method of getting data in or out is through the SavedVariables.lua file which is only updated/read on logout/login or when the interface is reloaded. The function call to load a URL (LaunchURL()) only works for web pages originating on Blizzard's web site and it switches to your default web browser (Internet Explorer, Firefox, etc.) anyways. There is no way to access web site information within the game.
Q How do I extract information from WoW to an outside source? (Credit Shouryuu)
A This can't be done directly. For example, let us say you want to make an AddOn that updates your guild rooster, and posts the name/lvl/class of each member on your web site. The only way to do this, is to write an AddOn that will save the name/lvl/class of each guild member in a SavedVariables.lua, close WoW and extract the info to your guild web site either manually, or a program which would do it for you.
You cannot extract information about anything in the WoW environment by "leeching" the information that passes between you and the server.
|02-25-06, 12:15 AM||#12|
Section 9 – What? (Definitions)
Q: No, really. What the heck are macros and scripts? (Credit Legorol, as posted at http://www.WoWWiki.com)
Macros are series of commands designed to be executed in series.
A macro can consist of any number of /<command>s or pure text to up 255 characters. Users wishing to use more advanced commands are recommended to see the Interface Customization and World of Warcraft API sections at wowwiki.com.
Usually, not just in WoW, the term Script refers to a short to medium length program, written in some kind of simple programming language (called a scripting language). The purpose of a script is usually to control another program.
World of Warcraft has a powerful programming language called Lua embedded inside it, which is used for scripting. What this means is that WoW is able to understand and execute little programs written in the Lua language. However, in WoW, a script is usually not something that you use by itself, i.e. you don't just type in a script and execute it (although this is also possible). Instead, there are several places in WoW where you have the option to enter scripts as part of something else.
The kind of places that you can use a script:
/script [command] : If you type the slash command "/script" in the chat box, you can follow it with one or more valid Lua language statements (i.e. a script), separated by semi-colons (.
Macros: you can enter scripts as part of macros, by putting one or more "/script" commands in your macro.
So what can a script do? There are many resources on Lua scripts (the main one being http://www.wowwiki.com); However, the most important point is that scripts are able to perform many more game actions than slash commands. This is done via a set of functions (called API or Application Programming Interface) that WoW makes available for use in scripts. There is a quite extensive list of all the API functions available for use in scripts at http://www.wowwiki.com
|02-25-06, 12:17 AM||#13|
Section 10 – Where?
Q: Where can I learn more about macros / scripting?
A: These forums, for one. Another great source of info is http://www.wowwiki.com
For Macros, some good sites to visit are http://www.wowmacros.com for pre-made macros. Visit http://www.geocities.com/jsalli39/wowmacros.html or http://www.rpgexpert.com/4118.html for help with macro commands and scripting in general.
|02-25-06, 12:18 AM||#14|
Section 11 – How? (How do I use?)
Q: How do I create a macro? (Credit Trimble)
A: In a chat box, start by typing /macro. then click NEW, give it a name and an icon, and then start entering some commands.
Q: What is the best way to know the exact spelling of a spell to cast? (Credit Trimble)
A: Open your spellbook along side your macro editor. Position the edit cursor in the macro window, and then hold down the SHIFT key while you LEFT click on a spell icon in your spellbook, and the game will type in the correct /cast spellname command for you. You can then cut/paste or edit it if needed.
Q: How can I make a conditional macro? (Credit Trimble)
A: To use conditionals, you'll need to invoke the LUA interpreter. To do that, you start a macro with "/script" Anything after /script will be run as lua code (or a 'chunk' as lua calls it). It is VERY important to keep all parts of a Lua chunk on ONE LINE in a macro, and make it fit within 255 characters.
You can then use the "if then end" codeblock to complete your macro. it should look similar to this when you're done:
/script if UnitName('target') == 'fred' then CastSpellByName('Healing Touch(Rank 1)') end
Note the use of "end" at the end. it's important to Lua.
Also, note that when using Lua code, you can't use /cast to cast a spell - you have to use the CastSpellByName() "function". Luckily, CastSpellByName accepts the exact spelling of the spellname given to you by the shift-click method I mentioned above (remember, you can cut and paste after using the shift-click trick). Additionally, there is another function called CastSpell(), but you must know the SPELL NUMBER to use it.
Also notice the part that says 'target'. this is a placeholder that WoW uses to represent whatever your target it. It's a kind of variable, but it isn't a Lua variable. Other placeholders are 'player', meaning yourself (no matter what your name is), 'party1' through 'party4' meaning your groupmates, and 'pet' which means your pet. MANY wow Lua functions accept these placeholders as arguments, but they are NOT Lua variables - they are more like literals to Lua. This means that while UnitName('player') is valid, UnitName(player) is not valid unless you created a Lua variable called player and did a statement like this player = 'player' to make it contain a valid placeholder value.
Q: When using Lua script code, do I need to end each line with a semicolon? (Credit Trimble)
A: Lua doesn't require this, but you may do so if you like. It does make it easier to read, but Lua does have strict enough syntax that it can understand commands without semicolons. Even something as ugly as this is legal: /script a =5 b =6 Message(a..b)c= a +b
Q: Can I make a conditional macro that does something if I have a certain buff? (Credit Trimble)
A: It's possible, but WoW's UI doesn't come with a simple function to check for a buff. There are ways to do it, but it's tricky. The best way is to use an addon that provides this function and then use it in your macros.
NOTE: Do a search on curse-gaming.com for the IsBuffActive AddOn; this will provide you with an extremely simple method of checking for buffs on yourself or others.
Q: How do I output text to the chat window?
A: use DEFAULT_CHAT_FRAME:AddMessage(msg,r,g,b)
This is easier if you alias it something like:
cprint = DEFAULT_CHAT_FRAME:AddMessage
then you can use cprint("foo",1,0,0) or the like.
where msg is the text, r,g,b are red,green,blue (0-1) and a is alpha (0-1)
Q: Is it possible to use multiple abilities in one macro, such as cast Corruption, Curse of Agony, and then Shadowbolt? (Credit Skrag)
A: No. The reason is that it is not possible to wait in a macro, but to cast one spell after another, you would have to cast the first one, wait for it to finish, then cast the other. Even instant spells activate a global recast timer, which is somewhere in the neighborhood of one second, I believe, and you cannot cast another spell until this timer is done. So, without the ability to wait in a macro, it is impossible to cast multiple spells. Also, spells can only be cast when the player presses a key or clicks their mouse, not at any other time (which is why "do something, wait a bit, then cast XXX" is impossible).
It is, however, possible to do multiple things that don't require waiting. You could, for example, cast a spell and turn on attack. Or use two items (as long as they had independent refresh timers).
You just can't do anything that would require waiting between action A and action B.
NOTE: It is possible, however, to install an AddOn which automatically changes an action button to cast different spells in a user-specified list. So the first time you press the action button, you would cast Corruption; press it again, and you’d cast Curse of Agony; a third time would cast Shadowbolt. Danboo’s CastAway AddOn is a good example of an AddOn designed to do this very thing.
Q: How do I set up a macro or script to automatically cast XXX when... (Credit Skrag)
A: You don't. There is no way to automatically cast any spell or ability. You can ONLY use spells and abilities in response to a hardware event (mouse button or keyboard press), and furthermore, it appears that the hardware event must trigger a normal action button or the spell will fail to cast. You can attempt to call CastSpellByName after a certain amount of time, but the spell will not be cast.
NOTE: There are some AddOns that make self-rebuffing much easier to the point of being almost automated.
|02-25-06, 12:19 AM||#15|
Section 11 again
Q: Is it possible to wait in a macro for a certain amount of time, then continue running the rest of the macro? (Credit Skrag)
A: No, it is not possible. See the question regarding multiple abilities in one macro for a more detailed explanation of the sorts of things not being able to wait prevents you from doing.
It is possible, if you have Cosmos installed, to do something like:
/in 5 /say Hello,
And in 5 seconds you will say "Hello,". But you will say "Fred!" right now. /in is not a macro pause command, it simply lets you queue up a single command to execute at a future time.
HOWEVER, you cannot use /in to cast a spell, use an ability, or run a macro, due to the hardware event restriction. So, its usefulness is very limited. You can use it to talk, or to use items, but that's about it. Which is one reason I didn't mention it in the first place. Because 99% of the time people want a pause, its so they can cast another spell in the same macro, or switch inventory items and then use an ability, neither of which is possible using /in.
Q: Can you help me write a macro that will automatically loot a corpse / automatically skin and loot a corpse / automatically pickpocket and loot?
A: No. There is no way to loot items except via mouse clicks.
Q: How do I make a macro that jumps and spins 180 degrees?
A: Movement related functions now require a hardware event to work so such a macro is no longer feasible. Even when it was, you could only turn at the same speed that the keyboard can turn you which is too slow to be usable in PvP. It is better to practice this maneuver using the mouse.
Addendum: (Credit Masennus)
I just figured this out. This macro will spin you 180 degrees but it requires some set up:
/script SetView(1); SetView(1); TurnOrActionStart(); CameraOrSelectOrMoveStart(); TurnOrActionStop(); CameraOrSelectOrMoveStop(); SetView(4); SetView(4);
First turn the camera 180 degrees with the mouse and type /script SaveView(1); into the chat window. Now this macro will spin you around.
If you find it disorienting to have the camera whip instantly to your new view delete the last SetView(4); Now you'll spin 180 degrees and the camera will spin a moment later to catch up with you.
Q: How do I make a macro/addon that tells me the distance to my target?
A: The ability to obtain the exact distance between you and a non-friendly target was removed. At best, you can now only obtain a range (i.e.: Between 36 and 30 units) based on which abilities on your action bar are usable.
Q: Why won't this macro / addon work? I'm almost positive my code is correct! (Credit Gharr)
A: For macros: double- and even triple-check your syntax AND SPELLING. Remember that LUA is case-sensitive! Triple-check the names of any spells, as well. CastSpellByName("Curse of Shadows(Rank 2)") is NOT the same as CastSpellByName("Curse of Shadow(Rank 2)")
For AddOns: Follow the advice given in the "For macros:" section above. Remember that both LUA *and* XML are case-sensitive! </OnLoad> is NOT the same as </onload>. If your AddOn is listed in the [AddOns] list at character select, but doesn't seem to be loading in-game, check your XML, you likely have an error there somewhere.
If you've tried the above and STILL can't get your script to work: Make a NEW post in this forum asking for help. Please DO NOT clutter up this thread asking for help with your broken macros!
Q Can I make a Macro that automatically picks up the WSG flag? (Credit Shouryuu)
A This is not possible. Any interaction with the 3d world (talking to NPCs, looting...) must be done via mouse click
|02-25-06, 12:20 AM||#16|
More Section 11
Q: How do you link multiple spells together in a single macro? (Credit Guillotine)
A: Spells can be linked into one macro if the first one does not activate the global cooldown (such as Nature's Swiftness). To do so, simply put /script SpellStopCasting(); in between the two spells. E.g.
Q u o t e:
/cast Presence of Mind
/cast Pyroblast(Rank 1)
Addendum (Credit Astryl and Ungnoticed):
Despite the popular (and usually correct) notion that you can only cast a single spell or use a single item per button press, it is possible to do so. However, what spells you can chain together is extremely limited. If you read nothing else in this post, at least read the Limitations section before posting questions.
You can only cast spells during a button press. You cannot have the macro wait for any period of time and then cast the spell. The limiting factor is cooldowns. Casting a spell (usually when you start to cast) usually activates a global cooldown. You can only chain together spells that could otherwise be cast together near-instantly. This means that the first spell must be instant, and it must not activate a cooldown that prevents the second spell from being used immediately.
---What You Can't Do---
All of you that are looking for a way to cast Frostbolt, followed by Arcane Missles, followed by Frost Nova, followed by Blink, can just give up now. The first spell must be instant, and the next spell must be able to cast immediately following the first. There's no waiting 1 second for the global cooldown to pass allowed.
---What You Can Do---
There are a few spells, usually a couple per class, that fit the rules for chaining spells. They're usually spells that affect the next casted spell, or abilities that affect the next used ability. This means things like Nature's Swiftness, Presence of Mind, Heroic Strike, Raptor Strike, etc. They have no casting time (instant) and they do not activate the global cooldown.
---How Do You Do It---
The script for doing it is relatively simple. Make a macro to cast the first spell that fits the above rules. After that, you need to call the script function SpellStopCasting(). This is the key. After that, you can cast whatever you want that isn't on cooldown. For example:
/cast Nature's Swiftness
/cast Healing Wave
That gives you a single button press to cast an instant Healing Wave. Another example:
/cast Presence of Mind
That gives you an instant Pyroblast. Here's a nice one for Rogues with First Aid:
/script UseContainerItem(0,1) --Bandage
There is an exception to this. Spell that are 'On next Attack', like Heroic Strike or Raptor Strike should not have the SpellStopCasting(), as it will cancel the spell from happening. Hunters should like this one:
/cast Raptor Strike
/cast Wing Clip
That's will do a Wing Clip immediately, and a Raptor Strike on the next attack (which might be immediately following the Wing Clip, if the weapon speed timer is up). Warriors could do the same thing with Heroic Strike and Hamstring, though that's quite alot of rage to burn through in their case.
---Items Can Be Used As Well---
Most items aren't hit by the global cooldown, which means that spells that activate the global cooldown, can still be chained with many items. Druids could make an emergency self heal that chained Rejuvenation with using a healing potion. I like to have my Lightning Shield up at all times, so I chain that before using my mount. Some trinkets can be used and immediately followed by casting spells (such as the fire trinket from the new lvl50 Mage quest).
---Tips for Effective Use---
This functionality is best used to enhance your existing play style, not totally change it. For example, a warrior (especially one who has the talents to reduce their bloodrage damage) could chain bloodrage before some/all attacks (Bloodrage+Execute would be useful), to make sure they're using it whenever possible. You could add logic so that it only uses the bloodrage if you have more than half health or something. You could make sure you're making the most of your Elemental Mastery/Presence of Mind by attempting to cast it with every Chain Lightning/Pyroblast you cast. Explore the many possabilities!
Many of these macros are best used in emergency situations, especially the NS+Heal ones. If you were to already have a spell casting when you hit the emergency heal button, it would begin casting the heal without NS. To get around this, if you have the room in the macro (macros can only be 255 characters long, remember), add another '/script SpellStopCasting()' line at the top of your macro. That will make it abort whatever spell you might already have been casting, and do the NS+Heal. Note that this doesn't just apply to NS+Heal; I use it for my EM+ChainLightning.
Please note that the examples here are just examples of how to chain spells together. In order to be very useful, some of them (ie the healing ones) will require some other addon or script to handle their targeting, so that your heal targets yourself if you don't have another friendly unit targeted, or automatically targets a certain party member, or whatever target you want.
---Chaining More Than 2 Spells---
Though even more rarely useful, it is possible to chain more than just 2 spells/items. For example, we could enhance that druid emergency heal even further:
/cast Nature's Swiftness
/cast Healing Touch
/script UseContainerItem(0,1) --Potion
One thing to note about this is that if you chain Nature's Swiftness or Presence of Mind together with a spell with a cast time, it won't work while moving, whereas it would if you casted them seperately.
The reason for this is because the client doesn't know that Nature's Swiftness or PoM is up so therefore denies the spell from being cast. This is due to the time required to communicate with the server - even latency of 1ms would cause this issue. Your latency would have to be effectively 0 (in actuality somewhere in the nanosecond range, the exact latency would depend on how fast your computer would be able to process the macro) which is not possible. This is a limitation of current technology and I suspect that it will always be the case.
This functionality also doesn't work with form or stance switches. I really wanted a 'switch-back-to-caster-form-and-start-healing' macro, but it doesn't look like that's possible. If anyone has any way to get it to work, I'd love to know.
A few more examples:
Vanish+(anything that requires Stealth) - this will never work unless you're in Stealth already when you vanish, since the client will deny use of abilities that require stealth until the server tells it you're in stealth.
Any Seal+Judgement - this will fail unless you have an active Seal. This doesn't have to be the same seal as the one you are trying to Judge, any seal will do for the purposes of validating the Judgement spell in the client. However, I know of no issues with Divine Favor+Holy Light macros.
---Is This An Exploit?---
Nope. Slouken has confirmed that this is an allowed practice. It doesn't get around cooldowns in any way. Have fun!
Last edited by Cairenn : 02-25-06 at 04:06 PM.
|02-25-06, 12:22 AM||#17|
Blizzard Customization Tools - http://www.Blizzard.com/support/wow/?id=aww01669p This is a blowout of the FrameXML in a zip file.
WoWInterface Development Network - http://wdn.wowinterface.com/
WoW UI Designer - http://wowuides.wowinterface.com/
WoWWiki - http://www.wowwiki.com - Documents almost all of the WoW API as well as in-game events that you are able to respond to.
LUA Manual - http://www.lua.org/manual/5.0/ - Official LUA Manual
LUA Wiki - http://lua-users.org/ - Wiki for LUA -- useful for more in depth descriptions of LUA syntax, etc.
WinMPQ - http://www.wowinterface.com/downloa...nfo.php?id=3990 - MPQ is Blizzard's compression format -- this program allows you to extract data from these MPQ files.
BLP2 Tools - : http://www.curse-gaming.com/mod.php?addid=180 - This allows you to open BLP files, which store the artwork for WoW.
EditPlus - http://editplus.com/ - Fairly decent editor w/ most of the options you'll need while scripting in LUA, there is a plugin for LUA syntax here. This is a trialware program -- eventually you will have to pay.
LUA Eclipse - http://www.ideais.com.br/luaeclipse/ - Another editor to use while scripting in LUA. I have not used it at all so I can't comment on it.
UltraEdit32 - http://www.ultraedit.com - My editor of choice. LUA syntax highlighting file available @ http://www.capnbry.net/wow/downloads/lua.txt courtesy of capnbry.
BLUA - http://blua.sourceforge.net/ - This is an editor being developed exclusively for Blizzard's flavor of LUA, and when complete hopes to THE complete IDE for Blizzard LUA. They are not quite finished yet but keep your eye on this one, it looks like a winner.
Dreamweaver Code Coloring for LUA - http://www.wowinterface.com/downloa...oad.php?id=3971 - Dreamweaver extension that adds syntax coloring for lua code, within both lua and xml files. World of Warcraft Global and Widget API are both included as native functions, up to version 1.5.0 of the game client (soon to be released).
WoW SciTe LUA - http://www.wowguru.com/ui/61/wow-scite-lua/ - This is a freely distributed copy of SciTe Editor with many modifications. The version of the scite editor is SciTe Version 1.63 (Modified for WoW + Lua) With the introduction of API, keywords and function calltips were made easy. I modified lua.properties to include the calltip references to the wow.api I created. What this allows you is the ability to call functions within a "saved" .lua script that you are working on to easily reference the functions, as well as help provide you help with proper syntax. WoW SciTe Lua contains full functional LUA script "inserting", "syntax checking", highlighting, and the latest 5.0 compiler. However, this is a project that is just in it's infancy, so expect a lot of great changes in the future.
XMLSpy - http://www.altova.com - This is probably the best XML editor out there, and there is a free version available. Unfortunatley many of the things that make it so great are not present in the free version. There is a 30 day trial of the good version. Over $1000 to purchase, so unless you want to warez it, probably not one to get too attached to.
XMLMarker - http://symbolclick.com/ - Completely free and pretty decent tree based XML Editor -- probably the best of no-cost editors out there.
Peter's XML Editor - http://www.iol.ie/~pxe/ - Another decent, completely free XML editor.
Nevir's Tutorials - http://wow.nevir.net/tutorial/ - Nevir has a pair of tutorials that I found very useful when starting my WoW UI modding adventure.
Phryer Tuck's Tutorials - http://vnboards.ign.com/WoW_UI_Cust...852/79108902/?8 - Phryer Tuck has an excellent tutorial here to get you started on WoW modding.
WoWWiki Tutorials - http://www.wowwiki.com/HOWTOs - WoWWiki has some basic howto's here to accomplish specific tasks.
Viewing & Converting Screenshots:
Last edited by Cairenn : 02-25-06 at 12:47 PM.
|02-25-06, 12:24 AM||#18|
Okay folks, help me get this sucker cleaned up
What needs to be added yet? Stuff about the stupid G15. What else?
|WoWInterface » AddOns, Compilations, Macros » AddOn Help/Support » The Definitive AddOn and Macro FAQ, yet again|