Monday, April 15, 2013

Ever want to know what spell or skill is unlocked at a certain level?

One of the great things Dentin has recently implemented is notifying you when a new skill is unlocked.  This feature is great for newbies and veterans alike.  In fact, I enjoy this feature so much that I asked myself, "What if a player didn't want to wait until the skill is actually unlocked to find out what's available soon?"
You could walk to a trainer and type slist, but what if there was a command that let you do it without making the hike?  Since Dentin hasn't implemented this idea yet, and I'm fairly adept with aliasing, I decided to make a hackjob alias that could clone this. Enter previewsk (preview skill) and previewsp (preview spell)!

Simply type alias start previewsk and copy/paste this code into the editor:


if $1 == "thief"  skills $1 || grep --   --   $2   --   --  --    ## thief two digit
 if $1 == "thief"  skills $1 || grep --   --    $2   --   --  --   ## thief single digit
 if $1 == "cleric" skills $1 || grep --   $2   --   --   --  --    ## cleric two digit
 if $1 == "mage"   skills $1 || grep $2   --   --   --   --  --    ## mage any digit
 if $1 == "warr"   skills $1 || grep --   --   --   $2   --  --    ## warrior two digit
 if $1 == "warr"   skills $1 || grep --   --   --    $2   --  --   ## warrior single digit
 if $1 == "necro"  skills $1 || grep --   --   --   --   $2  --    ## necro two digit
 if $1 == "necro"  skills $1 || grep --   --   --   --    $2  --   ## necro single digit


When you've done that, type /done or @ <enter> twice.
Note: The double pipes "|" are intentional because of how the editor handles pipes.

 Here's the code for previewsp:


 if $1 == "warr"   lec There are currently no spells for the warrior class. Bitch at Dentin. ## warrior any digit
 if $1 == "mage"   spells $1 || grep  $2   --   --   --   --  --  ## mage any digit (bugged for one digit inputs)
 if $1 == "cleric" spells $1 || grep --    $2   --   --   --  --  ## cleric one digit
 if $1 == "cleric" spells $1 || grep --   $2   --   --   --  --   ## cleric two digit
 if $1 == "thief"  spells $1 || grep --   --   $2   --   --  --   ## thief two digit
 if $1 == "necro"  spells $1 || grep --   --   --   --    $2  --  ## necro one digit
 if $1 == "necro"  spells $1 || grep --   --   --   --   $2  --   ## necro two digit



Notes:
1. I wasn't able to figure out how to properly handle mage spells or skills under level 10.
    The game will output the available skills, it just will output some that are higher level as well.

2.  The usage is in this form: previewsk <class> <level> or previewsp <class> <level>
Note that since parsing isn't available for aliases (or if it is, I haven't figured it out yet) the class names must be entered exactly as this:
Necromancer = necro
Warrior = warr
Mage = mage
Cleric = cleric
Thief = thief

I put in an easter egg for previewsp warrior. Try it out.

Improvements to the alias are welcomed.  I hope you enjoy using these. :)

- Taran

No comments:

Post a Comment