Thoughts on putting all movement mechanics into one script?

Hello developers, I am here to ask if it would be a better idea to put all movement mechanics in a game in one script. The reason I am even thinking about this is because in one script, you would only need to get a service or define the character once whereas in multiple you would need to define variables multiple times. With that said should I put all my movement code in one script or keep using multiple?

(Also just want to say I did make a post like this a long time ago but I didn’t think much about the benefits before posting it)

Thanks for reading!

So far I know, that is really just up to your preference.

If it’s thousands of lines, it may be easier to split up the main components so that debugging and overall readability is easier than everything being in a single script.

2 Likes

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.