- Home /
Climbing using OnTriggerEnter and Arrow Keys?
So, here's the setup I'm using: I have a character, with a box collider at his feet. The goal is that when the collider hits something like a wall, and the button space is help, the character is entered into a climbing state. Then, if the arrow keys are pressed, the character can go up, left, right, down, etc. How do I do this?
(I also made an image: my description isn't the best...)
Answer by Johnz1234 · Jun 20, 2015 at 10:39 AM
You can deactive your player movement scrip and active your ladder script something like this void OnTriggerEnter(){ CharacterController.enabled = false; LadderClimbing.enabled = true; } void OnTriggerEnter(){ CharacterController.enabled = true; LadderClimbing.enabled = true; } Check out on youtube ladder climing unity
Do you have any ideas for how to do the ladder climbing? As well as how to turn off another script remotely?
Your answer
