r/howdidtheycodeit • u/siorys88 • Sep 02 '22
Third person ledge detection
You know when the character jumps and then hangs from an edge of a platform or ledge and then climbs it? Is that mechanic collision based? Does it depend on the geometry of the level?
2
Upvotes
View all comments
Show parent comment
2
u/siorys88 Sep 02 '22
can you elaborate on that? Let's say you do shoot a raycast towards the edge. That means that you need to have all grabbable edges preannotated in your level. Is that how it's done? Or is there a way for the raycast to detect the edge's angle and consider it grabbable if it's less than a certain amount?