sourcelike air strafing in unity

Опубликовано: 04 Ноябрь 2024
на канале: corviraptor
734
13

finally dipping my toes into gamedev!

i referenced this steam guide to figure out how source air control actually works: https://steamcommunity.com/sharedfile...
i ended up replacing the vector projection math with a dot product since its roughly what's being done anyways, although i might adjust the dot product to roughly account for the non-normal magnitudes if when i get out of grey checkerbox hell it feels weird.

i couldn't get the vector projection math detailed in the guide to work in this for some reason, the speed limit would be reached but for some reason allow the acceleration to continue regardless?? but yay, theoretically an extraordinarily marginal performance boost because i pruned the trig stuff????? programming is scary. in the end its probably better that this system is using something that i'm more familiar with anyways, and it seems to achieve what i want it to do anyways

also yes, i literally havent programmed ground movement yet. the first thing i programmed after the camera rotation was the air control system LMFAO