Maintenance for the week of August 17:
• PC/Mac: No maintenance – August 17

API Request: Please Expose the Existing Player Sprint State — IsPlayerSprinting / IsUnitSprinting

SugaComa
SugaComa
✭✭✭✭✭

Summary

I would like to request a simple, read-only API method for determining whether the local player is currently sprinting, including while mounted/galloping.

Ideally something along the lines of:
IsPlayerSprinting()

or:
IsUnitSprinting("player")

An event-driven alternative would also be extremely useful:
EVENT_PLAYER_SPRINT_STATE_CHANGED(bool isSprinting)

This request comes after extensive testing of the currently available ESO addon API on console using API version 101050.

The game engine demonstrably maintains an authoritative sprint state internally — including mounted galloping while using the War Mount Champion Point passive — but this state does not appear to be exposed to addon code.


Why is this needed?

The immediate use case is a simple Sprint Indicator accessibility addon.

A player may be:
  • Walking
  • Running
  • Sprinting
  • Riding normally
  • Galloping

Unfortunately, movement speed itself cannot reliably distinguish these states.

Player speed can vary substantially because of:
  • Equipment
  • Champion Points
  • Buffs
  • Character builds
  • Mount upgrades
  • Movement-speed modifiers

A speed-based addon therefore requires calibration and may become inaccurate whenever the player changes character, equipment, CP setup or buffs.

Mounted sprint detection is particularly problematic because the War Mount CP passive removes mount stamina costs outside combat.

A player can therefore be genuinely galloping while showing no mount stamina drain at all.

A direct, read-only sprint-state API would eliminate these issues.


Testing Performed

We investigated multiple possible methods using API version 101050.


1. World-position movement speed

We calculated player movement using:
GetUnitRawWorldPosition("player")

This allows movement velocity to be estimated.

However, movement speed is not equivalent to sprint state.

A sufficiently fast normal-running build may overlap with another character's sprinting speed, and character configuration changes alter the expected values.

Result:

Not reliable without per-character calibration.


2. Player stamina drain

On foot, sustained stamina loss can help identify sprinting.

However:
  • Other actions can consume stamina.
  • Sprint-cost modifiers affect the result.
  • It does not solve mounted sprint detection.

Result:

Useful as supporting information, but not an authoritative sprint-state query.


3. Mount stamina drain

Normally, galloping consumes mount stamina.

However, the War Mount Champion Point passive removes this cost outside combat.

This means a player can be actively galloping while:
Mount stamina drain = 0

Result:

Cannot reliably identify galloping.


4. Potion and item usability

ESO prevents items such as potions from being used while sprinting.

During testing, manually attempting to use a potion while sprinting produced:
UI Error 10014
"You cannot use this item while sprinting."

We confirmed this while:
Mounted = false

and while:
Mounted = true

The mounted test was performed while galloping with War Mount active.

This is particularly interesting because it demonstrates that the ESO engine still knows the player is sprinting/galloping even when the stamina cost has been completely removed.

However, immediately before ESO rejected the potion, all available public usability checks still reported that the potion was usable:
IsSlotUsable() = true
IsItemUsable() = true
CanInteractWithItem() = true
IsItemConsumable() = true

Quickslot cooldown = 0
Item cooldown = 0

The item is only rejected later in ESO's internal validation process.

Result:

The authoritative sprint state clearly exists internally, but it is not exposed through the public item-usability API.


5. Item-use validation path

We investigated whether the item-use validation path itself could be observed.

The relevant UseItem functionality is private.

Attempting to access it from insecure addon code correctly results in a private-function error.

Result:

Not accessible to addons and not an appropriate solution.


6. ACTION_RESULT_SPRINTING

The API defines:
ACTION_RESULT_SPRINTING

We registered for this result using EVENT_COMBAT_EVENT and performed three complete test sequences:
Stand still
Run
Sprint
Stop
Mount
Ride normally
Gallop with War Mount
Stop

All three completed with:
ACTION_RESULT_SPRINTING events = 0

Result:

The constant exists, but it does not appear to provide a passive event for the player's sprint state.


7. Sprint input / special move state

The API contains:
SPECIAL_MOVE_INDEX_SPRINT

This indicates that ESO internally recognises sprint as a special movement state.

However, the associated special-move input functions are private.

Similarly:
IsKeyDown()

is private.

The public API allows an addon to inspect which controls are bound to an action, but it cannot query whether the player's sprint control is currently being held.

Result:

Sprint input cannot be safely or reliably observed by addons.


8. LibSprint / ActionSlotHasNonCostStateFailure()

We also investigated the existing PC library LibSprint.

LibSprint attempts to infer sprinting using:
ActionSlotHasNonCostStateFailure()

across the player's action bar.

The theory is that when a player is moving and all normal combat abilities are blocked for a non-resource-cost reason, the player is probably sprinting.

The function itself is still publicly available in API 101050.

We implemented a console-specific test using:
  • EVENT_ACTION_SLOT_STATE_UPDATED
  • A conservative 1-second fallback poll
  • Action slots 3 through 8
  • Movement checks
  • Mounted-state checks

EVENT_ACTION_SLOT_STATE_UPDATED does fire on console.

However, the NonCostStateFailure results fluctuated independently of the player's sprint state.

Observed results included combinations such as:
F,F,F,F,F,F

T,F,T,F,F,F

T,T,T,T,T,T

including changes while the player was stationary.

During actual sprint and gallop testing, the inferred LibSprint result did not reliably indicate the player's true sprint state.

Result:

This PC inference technique does not provide a reliable sprint-state detector on console.


Conclusion

ESO clearly already maintains an authoritative internal sprint state.

We know this because the engine correctly returns:
"You cannot use this item while sprinting."

for both:
  • On-foot sprinting
  • Mounted galloping with War Mount active

This means the internal sprint state exists independently of stamina consumption.

Addon developers currently have to attempt to infer this state indirectly through:
  • Movement speed
  • Stamina consumption
  • Mount stamina
  • Action-slot availability
  • Combat-result events
  • Item usability

None of these provides the same authoritative answer the game engine already has.


Requested API

The simplest solution would be:
IsPlayerSprinting()

Returning:
bool isSprinting

Alternatively:
IsUnitSprinting(unitTag)

Example:
local isSprinting = IsUnitSprinting("player")

If exposing sprint state for arbitrary units is undesirable, IsPlayerSprinting() alone would be sufficient for this use case.


An event-driven option would also be extremely valuable:
EVENT_PLAYER_SPRINT_STATE_CHANGED(bool isSprinting)

This would allow addons to react only when the sprint state changes rather than continuously polling the API.

Ideally, the returned state would match the game's existing internal definition used by item-use validation, meaning it would return true for both on-foot sprinting and mounted galloping.


Benefits

This would be a read-only informational API.

It would not:
  • Initiate sprinting
  • Automate movement
  • Simulate player input
  • Affect movement speed

It could support:
  • Accessibility indicators
  • Sprint/gallop visual feedback
  • Controller-oriented UI improvements
  • Custom stamina/resource displays
  • Mounted movement indicators
  • Console addon development

It would also allow addon developers to remove unreliable movement calculations and continuous polling.

This is particularly relevant for console addons, where unnecessarily aggressive polling should be avoided.


The Request

Could ZOS please expose the player's existing internal sprint state through a public, read-only API such as IsPlayerSprinting() or IsUnitSprinting("player")?

The game already maintains this state independently of stamina consumption, as demonstrated by UI error 10014 correctly identifying both on-foot sprinting and mounted War Mount galloping.

Providing access to this existing state would remove the need for unreliable speed calculations, stamina monitoring, action-slot inference and continuous polling.

It would enable straightforward accessibility features such as reliable sprint and gallop indicators on both PC and console.

Thank you for considering it.
Sign In or Register to comment.