» Contents » (0) Quickstart » (1) Introduction » (2) Installation & setup » (3) Creating a character & starting to play » (3.7) Creating macros for ranged attacks & abilities (spells)
» (4) The world» (5) Item and flag details, elements » (6) Monster details » (7) Character details » (8) Tactics & strategy » (9) Miscellanous |
(3.7) Creating macros for ranged attacks & abilities (spells) ------------------------------------------------------------- Note: This section is becoming pretty advanced. If you want to try an easier method but miss a nice fundamental explanation on the way macros work, you may just jump to (3.7c) now, where the comfortable macro wizard is explained! Those macros basically consist of three parts. 1. Clearing the keyboard buffer (to avoid your character locking up in an attack queue if you hammer the trigger button for a ranged attack). 2. Designating a target. 3. Attacking the designated target. What does the macro look like? (Note: Keys could vary depending on your keymap definitions. Firing might be 't' instead of 'f' if you use the rogue-like key set etc.) For.. a) casting a magical spell Press 'm' to see your choices of casting magical spells. Let's assume you see this menu then: a) check dodge chance b) cast a spell Now we want 'b'. Press it to see a list of your magical books in your inventory. Let's assume you have learned spell 'a)' from book 'b)' in your inventory. Since the order of your books could change if you pick up new items or drop old ones, we will inscribe your magical book that is currently at position 'b)' like this (press '{' key to inscribe): @m2 The '2' is our own choice. We could've used 7 or 0 if we wanted to. Note that it must be a single digit! @m20 does not work. Now we can create the macro. -Press '%' to invoke the macro menu, -press 'a' to enter a new action, -enter: \e)*tmb2a- This means: \e) clear the keyboard buffer *t designate the closest enemy as the target for the spell (if there is an enemy)! m invoke the ability menu b choose 'b) cast a spell' 2 use the magical book which is inscribed @m2 a use spell 'a)' from this book - use previously designated target as direction, if that target is actually valid. Otherwise cancel the spell! -press ENTER key to accept that macro, -now hit 'h - create a hybrid macro' -hit the key you want to bind this macro to, for example the 'F1' key. F-keys are a good choice for macros, since they're not used otherwise. -To save your macros, press 's - Save macros' and enter a filename of your choice. If you want your macros to be loaded automatically when you log in with your character, save them to '<yourname>.prf'. For example to 'Gandalf.prf' if your character is called 'Gandalf'. If your macros are not automatically loaded, you'll have to do it manually after logging in, by pressing % and choosing 'l - Load macros', then specifying the according filename. Note that if your character gains additional abilities that show up in the 'm' menu, it might happen that 'b) cast a spell' becomes 'c) cast a spell' which would require you to redefine your macros. Fortunately there is a way around this, by using Ability Codes instead of letters to pick a skill to use. See 'Ability codes' below. Further, in (3.9b) a way of casting spells (or using items in general) without relying on inscriptions at all will be explained! b) throwing an item at a monster (or player) Throwing would be done by pressing 'v', followed by the item and either one of the 8 directions or '*t' to designate the closest enemy as the target. The macro: -Press '%' to invoke the macro menu, -press 'a' to enter a new action, -lets assume the item you want to throw is at position 'c)'. It's 'c) 3 potions of blindness'. You could now either specify the slot 'c)' in the macro or you could inscribe the potions @v1 and replace the c in the macro string by a 1. Inscribing has the advantage that if the potions change their location in your inventory you could still throw them. If you use 'c' you'd just throw the item at position 'c)' even if the potions are currently 'd)'. Examples: enter: \e)vc*t or \e)v1*t This means: \e) clear the keyboard buffer v throw an item c OR 1 choose 'c) 3 potions of blindness' OR choose the item for throwing which is currently inscribed @v1 *t designate the closest enemy as the target! -press ENTER key to accept that macro, -now hit 'h - Create a hybrid macro' -hit the key you want to bind this macro to, for example the 'F2' key. F-keys are a good choice for macros, since they're not used otherwise. -Don't forget to save your macro by pressing 's - Save macros' if you plan to use it again. c) firing your equipped ranged weapon (sling, bow, crossbow) The keys we need are 'f' to fire and a direction key or *t to simply target the closest enemy. The macro: -Press '%' to invoke the macro menu, -press 'a' to enter a new action, -Since ammunition for firing or a boomerang is always at a fixed position in your equipment, we do not need any inscriptions on the weapon or ammunition - the game knows which item we want to use since there's only one possible choice. enter: \e)*tf- This means: \e) clear the keyboard buffer *t designate the closest enemy as the target! f fire an item (boomerang, if equipped) or fire ammunition (if launcher & ammo is equipped) - use previously designated target as direction, if it's still valid, otherwise cancel firing! -press ENTER key to accept that macro, -now hit 'h - Create a hybrid macro' -hit the key you want to bind this macro to, for example the 'F2' key. F-keys are a good choice for macros, since they're not used otherwise. -Don't forget to save your macro by pressing 's - Save macros' if you plan to use it again. d) zapping a magical rod or aiming with a magical wand Rods are used by 'z' (zap a rod) and wands by 'a' (aim a wand), followed by the item and either one of the 8 directions or '*t' to designate the closest enemy as target. The macro: -Press '%' to invoke the macro menu, -press 'a' to enter a new action, -lets assume you want to aim the wand at position 'c)'. It's 'c) a wand of magic missiles'. You could now either specify the slot 'c)' in the macro or you could inscribe the wand @a0 and replace the c in the macro string by a 0. Inscribing has the advantage that if the potions change their location in your inventory you could still throw them. If you use 'c' you'd just throw the item at position 'c)' even if the wand currently is at 'd)'. Examples: enter: \e)*tac- or \e)*ta0- This means: \e) clear the keyboard buffer *t designate the closest enemy as the target! a aim a wand (or 'z' to use a rod here) c OR 0 choose 'c) a wand of magic missiles' OR choose the item which is currently inscribed @a0 (or @z0 for a rod) - use previously designated target as direction, if it's still valid, otherwise cancel firing! -press ENTER key to accept that macro, -now hit 'h - Create a hybrid macro' -hit the key you want to bind this macro to, for example the 'F2' key. F-keys are a good choice for macros, since they're not used otherwise. -Don't forget to save your macro by pressing 's - Save macros' if you plan to use it again. What happens if you leave out the '\e)' part? Well, that means the commands that aren't processed yet will stay in the buffer and wait for execution. Example: You hit the macro *tf- 30 times rapidly. Now your character will shoot 30 times with his bow. However, since he's quite slow, this might take him 30 seconds! You now sit in front of your keyboard and watch your character process all the remaining 30 shots. If suddenly an enemy appears that needs you to teleport away because it's too dangerous, you couldn't press any key until the 30 shots are finished. The character is 'locked'. The ')' in the macro '\e)*tf-' clears all previous keypresses and hence allows you to hammer the macro without fearing a lock.
|