That function is used for AI controlled entities i.e enemies and NPCs to find target and gain proper velocity to move toward target.
It only gain velocities to be used by any of these functions:
dash
leap
shoot2
Those functions are the ones who do the actions.
In case you still haven't figured it yet, do you know Sodom or any fat chargers from Final Fight series? if you want to replicate their targetted charging attack, you need to use this target function.
Parameter definitions:
void target(float Velx, float Velz, float dx, float dz, int Stop)
Velx = maximum x velocity
Velz = maximum z velocity
dx = x offset
dz = z offset
Stop = stop flag, 0 = get x velocity only, 1 = don't move