Skyrim

File information

Last updated

Original upload

Created by

Off the Rails

Uploaded by

Offtherails

Virus scan

Safe to use

22 comments

  1. djtalks
    djtalks
    • supporter
    • 5 kudos
    i use a ps4 controller.. will this allow my macros for left and right mouse pad to hit 9 and 0. i use ds4.
    1. Offtherails
      Offtherails
      • premium
      • 9 kudos
      Not by itself, but Autohotkey can convert buttons to keypresses so it would be easy to script.
  2. Sam324
    Sam324
    • member
    • 2 kudos
    @Offtherails:  Good idea; however, I've actually come to a different solution, not actually using AutoHotkey but accomplishing what I wanted to do anyway.  I just used FreePIE to make the A and D keys move the cursor left and right, and that worked fine in Skyrim.  If anyone's interested in doing the same, here's the script I used:

    def update():
    yaw = trackIR.yaw
    pitch = trackIR.pitch

    deltaYaw = filters.delta(yaw)
    deltaPitch = filters.delta(pitch)

    if keyboard.getKeyDown(Key.A):
    mouse.deltaX = -sensitivity + deltaYaw*multiply
    if keyboard.getKeyDown(Key.D):
    mouse.deltaX = sensitivity + -deltaPitch*multiply
    else:
    mouse.deltaX = deltaYaw*multiply
    mouse.deltaY = -deltaPitch*multiply

    if starting:
    enabled = True
    multiply = 20
    sensitivity = 10
    trackIR.update += update

    This is just a modified version of the TrackIR to mouse input script on the FreePIE website; the reason I wanted to turn my view with A and D was because I was using TrackIR for head tracking and wanted a secondary way to turn my character.  So if anyone else wants to use this script for A and D rotation of the character/view, just take the "if keyboard.getKeyDown..." lines and use those in a FreePIE script, along with the line "sensitivity = 10", or change 10 to another number based on preference.  In fact, I think this is what it should be:

    sensitivity = 10

    if keyboard.getKeyDown(Key.A):
    mouse.deltaX = -sensitivity
    if keyboard.getKeyDown(Key.D):
    mouse.deltaX = sensitivity

  3. Sam324
    Sam324
    • member
    • 2 kudos
    @Hirlok:  I guess you could say I tested what you asked, as I am trying to do the same thing and having the same problem, where the mouse can be moved by keyboard keys outside of Skyrim but not in the game.  I've tried all the different input modes in AutoHotkey.
     
    Basically, what I want to do is make the keyboard walking controls Guild Wars 2-style, where strafing is with Q and E, and A and D turn my character/view left and right in addition to the mouse.
     
    I'm also bothered by how it either moves the cursor slowly and smoothly or quickly but in visible jumps (e.g. 50 pixels at a time); does anyone know if there's a way to make the cursor move rapidly but not in large jumps?
    1. Offtherails
      Offtherails
      • premium
      • 9 kudos
      Tricky one. I guess Skyrim ignores the mouse cursor and uses raw mouse input to pan the player's view.

      Might be doable if you switch on Skyrim's controller support and map the keys to the gamepad's X axis... ?
  4. Hirlok
    Hirlok
    • supporter
    • 17 kudos
    Thanks for this piece of code - might help me to get my problem solved. Maybe other users here are more experienced and could help me - what I am trying to achieve is this: for smooth cam rotation (when recording in-game video) I want to assign mouse movement to hotkeys.

    Usually you just add something like

    !g::MouseMove, -1, 0, 50, R
    !h::MouseMove, 1, 0, 50, R

    to a script, works (in Windows...)

    If I add this to one of the scripts in the mods scripts folder, - it does not work. In Windows yes, but not in game.

    Any way to assign mouse movements to autohotkey keys??? thanks & cheers!
    1. Offtherails
      Offtherails
      • premium
      • 9 kudos
      It could be that your commands are in a part of the script that never gets called. Try a new script? SAA will load any scripts it finds in the folder; no setup needed.
    2. Hirlok
      Hirlok
      • supporter
      • 17 kudos
      thanks for the reply. hmmm. Actually I tried that already.

      I have the feeling that keyboard handling and mouse handling are 2 things... maybe Skyrim blocks something there, so while we can assign keys to actions etc. no manipulation of the mouse input is accepted...

      Just in case you are TERRIBLY bored ;-) - could you try if in your setup you can convince Skyrim to accept mouse pointer movements via AutoHotKey commands and share the result? I just don't get it, but then again I started to use AHK yesterday, LOL

  5. GreenCultist
    GreenCultist
    • BANNED
    • 0 kudos
     I would like to ask, if any of you guys could help me with AutoHotKey. In my case I would like to bind this console command to MOUSE4: pushactoraway 00000014 1
     
    Thanks Since Now!
  6. Offtherails
    Offtherails
    • premium
    • 9 kudos
    Ylurien: I don't know, I've never tried. Mod Organizer might let you launch SAA instead of TESV.exe; that would be the preferred method if it's possible. Or you could edit the saa.ini file to point to the Mod Organizer executable.
  7. Ylurien
    Ylurien
    • premium
    • 0 kudos
    How do you run this together with Mod Organizer?
  8. Offtherails
    Offtherails
    • premium
    • 9 kudos
    clownatwar: www.autohotkey.com for autohotkey
  9. clownatwar
    clownatwar
    • member
    • 1 kudos
    "To run, just double-click Skyrim Autohotkey Assistant.ahk. All your scripts, and then Skyrim, will be launched like arrows at Agincourt."

    How did you make your program associate .ahk to it? I'm not just curious, it doesn't work here. W7 64.
  10. Offtherails
    Offtherails
    • premium
    • 9 kudos
    @larry7

    I'm not sure what you mean; are you trying to create your own autohotkey scripts? If so, www.autohotkey.com has a huge help forum.