physics.CastHit
pykraken.physics.CastHit Result of a ray cast or shape cast query.
More about physics.CastHit
Contains the body that was hit, the point and normal of the intersection, and the fraction along the cast path where the hit occurred.
At a glance
5 membersReference
PYTHON APIConstructor
methodphysics.CastHit(/, *args, **kwargs)Initialize self. See help(type(self)) for accurate signature.
body
propertybody: physics.BodyThe body that was hit.
fraction
propertyfraction: floatThe fraction along the cast path at which the hit occurred.
normal
propertynormal: Vec2The normal vector of the hit surface.
point
propertypoint: Vec2The point of the hit in world coordinates.