Change Camera/Character Controls by entering a vehicle or environmental area.

I want to create a game where the User’s Character is getting in and out of vehicles and traveling to different environments. So you’d be walking around then access a vehicle with a button and then be driving or flying around. How do you get the controls and the camera to change?

Another use for changing behavior on the fly is to set up various animations based on environments: walking indoors as opposed to trudging through the snow. How do you get the walk animation to change based off the area you’re in?

This is really 2 questions, and when you look at it like that it’s really more like 10. This is a lot of work you’re asking about with these two paragraphs.

Part 1: Just have some kind of interface that defines how a ‘vehicle’ responds to input. Then, just use the correct input vehicle for any given object. The catch- the baseline walking player character counts as a vehicle for these purposes! It just uses a different control scheme. Similarly with cameras- set up cameras in all the different locations that you need them, and then just activate them when you need them.

Part 2: I’d do this with physic materials. Given that you have all your different animations, you can check the physic material of the object you are standing on, and pick your animation accordingly.