Hello. I am new to scripting, but I’m wondering if it is easy to implement this type of constraint to a sprite moving in a 2.5D world: http://www.galloquema.com/papmario2.mov
The effect that I am wanting is the part where Mario goes around the corner and the camera/world readjusts to 2D side-scrolling perspective.
Other than that I want to limit the movement to X + Y.
But is there an easy way to force the movements to only the x and y axis? I want a true side-scroller here.
But I also want to be able to have the camera move around corners like it did in the movie I posted. Essentially, the player will hold left and right most of the game, and when a corner is approached, the player is still only required to hold left or right and the character and camera follow the path automatically.
Am I being unclear? Any tutorials? How can I modify this script to achieve these goals?
Also, I have tried to use the script from the wiki that forces 2D: http://www.unifycommunity.com/wiki/index.php?title=Force2D but things aren’t as simple as just adding the script along with the 3D controller, I am seeing a weird stutter for example.
Is there a tutorial that really covers the bare minimums of moving in simple up, down, left, right?
If you visit this page, you can see a little example of how to use the CharacterController to move your character around. Looking at that movie you posted, which is basically 3D, you’ll probably just want a character that always points its Z axis at the camera (using transform.LookAt). That way, when you use the CharacterController or manipulate the camera in any way, it will always move relative to it.
I hope that helps out. I’m much better at being confusing than at clarifying, unfortunately.