for(var/mob/Combative/target in view(0,M))
if(target!=M&&target in get_step(M,M.dir))
Problem description:
I've also tried this with:
for(var/mob/Combative/target in view(1,M))
however because of pixel movement it's not accurate and sometimes doesn't hit at all... for some people this may sound like a basic problem but I'm not exactly what you'd call a professional programmer if someone could help me figure out an effective way of having an accurate attack i'd appreciate it