Speed Increment while ADS

Hello, Ive run into another problem. Thanks to the awesome member “EVERYONE” here, I have this script to disable sprint while ads. In the meantime, Ive gotten a code to work, that lets me increase or decrease walk speed with my thumb mouse buttons, however, while ADS, I can get walk speed up to sprint, negating my disable sprint to ads functions. is there a way to limit the speed increment while ADS but have full increment while not ADS. Sorry if this doesnt make sense!
Any help would be greatly appreciated. <3

Same principles apply.

On ADS input, check if you can ADS, determine stance (standing, crouched, prone), set max walk speed, do ADS stuff.

How do you say “Can ADS?” vs “Is ADS” and what determines the difference? are they both just simple booleans? I appreciate your response, and sorry if this is a simple question. And I only ask this because I can always ADS.

Depends on the rules of your game. In mine I can’t ads if sprinting, falling, swimming etc.

In general can ads refers to checking against game rules that wouldn’t allow you to ads.