Godot Version
4.4
Question
`Hello, I’m making a Spider-man Fangames in godot and I need help with the Third Person web swing. I want recreate the swinging mechanic of Marvel’s Spiderman. Please I need help!!!
PD:Sorry for my English, I speak Spanish
1 Like
Well what do you need help with? I know its the spiderman swing but what about it? (P.S. your english is great)
1 Like
You’ll probably have best luck searching for “grappling hook physics” or “rope swing physics”, but it depends on what you want.
Some of it will depend on whether you want to allow slack in the webbing. If you can treat the web as being a rigid bar, things are pretty easy; you have an anchor point where the web is attached to something, and the character holding the other end is effectively on a circular path that is the radius of the web length. Shortening or lengthening the web just changes the circle radius.
If the web can flex, you’re into rope physics, which gets more complicated, but not beyond what modern hardware can handle.
If you’re assuming that the rope/web is always in tension, you can treat it as if it’s rigid and use the easy method. The only reason you might need slack in the webbing is if the player can get knocked off the pendulum path, say by being hit from below while swinging.
Gracias, necesito ayuda con la física que detecta donde hay un edificio y lanza la red hacia el edificio más cercano
PD:Disculpa por hablar en español pero en la página oficial se puede traducir a Inglés
Parece difícil empezar con un algoritmo que pueda detectar edificios. Puedes comenzar con un RayCast3D longo desde la cámara para recibir el superficie del contacto. Además, puedes empezar con la física.
Ya tengo la física de la telaraña hecha, solo necesito ayuda con la detección de edificios. Hice de un tutorial que hubiera un RayCast3D en el centro de la pantalla y hacia lanzar una telaraña si detectaba un edificio pero así no funcionan los balanceos en los juegos de Spiderman modernos
Si recuerdo correctamente de los videojuegos modernos de Spiderman, cuando estás suficientemente cerca del edificio y lanzas la telaraña, hay una sistema de atar automáticamente al techo. Entonces, creo que es más fácil colocar unos Area3D alrededor de los edificios, llamados “Attach Zone”. Cuando el jugador presiona el botón de atar, el Area3D más cercano puede compartir una variable de export como “Attach Point” que puede ser tipo de Marker3D. Así, puedes colocar el Marker3D al borde del techo para cualquier lado del edificio, y el jugador puede empezar la acción en cualquier “Attach Zone”.
1 Like
Me podrías explicar mejor porfavor