Gosse - cheers :)
I'd do...
I ditched the normalize. That could be built into the np_GetNX and np_GetNY commands. I would also have a global temp vector (np_VectTemp?) that could be used for all commands like this. That way you don't have to keep creating and freeing types. The value returned from nP_PolyOverlap would then just be True/ False.
Of course you should do it how you think best... but I like to keep everything as clean and simple as possile so that's what I would do.
I'd do...
vect = nP_PolyOverlap(...) if vect then ; its not 0, so there is a vector and it collided x = nP_GetNX(vect) y = nP_GetNY(vect) end if
I ditched the normalize. That could be built into the np_GetNX and np_GetNY commands. I would also have a global temp vector (np_VectTemp?) that could be used for all commands like this. That way you don't have to keep creating and freeing types. The value returned from nP_PolyOverlap would then just be True/ False.
Of course you should do it how you think best... but I like to keep everything as clean and simple as possile so that's what I would do.