The World of Layonara  Forums

Author Topic: Emote your heart out!!  (Read 1698 times)

Pen N Popper

Emote your heart out!!
« on: March 19, 2007, 07:44:41 pm »
[SIZE=18]Tired of trying to type in battle?  Tired of repeating your introduction to the umpteenth person?  I have the solution right here![/SIZE]

Those of you that have travelled with my PCs were probably thinking to yourself, "That fellow can type up a storm!"  While I can do that, I've added to my repetoire by taking advantage of this nifty software:  AutoHotkey - Free Mouse and Keyboard Macro Program with Hotkeys and AutoText.

This free bit of software allows you to write rather complicated hotkeys and macros.  The nice thing is that it can intercept the keystrokes before they reach your game.

Take my paladin of Vorax, Wanark.  He had a dozen or more short blessings that he'd say (some in dwarven) when just prior to casting bless or equipping his waraxe.  Then he had longer blessings that even included him kneeling.  Finally, he had the entire Vorax paladin credo he'd use when he visited the temple.  All of these I had assigned to hotkeys outside the game.  Brings a tear to your eye, doesn't it?  Beautiful.

I'll give an example from my current PC that you can use to build your own set.  (Careful of line wrapping if you cut&paste into your own file.)
[INDENT][SIZE=16]
;; ------------------------------------------
;; A utility routine to say something
;;
[/SIZE]
[SIZE=16]Say(s)
{
    global prefix

    SendInput {Enter}
    Sleep 250
    IfInString, s, /tp
    SendInput {Raw}%s%
    else
    SendInput {Raw}%prefix%%s%
    SendInput {Enter}
}

;; ------------------------------------------
;; This will send yourself a tell with some help
;;
::/o help::
    SendInput {Raw}/tp "Pen N Popper" name, description, wearing, ^f
    Send {Enter}
return

;; -------------------------------------------
;; Give your name
;;
::/o name::
    SendInput {Raw}rolan tennesen... *bows* sellsword in the employ of the freelancers
    Send {Enter}
return


;; ------------------------------------------
;; A random color emote of walking along
;;
^g::
    Random, num, 1, 5
    if ( num == 1 )
    Say("*hurries along at an uneven pace, pausing now and then to catch breath*")
    else if ( num == 2 )
    Say("*moves along at a steady pace*")
    else if ( num == 3 )
             Say("*hurries along, gaze taking in his surroundings*")
    else if ( num == 4 )
             Say("*marches along with quick strides, sounding a bit out of breath*")
    else if ( num == 5 )
             Say("*moves at a deliberate pace*")

    Sleep 100
    SendInput {LControl}
return[/SIZE]

[/INDENT]I save this to a file called "rolan.ahk" and then run it.  Ingame, when I hit Ctrl-g a random description of walking will be sent.  When I type in /o description the verbose description of Rolan is output.

You can see that this can have as much flavor as you can think of.  It is especially handy during battle when all I have to do is type Ctrl-f for a fight emote.  (I even have it setup to fill in which weapon he is using to the emotes are correct.)

Good luck!

Tanman

Re: Emote your heart out!!
« Reply #1 on: March 19, 2007, 09:33:57 pm »
OK. PnP I don't know where you get this stuff from but this is brilliant.
 

gilshem ironstone

Re: Emote your heart out!!
« Reply #2 on: March 19, 2007, 09:46:24 pm »
Not only do I not know where you get this stuff, but how do you know how to use it?  Wait is that the development team laughing at me?
 

Hellblazer

Re: Emote your heart out!!
« Reply #3 on: March 19, 2007, 10:00:11 pm »
Man thank you very much.

Stephen_Zuckerman

Re: Emote your heart out!!
« Reply #4 on: March 19, 2007, 10:12:30 pm »
Quote from: gilshem ironstone
Not only do I not know where you get this stuff, but how do you know how to use it?  Wait is that the development team laughing at me?


Actually, I'm hesitant about trying to use this, myself. I'm not sure about the actual application of this...
 

Tanman

Re: Emote your heart out!!
« Reply #5 on: March 20, 2007, 01:15:36 am »
Stephen, basically its an extension of the text macro in NWN, except that it is far more powerful. You can just run a macro, and all of a sudden, the program will randomly select certain phrases that you have preselected, or you can hotkey it.

So in essence you are not tired down to the quickslots in NWN to run your text macros.
 

Hruby

Re: Emote your heart out!!
« Reply #6 on: March 20, 2007, 11:52:14 am »
P N P,

You rock as always.  Kurgin has all his slots filled with Cleric Spells.  This will help tremendously.
 

Falonthas

Re: Emote your heart out!!
« Reply #7 on: March 20, 2007, 11:59:44 am »
so do we need to do anything special for this and can it be assigned for each character or only one
 

Pen N Popper

Re: Emote your heart out!!
« Reply #8 on: March 20, 2007, 12:05:54 pm »
The way I have it set up, each of my PCs have their own ahk file.  I then browse to the files and double-click on them to get them running.  This will put a little green H in the Windows toolbar.  Right-clicking on that allows you to suspend the ones you're not currently playing.  Just keep one script active to match your current PC.
 

gilshem ironstone

Re: Emote your heart out!!
« Reply #9 on: March 20, 2007, 12:26:47 pm »
Quote from: Stephen_Zuckerman
Actually, I'm hesitant about trying to use this, myself. I'm not sure about the actual application of this...


Yeah I have seen PnP use them many a time.  Like when he did "The Book of Five Rings" series.  Those were all done using this software.
 

Hellblazer

Re: Emote your heart out!!
« Reply #10 on: March 20, 2007, 01:58:40 pm »
oy macros!!! runs and hide.

bowfreak

  • Jr. Member
  • **
    • Followers of Katia
  • Posts: 21
    • View Profile
Re: Emote your heart out!!
« Reply #11 on: March 23, 2007, 06:39:07 pm »
Do you write and save this file to your NWN folder? When do you run it...before or after you load NWN? This is sweet, the macros dont give enough room to -really- say or emote what you want without cutting it up to fit, or trying to squeeze it in multiple slots.
 
You used this with Aeron and Yzar at the Crimson Memorial, and this is exactly what I thought..."That fellow can type up a storm!"
 

darkstorme

Re: Emote your heart out!!
« Reply #12 on: March 26, 2007, 02:22:13 pm »
It runs independently of NWN, so you install it, and then any .ahk file will execute on double-click.  Generally speaking, you should activate it before you start NWN.

That being said, I've taken to editing my files on the fly, so I activate and deactivate it throughout a play session.

Edit:  I'd forgotten the reason I originally was going to post!  Props to PnP for such a useful program!
 

Faldred

Re: Emote your heart out!!
« Reply #13 on: March 26, 2007, 02:32:55 pm »
Quote from: darkstorme
It runs independently of NWN, so you install it, and then any .ahk file will execute on double-click.  Generally speaking, you should activate it before you start NWN.

Can it be launched form the command line?  That would be sweet, as I can then just add it to the batch files I use for starting NWN for Layo...
 

darkstorme

Re: Emote your heart out!!
« Reply #14 on: March 26, 2007, 02:52:25 pm »
There's a nifty little feature in AHK itself which allows you to compile an AHK file into an .exe.   I would guess that if you did that, you could then launch it from the command line, though I don't have the program here to try right now.

Even so, I'd imagine it's possible.
 

pejsaboy

  • Full Member
  • ***
    • Posts: 284
      • View Profile
    Re: Emote your heart out!!
    « Reply #15 on: April 07, 2007, 08:56:55 pm »
    Once I got past the formatting, this thing is absolutely great! Thanks for the link :D
     

    Masterjack

    Re: Emote your heart out!!
    « Reply #16 on: March 13, 2008, 09:53:24 am »
    *bump for the new players*

    My son set it up for me. He has it so all have to do is hit Crtl + L and NWN launches and loads right into layo. Don't ask me how to do it, I have no idea.
     

    Thief Of Navarre

    • Jr. Member
    • **
      • Posts: 131
        • View Profile
      Re: Emote your heart out!!
      « Reply #17 on: January 19, 2009, 07:12:36 am »
      Im pretty sure ^L::Run C:\\Desktop\\nwn.exe to run Neverwinter Nights if thats the way its set up. God knows how he got it to load into Layo from the getgo! Im not that clever or patient >.<
       

      ShiffDrgnhrt

      Re: Emote your heart out!!
      « Reply #18 on: January 19, 2009, 03:50:16 pm »
      Well it doesn't work in with Layo.  It's based on Key Board Commands like Ctrl+L to execute written scripts that you make.  It's probably capable of doing things like launch NWN for you with a push of some buttons, but I don't know how to script that.  I do know though, that after you create your basic scripts, while in game if you hit the assigned short cut, usually an CtrL+whatever letter you want or number or whatever, it can do whatever's necessary.  it even works as a sort of "auto typer."  I have it set up that if I type /o armor it scripted to type in "*Tyra does whatever with her armor"...  it's really cool, but I wouldn't know how to help someone set it up over forum posts.  If you can catch me or any of the other people who use it with some fluency on IRC I'll be happy to talk you through at least what I have set up.
       

      ShiffDrgnhrt

      Re: Emote your heart out!!
      « Reply #19 on: March 24, 2009, 07:09:00 pm »
      A Friendly Bump  :)
       

       

      anything