so im trying to do what i just mentioned, is there a way to set a range, so like something like

if (bullet's X,Y,Z is in the range of Player X,Y,Z) (within 100 units, for instance)
{
remove player health by 10
}

sorry for the wierd psuedo code.