Joshua Red

Members
  • Content Count

    2
  • Joined

  • Last visited

  1. Joshua Red

    Opposite event of onColide

    Hi NasimiAsl, thank you for your reply. What I was intending to do is if you're walking forward and you walk into a ladder then it would automatically start moving you up the ladder, like how ladders are in Minecraft. I could use your suggestion and transport them to the top instantly (or use a animation) but it would be nice if I could jump off the ladder half way.
  2. Joshua Red

    Opposite event of onColide

    Hi, I'm trying to make an FPS game, and right now I'm attempting to make climbing up ladders possible. What I've tried so far is to have an `onCollide` event move the camera up a bit, but gravity pushes it down again, so I disable gravity when you move up: camera.onCollide = function(collidedMesh) { if (collidedMesh.id === 'ladder') { camera.applyGravity = false; camera.position.y += 0.02; } }; But then I have to turn gravity on again afterward. So when it stops colliding I want to enable gravity again, but I can't find the right event to use. Do you guys know anything else I can try?