ID:142973
 
Code:
obj
waterproj
icon='proj.dmi'
icon_state="water"
density = 1
Bump(mob/M)
if(istype(M,/mob))
var/damage=round(usr.maxreiatsu/10)
M.health-=damage
view(6)<<"[M] takes [damage] damage."
KOcheck(M)
mob
verb
Mizu_Houkou()
usr.projectile(new/obj/waterproj(usr.loc),usr.dir,20)


mob
proc
projectile(obj/projectile,var/dir,var/delay)
sleep(1)
walk(projectile,dir)
sleep(delay)
del(projectile)


Problem description:

So the problem here is obviously

var/damage=round(usr.maxreiatsu/10)


I don't know how to link the object back to the src who shot it...

I didn't take the time to confirm you're doing things in the best possible way, don't really have the time for that (although it looks as if you are doing things in a way that is undesirable), I know how to accomplish what you wanted done:
obj
var/mob/owner //This var will reference the owner
waterproj
icon='proj.dmi'
icon_state="water"
density = 1
Bump(mob/M)
if(istype(M,/mob))
if(!owner) del src //Deletes itself if there is no owner to avoid runtimes
var/damage=round(owner.maxreiatsu/10)
M.health-=damage
view(6)<<"[M] takes [damage] damage."
KOcheck(M)
mob
verb
Mizu_Houkou()
usr.projectile(new/obj/waterproj(usr.loc),usr.dir,20)


mob
proc
projectile(obj/projectile,var/dir,var/delay)
projectile.owner = src //Sets the mob as the owner of the projectile
sleep(1)
walk(projectile,dir)
sleep(delay)
del(projectile)
In response to Detnom
I just tested it out and it doesn't do any damage.
In response to GohanIdz
The only reason I could think it wouldn't do damage is if you had forgotten to set the owner in the projectile proc, causing it to delete itself before calculating the damage. I didn't really make any drastic changes to it, so it shouldn't have just stopped working. All I did was make a mob/owner variable for objects, set the owner in the projectile proc, and check for the owner then calculate the damage with the owner var in the bump proc.
In response to Detnom
Gah, my bad man. I know what happened. The default max reiatsu of a new player is 5, so whenever it was dividing 5 by 10 for the damage, it was coming up with zero.

I put it up to 55 and it worked perfectly. Sorry about that =P

Thanks for your help.