Hi i was considering use ray cast forward every time i move my object to see if it get to hit any one in front of it.
But then i’ve considere as well using worldTranslation,if i know my size and future location all i need is check if it equals other objects location + their size. Soo what i would to know is how mutch rayCast consuming in front of
lets say :
If(movingObject.getTranslation.getX<otherObject.getTranslation.getX-(movingObjectSize/2+otherObjectSize/2)||
movingObject.getTranslation.getX>otherObject.getTranslation.getX+(movingObjectSize/2+otherObjectSize/2));
doing same for Z and not doing for Y couse my objects cant fly or stuff. And doing this for each Other object exists in world.
Or should i just ray cast for node with all object in the world. I know its not a perfect code but its just to get an idea on what i want to use at place of ray ,if it is cheaper for pc efforts .
And im fine with vertex giving not precise data and is good only for a ball may be ,but im fine with let it leav some extra space for just in case
Soo what do you think is better ray or vertex using ?