ID:168282
 
Im tryin to make an npc that when in range will follow you and try to shoot you with a projectile but i have no idea where to start. o,o
I could make an NPC that follows you then attacks you once your in the way but i dunno how to make one that shoots you.
have a constant check to see if your in range, and if you are, have them shoot a bullet in your direction

proc/ifshoot()
TAB> for(var/mob/M in oview(5))
TAB> >TAB> insert shoot in direction of M stuff here
TAB> sleep(reload time)
TAB> ifshoot()