ID:140976
 
Code:
if(usr.dir == NORTH)
var/obj/SuutonW/A = new /obj/SuutonW(locate(usr.x, usr.y+1, usr.z))
var/obj/SuutonW/B = new /obj/SuutonW(locate(usr.x+1, usr.y+1, usr.z))
var/obj/SuutonW/C = new /obj/SuutonW(locate(usr.x-1, usr.y+1, usr.z))
A.owner=usr
B.owner=usr
C.owner=usr
A.dir = NORTH
B.dir = NORTH
C.dir = NORTH
walk(A,usr.dir,2)
walk(B,usr.dir,2)
walk(C,usr.dir,2)
sleep(60)//6 seconds
del(A)
del(B)
del(C)


the objects code:
SuutonW // :)
icon='projectiles.dmi'
icon_state = "Watervortex" //read New() above for more info. also check the projectiles.dmi
layer = MOB_LAYER + 1//??
var/list/wtrails=new
density=1
var/owner

New()
..()
sleep(30)//mpve lasts 6 secs
del(src)

Bump(atom/movable/a)
if(ismob(a))
var/mob/A=a
var/dmg=500
A.Dec_health(dmg,src.owner)
A << output("[src.owner]'s Suuton wave hit you for [dmg]!", "output2.combat")
del(src)
Move()
..()
var/turf/old_loc = src.loc
spawn()
var/obj/O = new/turf/terrainset/five(old_loc)
O.dir = src.dir
src.wtrails += O

Del()
..()
sleep(100)//wait 10 secs after the obj is dleed then delete the trails
for(var/obj/o in src.wtrails)
del(o)


Problem description:

The code only shoots one projectile now.
30 minutes ago before i added a few bits of code to a completly different section the code worked well.
Ive tried alot of things and it only shoots one object :( whats wrong?
You have sleep() in your New() part. This delays the New proc, which delays the execution of the new proc line when you fire the projectile.
Just change sleep() to spawn() and indent the del(src) line.
In response to Kaiochao
thanks. It works now, i never would have guessed it was that simple.