Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix grappling on gridmaps #551

Merged
merged 1 commit into from
Nov 15, 2023

Conversation

Malcolmnixon
Copy link
Collaborator

@Malcolmnixon Malcolmnixon commented Oct 17, 2023

This PR fixes issue #541 by only updating the RayCast3D when needed in the physics frame (to prevent getting stale data), and by relaxing the type of collider to be of anything the RayCast3D can collide with - including GridMaps.

The following screen-shots were taken using the KayKit City Builder Bits assets in a GridMap.
image
image

@DigitalN8m4r3
Copy link
Contributor

Lgtm,
on a sidenote, this could work well for a spiderman game :)

@BastiaanOlij
Copy link
Member

I would suggest trying to run everything in physics process and seeing if it runs properly, I'm not a fan of force physics because it takes a costly path especially when physics runs in a separate thread.

@Malcolmnixon Malcolmnixon force-pushed the grappling-on-gridmaps branch from 94215ed to 17f4b95 Compare November 2, 2023 00:12
@Malcolmnixon
Copy link
Collaborator Author

I would suggest trying to run everything in physics process and seeing if it runs properly, I'm not a fan of force physics because it takes a costly path especially when physics runs in a separate thread.

Done, and tested as working in the same city map.

This PR fixes issue GodotVR#541 by only performing RayCast3D tests in the physics update, and by relaxing the type of collider to be of anything the RayCast3D can collide with - including GridMaps.
@Malcolmnixon Malcolmnixon force-pushed the grappling-on-gridmaps branch from 17f4b95 to d4fa428 Compare November 5, 2023 17:11
@BastiaanOlij BastiaanOlij added the enhancement New feature or request label Nov 15, 2023
@BastiaanOlij BastiaanOlij added this to the 4.3.0 milestone Nov 15, 2023
Copy link
Member

@BastiaanOlij BastiaanOlij left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to merge

@Malcolmnixon Malcolmnixon merged commit b6b8994 into GodotVR:master Nov 15, 2023
2 checks passed
@Malcolmnixon Malcolmnixon deleted the grappling-on-gridmaps branch November 15, 2023 02:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants