Bump(mob/M)
if(!M.client)
killit(M)
Problem description:
ive tried this
Bump(mob/M)
if(!M.client)
if(istype(src,mob/Units/)) return
killit(M)
but it gets an error, but i got it to where i can make my troops. my troops do what i want them to do. only problem is, when they bump each other, they attack each other, i want to get rid of that...how?
B) You need a slash at the start of that type-path: /mob/Units/
C) Assuming this Bump() is defined under the Unit type, you want to be checking that M's type is /mob/Units and not src's.
D) The killit() call shouldn't be indented under that second if(), as the return statement is the only thing that's meant to be inside it.