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

better on_ground calc #667

Open
andrewgazelka opened this issue Dec 9, 2024 — with Linear · 13 comments
Open

better on_ground calc #667

andrewgazelka opened this issue Dec 9, 2024 — with Linear · 13 comments
Assignees
Labels

Comments

Copy link
Collaborator

right now is on_ground: velocity.velocity == Vec3::ZERO,

Copy link

linear bot commented Dec 9, 2024

@andrewgazelka
Copy link
Collaborator Author

closing cause backlog

@andrewgazelka andrewgazelka closed this as not planned Won't fix, can't repro, duplicate, stale Dec 11, 2024
@Tebarem
Copy link
Collaborator

Tebarem commented Dec 11, 2024

i added one on the physics branch its 100% accurate

@andrewgazelka andrewgazelka reopened this Dec 11, 2024
@andrewgazelka
Copy link
Collaborator Author

andrewgazelka commented Dec 11, 2024

ok re-opening so you can close it @Tebarem on merge

@Tebarem
Copy link
Collaborator

Tebarem commented Dec 11, 2024

#696

@Tebarem Tebarem closed this as completed Dec 11, 2024
@andrewgazelka
Copy link
Collaborator Author

nooooo

@andrewgazelka
Copy link
Collaborator Author

image

like this

@andrewgazelka
Copy link
Collaborator Author

now when your PR is merged it will auto close this issue

@Tebarem
Copy link
Collaborator

Tebarem commented Dec 11, 2024

bruh. why did i not know of this

@andrewgazelka
Copy link
Collaborator Author

this is not actually truly correct. should look at AABB collisions similar to try_change_position probably

@Tebarem
Copy link
Collaborator

Tebarem commented Dec 15, 2024

@andrewgazelka how come? can u show a clip

@andrewgazelka
Copy link
Collaborator Author

A good example would be a half slab. If there is a half slab below the player, your algorithm would think that the player is on the ground when there's still a half block of air to go. So you need to actually look at the bounding boxes of the block to determine if the player is on the ground.

@Tebarem
Copy link
Collaborator

Tebarem commented Dec 15, 2024

you are right i didnt account for that. will have a look again

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants