i am quite new to scripting and have been experimenting with the tween service as well as user input service. i threw together a shift to sprint script using my limited knowledge, but i came across an issue, being if you end the shift input while the tween is still playing, it bugs your walkspeed as it would use the current speed value (being tweened) instead of the base speed value of the character.
what i'm doing right now is using the variable "wstarget" to define the character's base walkspeed, but i am afraid that might cause difficulties in the future if i want the wstarget variable to be changed by another script.
i thought of a possible remedy for this problem, being:
store the player's base walkspeed inside a stringvalue parented to the player's character model, and retrieve that value whenever they sprint
but i don't think that is the most efficient way of doing so
mb if this is a stupid question, i couldn't find answers anywhere and i really want to avoid technical debt
(im putting the script as its own message inside the thread because of discord character limits :p)
** You are now Level 1! **