I'm working on a 2d game that has multiple player characters in the scene at once. The first character I made the controls for using rigidbody. If the second character is controlled in the same way, is there a way to just copy everything from the first character (but with a different sprite), and toggle between which one is being controlled? Or does the second one need it's own variables and whatnot?
Currently, the second character has it's own unique variables, but is controlled by different keys. I'd be fine with that, in fact I'd prefer it, except for the fact that I can't get him to move on the horizontal axis. His jump works, but I can't figure out why he won't move back and forth. I copied everything from the first guy who works fine, to this guy, and added/changed all of the states and variables to be unique to him, but still nothing. Any help for these problems is greatly appreciated. Since I'm a total programming noob, I had to follow a tutorial. Here is the tutorial I followed if it helps someone figure this out for me.