Hey Guys. I made a topic earlier in which I needed help with making a speed simulator script. Everytime I move in any direction I want my leaderstat ‘Speed’ to go up by 1 everytime. I was lucky enough to have a in depth detailed description on how to make it. I’ve tried attempting to connect the pieces of his reply together but can’t quite figure out how. I came here for help. I’m a basic scripter wanting a better understanding on how to script. Basic Leaderstat|554x231
This is the leaderstat I made with a value of Speed.
This is the script attempt at trying to make my speed go up by one everytime I move in any direction. I’m sorry if the script hurts your eyes because I’m really bad at scripting but that’s why I came here.
P.S
My leaderstat script is in the ServiceScriptService because I believe that’s where it goes.
And my AddSpeed Script (2nd photo.) is in the Players place.
If I got any of this wrong please help me out with where it should go and why.
That would be where I’m really confused. As a basic scripter I’m trying to find out more stuff. Right now I don’t have the idea on how I can make a variable from a different script go into another script. Such as leaderstats. Speed is my leaderstat. The thing I want to do is bring the ‘Speed’ value from the leaderstat script into the AddSpeed script. I’m not quite sure how…
Yeah sorry that’s another part I’m confused on. Trying to get the leaderstat of another script. AKA bring the value from the leaderstat script into the AddPoints Script.
So I suppose "Stats’ Refers to the leaderstat in a way?
This doesn’t work for me. I don’t know if we went of topic a bit or something but my goal was to make it add 1 speed every second… I think I’m really bad at this sorry guys…