Jump to content

[LE] Unable to increase player walking speed


Recommended Posts

I'm trying to increase player walk speed (without increasing it for NPCs) however im not completely sure how to do this. I've created a magic effect that increases speed mult with these conditions:

 

Subject.IsRunning = 0.000000 AND

Subject.IsSprinting = 0.000000 AND

Subject.IsSwimming = 0.000000 AND

Subject.IsMoving = 1.000000 AND

Subject.IsSneaking = 0.000000 AND

 

When I add the spell with this effect to the player, the speed stays the same. Thanks.

Link to comment
Share on other sites

Check to see if IsRunning returns true even when walking. Pretty sure it does. Why do I think this? When using a controller both walk and run are managed by variable pressure on the stick. Lowering the speed multiplier for running to 25~35 yields a visual walk when the stick is fully pressed.

 

Keyboard & Mouse is the only input method that gives a toggle between walking and running. Not sure what the game does but I do not think that the speed multiplier is affected by toggling on walk.

 

If you were to get the user's INI setting for bAlwaysRunByDefault in the SkyrimPrefs.ini (1 = run / true, 0 = walk / false) you could then attempt to figure out which mode they were in when moving by checking to see what keys have been pressed (requires SKSE papyrus functions) and then adjust the speed multiplier (up or down) to achieve the rate that you want.

 

The following will check the user's INI file.

If Utility.GetINIBool(bAlwaysRunByDefault:Controls) == false
  ;default movement is walk instead of run
Else
  ;default movement is run instead of walk
EndIf

As for the rest, you'll probably need GetMappedKey before being able to register for the keys that could affect the user's movement. Unfortunately, I'm not sure which of the key labels correspond to what you'd need.

Link to comment
Share on other sites

Turns out the conditions work perfectly for what I needed. Somehow I had messed the spell up which was causing the magic effect to not apply. It does have a minor delay when switching between walking and running, which can lead a much higher running speed for a short duration, however I don't think I can fix that without adding another script. Thanks for the help.

Edited by pickle12312312312
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...